ArchWSL
ArchWSL copied to clipboard
No longer have access to internet within WSL
Describe the issue I've had Arch installed for some time. Lately, I no longer seem to have internet access (maybe due to a Windows update?). I tried updating ArchWSL to the latest version but it didn't help. Unlike https://github.com/yuk7/ArchWSL/issues/140, my /etc/resolv.conf file looks line (see screenshot)
To Reproduce Start Bash and try to access the internet, e.g. by Pacman update (times out) or ping ("Operation not permitted" message)
Expected behavior Internet access
Screenshots
Enviroment:
- Windows build number: [e.g. 10.0.17134.228] (Type
ver
at a Command Prompt) - Security Software: [e.g. ESET Internet Security]
- WSL version 1/2: WSL2
- ArchWSL version: 21.8.28.0
- ArchWSL Installer type zip/appx/other clean/update [e.g. appx update]: zip/update
- Launcher version [e.g. 19030700]: 20013000
ping may requires root permission, could you try run ping with root? and also run cat /proc/sys/net/ipv4/ping_group_range
to double check.
not related to ping root permission...
Default Version: 2 WSL version: 0.47.1.0 Kernel version: 5.10.60.1 WSLg version: 1.0.29 Windows version: 10.0.22000.194
no internet, but it seems it's able to resolve dns queries, and alas no internet traffic.
It also happens on my PC sometimes. But it will be fine after a computer reboot.
It reboot not fix it, try to use Network Reset in Windows Setting It will reinstall all the adaptor includes Hyperv's.
try ifconfig eth0 mtu 1350
I have the same trouble and temporally fix my problem inserting nameserver 8.8.8.8
in the last line of /etc/resolv.conf
each time I turn up my laptop
I had this happen on a couple of machines, the fix was generally to run netsh winsock reset
from the windows side.
It is technically possible to hardcode the dns ns as mentioned above, but it seems like sometimes even that fails.
I'm having something like this problem too. Already tried the nameserver
option and didn't work.
I got a download speed of 2Mbit/s with speedtest-cli
, but on ubuntu, it goes above 300 Mbit/s.
After messing around, I'm getting ~300 Mbit/s on Arch too, however, some commands fail to download packages over the internet.
Cargo/Rust was very slow and it had to retry several times
NPM doesn't work at all, but Yarn did work with some packages only
asdf worked fine, even to download nodejs
and ruby
The netsh
commands sometimes work but is painful to have to restart the pc every time.
In my case netsh doesn't not work for me
@yuk7