-
Notifications
You must be signed in to change notification settings - Fork 859
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
UDP packets of size less than 12 bytes are not sent from WSL to host #8610
Comments
@qqshka try
and the listener on Windows side: |
And your point is? Yes scapy works while nc does not works. The thing is nc here was as example how to reproduce it, the fact is almost any application could not send short UDP packets. scapy seems to be an exception since I guess it uses raw sockets or something (and probably calculates checksums on its own). I checked difference between packets from nc and scapy and for nc you may notice bad checksum. First packet sent with scapy, second with nc.
Also, I should admit that problem seems to arise after I installed recent update of the Windows. |
Got the same issue after a recent windows update, currently on OS version 19044.1826 |
After a lot of messing around trying to debug a test system I can confirm that I have found exactly the same issue. Two of our test systems failed pretty much at the same time, both use UDP based comms (small packets) and Win10/11 with WSL Ubuntu 20.04.4 LTS. Both systems also received Windows updates over the time of failure. Thank you to qqshka for reporting this - I was beginning to think I was going mad as I went down the rabbit hole of routing, bridging, NAT'ing and firewalls before stumbling on the length issue by typing a cursing rant into netcat! Win10 Ver: 19044.1826 |
I'm seeing similar behaviour from an ubuntu-22.04 hyper-v host. So, might not be WSL's fault? This is running Windows 11 pro 21H2 (22000.795) |
I used iperf3 between a WSL2 distro on a Win10 machine (client side) and a Fedora 36 machine (server side) to test the UDP transfers:
iperf3 command on client side was However, the same iperf3 command entered in a classic cmd console (WSL not involved) works whatever the Win10 version is. Wireshark shows that the first UDP packet exchanged by iperf3 has a 4-byte payload. Not found any workaround so far. |
We are looking into this. In the meantime, you should be able to work around this by disabling checksum offload from within WSL. As root: ethtool -K eth0 tx off This is global across all your distros, but it is not persisted across WSL restarts. |
I have a similar issue, except my What I wanted to note is this started with Summary: |
I and my team have encountered this in several programs including PHP. I can confirm that uninstalling update |
Can confirm I had the same problem testing a simple game server echo bot from Agones. |
Same issue here when using netcat inside WSL2 (or any app using UDP). Small packets do not go through to the receiving end while larger packets do go through. Receiving packets from the other end into WSL2 netcat client works for any size. |
Can confirm this issue. |
Can confirm, this isn't specific to WSL. It also happens on other Hyper-V VMs, which is how I found this issue (god what a debugging nightmare). |
@jstarks what is the status on this issue please? Is there an estimate on when a fix will be released? |
It seems fixed by a recent Windows update. However I don't know which one. |
Can confirm that I'm also on 10.0.19045.2251 and it seems to work fine now. |
I'm windows 11 ( 22H2 22621.819) work fine |
Win 11 (22H2 22621.525) still has this problem. As per https://support.microsoft.com/en-gb/topic/windows-11-version-22h2-update-history-ec4229c3-9c5f-4e75-9d6d-9025ab70fcce If necessary, this may help someone track down the specific change. |
I had this issue the entire time I was running server 2016. I was running a game called SWGEMU in a hyper-v VM with Ubuntu 20.04. I was encountering constant disconnects in that game until I ran the above command(ethtool -K eth0 tx off). I had to run that command every time I started the VM. I just upgraded to server 2019 and the issue is resolved. I no longer have to run that command on the VM to stay connected to the game server. |
This solve my problem. I'm working on 22621.2215 , and the client is Ubuntu18.04 on WSL2. Thanks alot |
This issue has been automatically closed since it has not had any activity for the past year. If you're still experiencing this issue please re-file this as a new issue or feature request. Thank you! |
Version
Microsoft Windows [Version 10.0.22000.795]
WSL Version
Kernel Version
5.10.102.1
Distro Version
Ubuntu 20.04
Other Software
No response
Repro Steps
Expected Behavior
I sent few UDP packets from WSL2 to the host, starting with UDP payload size of 2 bytes up to 13 bytes, expecting to receive all packets.
Actual Behavior
Only packets with payload size 12 or more received on the host.
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered: