iqiyi / dpvs

DPVS is a high performance Layer-4 load balancer based on DPDK.
Other
3.04k stars 730 forks source link

dpdk 17.11.2 Mellanox cx4-lx mlx5 pmd , fdir 不通 #627

Closed legend050709 closed 4 years ago

legend050709 commented 4 years ago

(1)dpdk 版本 17.11.2

(2)mellanox 网卡信息 Mellanox Technologies MT27710 Family [ConnectX-4 Lx] firmware-version: 14.26.1040 (MT_2420110034) [PN] Part number: MCX4121A-ACAT

(3)fdir 不通 (3.1)client 信息 client: 192.20.0.11

(3.2)dpvs 配置

ipvsadm -ln

  IP Virtual Server version 0.0.0 (size=0)
  Prot LocalAddress:Port Scheduler Flags
    -> RemoteAddress:Port           Forward Weight ActiveConn InActConn
  TCP  192.22.2.3:80 conhash sip synproxy
    -> 192.21.6.11:80               FullNat 20     0          1

(3.3)日志信息

连接:

ipvsadm -ln -c

  [6]tcp 3s     SYN_SENT    192.20.0.11:63838  192.22.2.3:80      192.21.4.5:1028    192.21.6.11:80

日志如下: Aug 6 09:57:31 dpvs[17883]: IPVS: conn lookup: [6] TCP 192.20.0.11/63838 -> 192.22.2.3/80 miss Aug 6 09:57:31 dpvs[17883]: SAPOOL: sa_pool_fetch: 192.21.4.5:1028 fetched! Aug 6 09:57:31 dpvs[17883]: IPVS: new conn: [6] TCP 192.20.0.11/63838 192.22.2.3/80 192.21.4.5/1028 192.21.6.11/80 refs 2 Aug 6 09:57:31 dpvs[17883]: IPVS: conn lookup: [23] TCP 192.21.6.11/80 -> 192.21.4.5/1028 miss Aug 6 09:57:31 dpvs[17883]: IPVS: tcp_conn_sched: [23] try sched non-SYN packet: [S.A.] 192.21.6.11/80->192.21.4.5/1028

如上日志所示,outbound方向流量 到达 core 23,和inbound 方向的 core(6)不一致,说明 fdir 没有生效;

问题: 请问 (1) 为什么 fdir没有生效, fdir生效需要什么要求? (2)fdir 不生效的情况下,如果还是该配置,规避方案用 redirect 功能?

ywc689 commented 4 years ago

有没有打下面这个patch? patch/dpdk-stable-18.11.2/0003-driver-kni-enable-flowitem-type-comparsion-in-flow.patch

legend050709 commented 4 years ago

有没有打下面这个patch? patch/dpdk-stable-18.11.2/0003-driver-kni-enable-flowitem-type-comparsion-in-flow.patch

用的是dpdk 17.11 编译的 dpvs;请问 这个也需要打下这个patch 吗?

ywc689 commented 4 years ago

dpdk 17.11 对 mlx 驱动支持不完整,请使用 dpdk 18.11