-
Notifications
You must be signed in to change notification settings - Fork 62
examples/sendudp stuck at Poll() after a while #9
Comments
it seems setting "Paravirtualization Interface" to "Minimal" in virutalbox VM setting solves the problem, however the VM performance is greatly impacted with such setting; |
I can confirm I see something very similar as well on Ubuntu 20.04, Linux kernel 5.8.0-55-generic, running natively.
Running
16 happens to be the maximum number of packets that will be attempted to be sent per "kernel kick", i.e. by the sendmsg(2) call on XDP socket, by the kernel: https://github.com/gregkh/linux/blob/v5.8/net/xdp/xsk.c#L332 By modifying
It doesn't seem like kernel ever reports those transmitted descriptors as completed:
The way they should be reported as completed is by skb->destructor getting called when the skb has been "sent": https://github.com/gregkh/linux/blob/v5.8/net/xdp/xsk.c#L376 BUT, this issue only seems to happen on virtual interfaces such as veth, I've never seen this issue happen on any "real" interfaces. So it could be some bug in the way we interact with the kernel, or, less likely, could be some problem in the kernel; we should probably try reproducing on latest kernel. |
So far, I only experienced this issue in a virtualbox VM; there is no issuing running sendudp on veth interface natively on my linux server (ubuntu 20.04 kernel 5.4.0-74-generic, CPU Intel E3-1230 V2) |
Hi,
I tried running examples/sendudp in a virtualbox VM running Ubuntu 20.04 (on a windows 10 host), using command "sendudp -interface vA", vA is a veth interface; the program always stop sending pkt after a while like following:
Then I added some codes to run pprof, and found the program stuck at line "_, , err = xsk.Poll(-1)", then I changed the timeout to a positive value like ", _, err = xsk.Poll(1000)", but it still stuck at the same place ....
The text was updated successfully, but these errors were encountered: