[ovs-dev] [PATCH dpdk-latest v4] build: Add support for DPDK meson build.

Tonghao Zhang xiangxia.m.yue at gmail.com
Wed Dec 16 13:43:20 UTC 2020


On Wed, Dec 16, 2020 at 9:34 PM Pai G, Sunil <sunil.pai.g at intel.com> wrote:
>
> <snipped>
> > > I tried your build commands using latest dpdk-next-net and OVS-dpdk-
> > latest branch. It worked fine for me on ubuntu18.04.
> > > Moreover, GHA and travis CI's are passing for the shared builds.
> > > So, it might be a problem with the system you are using.
> > > Best to check the paths you are setting as well.
> > >
> > > Btw, which branch in OVS and which OS are you using ?
> > > Could you also try running a sample application in dpdk like l2fwd and check
> > if it works fine as well ?
> > Yes, I use the dpdk helloworld to test.
> > ./build/helloworld -n 4 -c 4 -a
> > 0000:82:00.0,dv_flow_en=1,dv_esw_en=1,l3_vxlan_en=1,dv_xmeta_en=2,r
> > epresentor=[0-2]
> > EAL: Detected 56 lcore(s)
> > EAL: Detected 2 NUMA nodes
> > EAL: Multi-process socket /var/run/dpdk/rte/mp_socket
> > EAL: Selected IOVA mode 'VA'
> > EAL: Probing VFIO support...
> > EAL: VFIO support initialized
> > EAL: Probe PCI driver: mlx5_pci (15b3:101d) device: 0000:82:00.0 (socket 1)
> > common_mlx5: RTE_MEM is selected.
> > mlx5_pci: Size 0xFFFF is not power of 2, will be aligned to 0x10000.
> > EAL: No legacy callbacks, legacy socket not created hello from core 2
> >
> > But there is error in ovs:
> > $ ovs-vsctl show
> > a360a9ac-d269-4e89-b01c-c09331b9fb00
> >     Bridge br-int
> >         datapath_type: netdev
> >         Port tun
> >             Interface tun
> >                 type: vxlan
> >                 options: {key=flow, local_ip="10.96.74.2", remote_ip=flow}
> >         Port br-int
> >             Interface br-int
> >                 type: internal
> >         Port rep1
> >             Interface rep1
> >                 type: dpdk
> >                 options: {dpdk-devargs="0000:82:00.0,representor=[1]"}
> >                 error: "Error attaching device '0000:82:00.0,representor=[1]' to DPDK"
> >
> >
> > ovs-vswitchd log:
> > 2020-12-15T21:20:41.703Z|00333|netdev|WARN|rep1: could not set
> > configuration (Invalid argument) 2020-12-
> > 15T21:20:41.703Z|00334|dpdk|ERR|Invalid port_id=256
> > 2020-12-15T21:20:41.703Z|00335|dpdk|ERR|EAL: failed to parse device
> > "0000:82:00.0"
> > 2020-12-15T21:20:41.703Z|00336|dpdk|ERR|EAL: failed to parse device
> > "0000:82:00.0"
> > 2020-12-15T21:20:41.703Z|00337|dpdk|ERR|EAL: Failed to attach device on
> > primary process 2020-12-
> > 15T21:20:41.703Z|00338|netdev_dpdk|WARN|Error attaching device
> > '0000:82:00.0,representor=[0]' to DPDK
> >
> > One question, did you attach a dpdk port to ovs ?
>
> Yes, I attached physical as well as virtual ports and both got added without err.
>
> I suspect you might have to add a conf file pointing to the dpdk libraries , something like mentioned here:
> https://www.cyberciti.biz/faq/linux-setting-changing-library-path/
still not work
I export LD_LIBRARY_PATH=/root/local/dpdk-next-net/lib64
change that to:
$ cat /etc/ld.so.conf.d/dpdk.conf
/root/local/dpdk-next-net/lib64
$ ldconfig

>
> Also, what does the ldd report for ovs-vswitchd binary ?
linux-vdso.so.1 =>  (0x00007fff52364000)
/usr/local/gundam/gundam_client/preload/$LIB/gundam_preload.so =>
/usr/local/gundam/gundam_client/preload/lib64/gundam_preload.so
(0x00007fa24dda2000)
librte_vhost.so.21 =>
/root/local/dpdk-next-net/lib64/librte_vhost.so.21
(0x00007fa24dab9000)
librte_ethdev.so.21 =>
/root/local/dpdk-next-net/lib64/librte_ethdev.so.21
(0x00007fa24d479000)
librte_meter.so.21 =>
/root/local/dpdk-next-net/lib64/librte_meter.so.21
(0x00007fa24d276000)
librte_mbuf.so.21 => /root/local/dpdk-next-net/lib64/librte_mbuf.so.21
(0x00007fa24d05b000)
librte_mempool.so.21 =>
/root/local/dpdk-next-net/lib64/librte_mempool.so.21
(0x00007fa24ce4f000)
librte_eal.so.21 => /root/local/dpdk-next-net/lib64/librte_eal.so.21
(0x00007fa24cb50000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fa24c934000)
librt.so.1 => /lib64/librt.so.1 (0x00007fa24c72c000)
libm.so.6 => /lib64/libm.so.6 (0x00007fa24c42a000)
libunbound.so.2 => /lib64/libunbound.so.2 (0x00007fa24c129000)
libc.so.6 => /lib64/libc.so.6 (0x00007fa24bd5b000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007fa24bb57000)
libnuma.so.1 => /lib64/libnuma.so.1 (0x00007fa24b94b000)
librte_kvargs.so.21 =>
/root/local/dpdk-next-net/lib64/librte_kvargs.so.21
(0x00007fa24b748000)
librte_telemetry.so.21 =>
/root/local/dpdk-next-net/lib64/librte_telemetry.so.21
(0x00007fa24b53e000)
librte_net.so.21 => /root/local/dpdk-next-net/lib64/librte_net.so.21
(0x00007fa24b32f000)
librte_ring.so.21 => /root/local/dpdk-next-net/lib64/librte_ring.so.21
(0x00007fa24b12b000)
librte_cryptodev.so.21 =>
/root/local/dpdk-next-net/lib64/librte_cryptodev.so.21
(0x00007fa24af13000)
librte_hash.so.21 => /root/local/dpdk-next-net/lib64/librte_hash.so.21
(0x00007fa24acf7000)
librte_rcu.so.21 => /root/local/dpdk-next-net/lib64/librte_rcu.so.21
(0x00007fa24aaed000)
librte_pci.so.21 => /root/local/dpdk-next-net/lib64/librte_pci.so.21
(0x00007fa24a8ea000)
/lib64/ld-linux-x86-64.so.2 (0x00007fa24dfab000)
libssl.so.10 => /lib64/libssl.so.10 (0x00007fa24a678000)
libevent-2.0.so.5 => /lib64/libevent-2.0.so.5 (0x00007fa24a430000)
libpython2.7.so.1.0 => /lib64/libpython2.7.so.1.0 (0x00007fa24a064000)
libcrypto.so.10 => /lib64/libcrypto.so.10 (0x00007fa249c01000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007fa2499eb000)
libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x00007fa24979e000)
libkrb5.so.3 => /lib64/libkrb5.so.3 (0x00007fa2494b5000)
libcom_err.so.2 => /lib64/libcom_err.so.2 (0x00007fa2492b1000)
libk5crypto.so.3 => /lib64/libk5crypto.so.3 (0x00007fa249096000)
libz.so.1 => /lib64/libz.so.1 (0x00007fa248e80000)
libutil.so.1 => /lib64/libutil.so.1 (0x00007fa248c7d000)
libkrb5support.so.0 => /lib64/libkrb5support.so.0 (0x00007fa248a6e000)
libkeyutils.so.1 => /lib64/libkeyutils.so.1 (0x00007fa24886a000)
libresolv.so.2 => /lib64/libresolv.so.2 (0x00007fa248650000)
libselinux.so.1 => /lib64/libselinux.so.1 (0x00007fa248429000)
libpcre.so.1 => /lib64/libpcre.so.1 (0x00007fa2481c7000)

>
>
> >
> > ovs commit-id:
> > af06184705072804a4c1374f9c824c9e4c241c26
> > dpdk-next-net
> > d3fa7b89f0b893f051cb4cef1cbc961cb59f5721
> > systeminfo
> > CentOS Linux release 7.6.1810 (Core)
> > kernel 3.10.0-957.1.3.el7.x86_64
> >
> > >
> > > >
> <snipped>



-- 
Best regards, Tonghao


More information about the dev mailing list