-
Notifications
You must be signed in to change notification settings - Fork 822
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
[WSL2] Can't update Ubuntu, git clone, apt install, but ping works (Windows 1909) #5971
Comments
Please collect WSL logs and post the backlink to the feedback item here. Also please identify any third-party networking software that has been installed on Windows. |
I would really like to follow the procedure to give more intel but unfortunately I don't have the Feedback Hub on my computer. I don't find a way to install it. |
Having the exact same problem. |
Having the same problem. Things work fine when I reboot the computer, but after a while WSL 2 loses its connection to certain things (apt, mainly) while ping still works fine. Here's my feedback backlink: https://aka.ms/AA9tug5 |
same problem |
For me, even ping stopped working |
I had exactly the same issue (Windows 10 version 1903 (build 18362.1139) + Ubuntu 18.04 though WSL2) . It turns out that my wifi was configured in Windows as "public" network. Switching to "private" fixed the problem. |
|
Subscribing. Initially ping to Ubuntu mirrors worked, but apt update didn't (timeout). Then finally ping stopped working too (destination unreachable). WSL rendered unusable. Pity. Back to Hyper-V VMs (with a custom NAT vSwitch to overcome spurious WiFi adapter issues). >sigh< |
Update: downgrading to WSL 1 seems to be the best option for now, while the WSL 2 bugs are ironed out?
|
I did a downgrade installed stuff I needed upgraded back. But yeah WSL 2 seems to be broken for now. |
Same for me. For now I'm going back into my "normal" VM :/ |
Same problem for me. I had to downgrade back to WSL 1... |
Same problem for me. Is there any workaround except downgrading back to WSL 1? |
Guys, check your firewall-settings. For me, Bitdefender Firewall blocks WSL2 traffic. |
@ad-on-is Thanks, I checked the firewall that i used at the desktop, this caused from firewall liked you mentioned. |
i am living the same problem.... in wsl1 update is working , in wsl22 update problem.... any solution?????? |
@osmanatam add two rules to your firewall that all through the network interface used by WSL2, it is worth a try. |
Same problem for me |
Guys, check to firewall. |
This fixed the issue for me #5867 (comment) EDIT: This just fixed it temporary. The issue is back. Apparently when the network configuration changes (VPN off and then on again) then WSL2 cannot find its way to the internet anymore. |
|
If you modified, moved or compressed the temp folder, look at #5437 for the solution |
Me also. So WSL 2 causes packet fragmentation? |
Checkout my comment: maybe it helps: #5061 (comment) |
I tried and tried and tried to configure my firewalls to let the WSL2 work it's magic. I followed several tutorials that all led to the same ~5 ways to config the firewalls. In the end, I set WSL version back to 1; and it worked as though 'nothing was wrong'. |
changed wifi from public to private, then reboot windows fixed it for me |
Check what antivirus you are using. I was having McAfee and endpoint security enabled. If disconnect End Point security firewall connectivity will work straightaway (no reboot required). https://kc.mcafee.com/corporate/index?page=content&id=KB91411 |
Had the same problem with eset security enabled. Firewall prevented access. |
i had same issue and resolve with disabling my anti virous application( symantec endpoint ) |
That helped, thanks. |
Yes, I also find that. windows security ->disable Firewall&network protection (symantec endpoint protection) |
Been dealing with troubleshooting this issue for days - literally a firewall issue. Using Avast, all you had to do was change your current network to a trusted network. |
I had to do the following when working with symantec endpoint protection: Open the app > Click on options next to network and host exploit mitigation > configure firewall rules > uncheck all options After doing that, sudo apt-get update and sudo apt-get upgrade worked. |
This article was helpful for me to resolve my issues: https://wheatevo.com/wsl-2-and-vpn/ |
In my case it was the VPN (NordVPN) preventing the connection. Temporarily putting it on hold solves the problem. |
Doing these solved my problem: Select your pc, open Virtual Switch Manager Select WSL Set to external network Select the network card the traffic runs through Then login to wsl2 terminal and configure an IP address. E.g.
This is where i found it: https://stackoverflow.com/a/62438375/10853017 |
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
Steps to reproduce
sudo apt update
, orgit clone XXX
can't connect.sudo apt update
:I checked
ipconfig
on PowerShell, and my vEthernet adapter for WSL isn't disconnected, and I can confirm that, asping 8.8.8.8
actually works.The text was updated successfully, but these errors were encountered: