-
Notifications
You must be signed in to change notification settings - Fork 823
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
Curl failed by ping can succeeds on WSL2 #5382
Comments
Another user could ping but couldn't curl #4926 (comment) |
I think I have the same issue. I think this started happening since I installed the most recent windows 10 2004 update KB4557957 - https://support.microsoft.com/en-au/help/4557957/windows-10-update-kb4557957 , but I'm not certain. According to I see similar issues when trying to I have attached a pcap (zipped) which shows me doing the following in ubuntu 20.04:
Unfortunately that windows update KB4557957 doesn't look like it can be uninstalled, so I can't test if this update caused this issue. I ran Let me know what other information I can provide. Thanks, |
Having the exact same issue here; it looks like this starts to occur when I switch WiFi networks (home + work), but it's not consistently problematic on a single network. Sometimes it works at home, sometimes it works at work, and when it does, it keeps working until I connect to the other network again. Would also like to hear what info I can provide to help, here's some info for a start:
By the way, I seem to always be able to get up and running again by executing the commands described in this article:
|
Well, I found what the problem is in my case. |
I tried running the following (I skipped the renew because I use a static IP):
But after a reboot it still didn't work - same symptoms as before. However, on a whim, I disabled the HyperV feature in windows (Turn Windows Features on or off > HyperV), while leaving the WSL feature enabled. I rebooted and noted that all hyperV vswitch devices were gone - I had to reconfigure my IP address on the real network adapter again, but once I did that, I tried WSL. After it loaded, it automatically created a WSL vswitch again. I can successfully run Is it possible that the default hyperV vswitch and the WSL vswitch were interfering with each other? I don't know how to see how the bridges are actually configured/layered in windows. Is there a good way to see what adapter the WSL vswitch is 'bound' to? |
Try changing nameserver in /etc/resolv.conf cmd as admin:
Windows Search > Network Reset It save me couple times, when installing Gentoo WSL & Funtoo WSL. |
Just collected networking logs with the steps described at https://github.com/microsoft/WSL/blob/master/CONTRIBUTING.md#9-networking-logs and submitted them through the Feedback Hub. Feedback Hub URL: https://aka.ms/AA8sbrx |
Did you find a way around Symantec Endpoint Protection? I am having the same issue, and I just can't use WSL2 at the moment. |
@rescenic thank you, it worked! |
@rescenic |
In my case, curl request with multiple big response(more than on object) has error. |
I had the similar issue on one of my Windows laptops: the computer had F-Secure firewall enabled, and only after disabling the firewall I could reach internet locations from WSL. |
Sadly I have to say that all of the above mentions workaround does not work for me. I use Windows 10 Version 20H2. Previously my WSL2 , Ubuntu-20.04 was working perfectly. I notice the problem only after recent windows update. My WSL2 statistic:
If I revert to WSL1, and the issue solved. |
in my case i have to I looked into the NIC solution and disabled the WLAN, leaving only the ethernet interface. Not sure if it works but I'll see. |
Thanks... this was my problem as well. Damn. |
Thank you, this method has saved my life |
For those using Symantec Endpoint Protection, I shared a workaround at MicrosoftDocs/WSL#1046 (comment). Perhaps it could be useful for other firewalls as well. |
Same on my WSL. Disabled SEP and everything is OK now. |
|
I have Symantec yes and despite the workaround Symantec still seems to be blocking traffic : |
I've been experiencing inconsistent This pattern started to smell like a problem with an interface's MTU size. Within WSL2, I adjusted the MTU with the following:
Previously, As soon as I changed the MTU to 1400, all the It's not impossible this particular symptom is something to do with my network, but I thought I'd mention it! That |
@tbehling you are the one! I've experienced exactly the same behaviour and the worst thing is that I was trying to troubleshoot a dockerized env on WSL2. To make "persistent" changes to WSL2, I use the |
win10 block the WSL interface traffic. sudo Set-NetFirewallProfile -DisabledInterfaceAliases "vEthernet (WSL)" |
Hi. Can you please collect networking logs by following the instructions below? Please stop WSL, then start the trace, then start WSL and reproduce the issue, then stop the trace |
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! |
Environment
Windows build number:
10.0.19041.0
Your Distribution version:
Ubuntu 18.04
Whether the issue is on WSL 2 and/or WSL 1:
WSL 2
Steps to reproduce
Expected behavior
Curl should succeed too under my company's network on WSL 2.
Actual behavior
Curl failed under my company's network on WSL 2.
Notes
I have tried a lot of workarounds mentiond by other issues such as #4698, but these methods didn't work for me.
BTW, I tried to captures packets by Wireshark and it seems that the TCP SYN can't get a ACK.
The text was updated successfully, but these errors were encountered: