xdp-project / xdp-tutorial

XDP tutorial
2.42k stars 575 forks source link

advanced03-AF_XDP: Icmp echo not replying #299

Open becker63 opened 2 years ago

becker63 commented 2 years ago

Hello there, I'm having a issue attempting to run "Assignment 3" in which you write a ping reply program. I thought I could just run this without any changes considering the note in the README.. 'full solution is present in the af_xdp_user.c file'.

But when I run it with

t setup --name veth-adv03
sudo ./af_xdp_user -d veth-adv03

and then test it with

t ping

I don't get any form of transmission stats from the af_xdp_user program and my pings aren't responded to.

All I have done to my clone is add more comments, mostly in the process_packet() function.

should I add something more to the program to handle user to kernel transmission? the note at the end of process packet.. /* Do we need to wake up the kernel for transmission */ seems like its hinting something to me but I'm not sure.

tohojo commented 2 years ago

"Present" does not mean "working". This is a tutorial, you are expected to read the code and comments and do some work, not just run it without looking at it. Should be pretty obvious why it's not working when you do that (look at process_packet() in particular)...