Open hanlins opened 4 years ago
OS and DPDK functions are supposed to work independently and are designated for different network device types. If you bound your NIC to DPDK driver, use SetSender
and SetReceiver
, if you use Linux driver, then use SetSenderOS
and SetReceiverOS
. Conflating them will most likely cause problems and I am really surprised that you managed to make them both work :)
Hi
nff-go
community, I was trying to usenff-go
in my project. What I want to achieve is to check the original packets' five-tuple and encapsulate the original packets (in IPIP) and set the destination accordingly and send it out through the same interface. I'm trying to useAF_PACKET
before moving to XDP/DPDK ports. I hit several issues:The first issue is when I was trying to use
SetReceiverOS
andSetSenderOS
as the input/output flow function, the process just stuck there and perform any packet processing. I was trying to send the packets through a veth pair interface. Here's the code snippet:Then instead of using
nff-go
's methods to useAF_PACKET
, I tried pass dpdk args to the framework (see the comment out lines above), and now the packets are processed, but both the original packet and the processed packet are sent through the interface.You can see that both the icmp req and response are seen twice in the tcpdump above. The 2nd icmp req and response are the packets sent by this dpdk program and the first ones are the original packets.
I wonder why the original packet is also sent through the interface? Also it will be nice if I can get helps on figuring out the cause why I cannot use
SetReceiverOS
andSetSenderOS
against a veth interface.