Closed arnohub closed 2 years ago
下面以 DPVS 1.9.0 版本为例
关于下面这两行输出,不用管它,这是 DPVS 的警告输出,也只是警告,并不影响使用。
NETIF: Ethdev port_id=0 invalid rss_hf: 0x3afbc, valid value: 0x38d34
NETIF: Ethdev port_id=0 invalid tx_offload: 0x1000e, valid value: 0x2a03f
在启动 DPDK PORT 时(对应函数 netif_port_start
),会先检查并适配 RSS 和 OFFLOAD(防止后面调用 DPDK 接口做配置时失败);而在检查和适配过程(adapt_device_conf
)中,会首先通过 DPDK 接口获取网卡设备实际支持的值,如果发现和配置文件中的不一样,则将配置修改为从 DPDK 接口中获取的值,并打印一条警告日志;之后,netif_port_start
函数才会调用 DPDK 接口来配置 DPDK PORT。
所以,即使在 dpvs.conf 中配置的不对,DPVS 也会纠正为正确的值(同时打印一条警告信息),并不影响后续的使用。
只要确认网卡支持DPVS所要求的特性(也可通过 valid value: 0x38d34
中的值推算出是否支持),可以忽略上面的警告输出。
这条告警说明网卡不完全支持配置设定的 rss 方式(默认是all),可以尝试通过调整配置文件中的 rss 配置消除。如果消除不了,只要确认所有 worker 上都有连接且转发正常,就可以忽略该告警。
感谢这个问题解决了,不过又遇到了新的问题,我搭建了个测试环境,遇到了client端访问vip端口不通的情况,dpvs抓包发现直接回复了RST,rs上抓不到dpvs过来的包,并且ipvsadm -ln --stats OutPkts 没流量,确定dpvs到RS网络是通的,tcp探活没问题。拓扑及详情如下:
[root@inf2-test bin]# cat /etc/dpvs.conf
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
! This is dpvs default configuration file.
!
! The attribute "
! global config global_defs { log_level WARNING ! log_file /var/log/dpvs.log ! log_async_mode on ! pdump off }
! netif config netif_defs {
也需要通过 dpip 命令将 IP 及其路由在 dpdk 网卡设置一下,因为 DPDK 和 Linux 是两个独立的网络栈。
你看上面的截图,路由设置了
OS:CentOS7.9 DPDK:dpdk-stable-20.11.1 DPVS:dpvs-1.9.0 NIC:X520-DA2
[root@localhost:/root/dpvs-1.9.0/bin]
./dpvs
current thread affinity is set to FF EAL: Detected 8 lcore(s) EAL: Detected 1 NUMA nodes EAL: Detected static linkage of DPDK EAL: Multi-process socket /var/run/dpdk/rte/mp_socket EAL: Selected IOVA mode 'PA' EAL: No available hugepages reported in hugepages-1048576kB EAL: Probing VFIO support... EAL: Invalid NUMA socket, default to 0 EAL: Probe PCI driver: net_ixgbe (8086:10fb) device: 0000:02:00.0 (socket 0) EAL: Invalid NUMA socket, default to 0 EAL: Probe PCI driver: net_ixgbe (8086:10fb) device: 0000:02:00.1 (socket 0) EAL: No legacy callbacks, legacy socket not created DPVS: dpvs version: 1.9-0, build on 2022.07.09.06:00:33 CFG_FILE: Opening configuration file '/etc/dpvs.conf'. CFG_FILE: log_level = WARNING NETIF: dpdk0:rx_queue_number = 8 NETIF: dpdk1:rx_queue_number = 8 NETIF: worker cpu1:dpdk0 rx_queue_id += 0 NETIF: worker cpu1:dpdk0 tx_queue_id += 0 NETIF: worker cpu1:dpdk1 rx_queue_id += 0 NETIF: worker cpu1:dpdk1 tx_queue_id += 0 NETIF: worker cpu2:dpdk0 rx_queue_id += 1 NETIF: worker cpu2:dpdk0 tx_queue_id += 1 NETIF: worker cpu2:dpdk1 rx_queue_id += 1 NETIF: worker cpu2:dpdk1 tx_queue_id += 1 NETIF: worker cpu3:dpdk0 rx_queue_id += 2 NETIF: worker cpu3:dpdk0 tx_queue_id += 2 NETIF: worker cpu3:dpdk1 rx_queue_id += 2 NETIF: worker cpu3:dpdk1 tx_queue_id += 2 NETIF: worker cpu4:dpdk0 rx_queue_id += 3 NETIF: worker cpu4:dpdk0 tx_queue_id += 3 NETIF: worker cpu4:dpdk1 rx_queue_id += 3 NETIF: worker cpu4:dpdk1 tx_queue_id += 3 NETIF: worker cpu5:dpdk0 rx_queue_id += 4 NETIF: worker cpu5:dpdk0 tx_queue_id += 4 NETIF: worker cpu5:dpdk1 rx_queue_id += 4 NETIF: worker cpu5:dpdk1 tx_queue_id += 4 NETIF: worker cpu6:dpdk0 rx_queue_id += 5 NETIF: worker cpu6:dpdk0 tx_queue_id += 5 NETIF: worker cpu6:dpdk1 rx_queue_id += 5 NETIF: worker cpu6:dpdk1 tx_queue_id += 5 NETIF: worker cpu7:dpdk0 rx_queue_id += 6 NETIF: worker cpu7:dpdk0 tx_queue_id += 6 NETIF: worker cpu7:dpdk1 rx_queue_id += 6 NETIF: worker cpu7:dpdk1 tx_queue_id += 6 SAPOOL: sapool_filter_enable = on NETIF: Ethdev port_id=0 invalid rss_hf: 0x3afbc, valid value: 0x38d34 NETIF: Ethdev port_id=0 invalid tx_offload: 0x1000e, valid value: 0x2a03f
试了flow_enable off,netif.c port_conf->rxmode.mq_mode == ETH_MQ_RX_RSS_NONE还是报错,大佬帮看看什么问题