DPDK

topics: DPI Engine
related: NUMA, Linux
tags: #networking

Data Plane Development Kit

Created by Intel for high speed packet processing with zero-copy and poll mode driver.

This allows processing of packets without any copy from receiving to the transmitting.

Advantage

dpdk-comparison.png463
Main advantage compared to the traditional kernel based processing is that with DPDK, the userspace is able to directly process the packet, without the kernel being involved, and without costing a copy. Another major difference is that the DPDK is using Poll mode driver, whereas the kernel is handling network packets using IRQs.

Related notes

Windows

install msys2 mingw64
Install this package pacman -S mingw-w64-x86_64-gcc
Then follow the instruction at 3. Compiling the DPDK Target from Source — Data Plane Development Kit 23.07.0 documentation

DPDK testpmd

dpdk-testpmd -l 0-1 -n 4 -- -i --portmask=0x1 --forward-mode=txonly
start tx_first
stop
show port stats all

This will generate traffic and send it to the interface. Useful to test if the interface is working or not.

dpdk-testpmd -l 11-16 -a $PCI_ADDR -- --forward-mode='rxonly' --mbuf-size=10000 --max-pkt-len=9600 --stats-period=3

This will check the speed of receiving on the interface.