Search code examples
dpdk

EAL: Error - exiting with code: 1 Cause: No Ethernet ports - bye


I was trying to get the l2fwd application to work but it keeps showing this error. I dont understand I have the NICs properly bound and hugepages configured

The error `

./dpdk-l2fwd -l 0-3 -n 1 --no-telemetry -- -q 8 -p ffff  
EAL: Detected CPU lcores: 6
EAL: Detected NUMA nodes: 1
EAL: Detected static linkage of DPDK
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket
EAL: Selected IOVA mode 'PA'
EAL: VFIO support initialized
TELEMETRY: No legacy callbacks, legacy socket not created
MAC updating enabled
EAL: Error - exiting with code: 1
  Cause: No Ethernet ports - bye
root@dpdku:~/dpdk/build/examples#

`

Hugepages

`

dpdk-hugepages.py -s
Node Pages Size Total
0    600   2Mb    1Gb

Hugepages mounted on /dev/hugepages

`

NICs: `

dpdk-devbind.py -s

Network devices using DPDK-compatible driver
============================================
0000:00:08.0 'RTL-8100/8101L/8139 PCI Fast Ethernet Adapter 8139' drv=uio_pci_generic unused=8139too,vfio-pci
0000:00:09.0 'RTL-8100/8101L/8139 PCI Fast Ethernet Adapter 8139' drv=uio_pci_generic unused=8139too,vfio-pci

Network devices using kernel driver
===================================
0000:00:03.0 'RTL-8100/8101L/8139 PCI Fast Ethernet Adapter 8139' if=ens3 drv=8139cp unused=8139too,vfio-pci,uio_pci_generic *Active*

`


Solution

  • DPDK application l2fwd is just doing the right thing, not identifying the NIC you have shared. There is nothing wrong with the behaviour as this is the expected behaviour. Reason for the same is shared below as

    1. The nic RTL-8100 is Realtek Semiconductor RTL-8100/8101L/8139 PCI Fast Ethernet Adapter
    2. Following DPDK device enter link description here does not list the support for Realtek NIC
    3. One can check nic vs features to go through the various PF and VF PMD, realtek driver is absent.
    4. Also checking the online driver net PMD realtek driver is not supported.

    Hence the only way to use the Realtek nic dpdk is to

    1. bind the nic back to the kernel
    2. use either PCAP PMD to access the device into DPDK
    3. or use AF_XDP (if RTL supports the same), you can use AF_PACKET PMD.

    Note: please at least read up on documentation or hw list from dpdk.org to understand the library and supported PMD.