microsoft / WSL

Issues found on WSL
https://docs.microsoft.com/windows/wsl
MIT License
17.04k stars 797 forks source link

Adding internal HyperV network adapter breaks WSL networking #11263

Open tomsik-radek opened 4 months ago

tomsik-radek commented 4 months ago

Windows Version

Microsoft Windows [Version 10.0.19045.4046]

WSL Version

2.0.14.0

Are you using WSL 1 or WSL 2?

Kernel Version

5.15.133.1-microsoft-standard-WSL2

Distro Version

Oracle Linux 8.9

Other Software

No response

Repro Steps

Expected Behavior

Actual Behavior

[root@TOMSIKR-NTB2 system32]# ping 1.1.1.1 PING 1.1.1.1 (1.1.1.1) 56(84) bytes of data. From 172.17.119.3 icmp_seq=1 Destination Host Unreachable From 172.17.119.3 icmp_seq=2 Destination Host Unreachable From 172.17.119.3 icmp_seq=3 Destination Host Unreachable ^C --- 1.1.1.1 ping statistics --- 5 packets transmitted, 0 received, +3 errors, 100% packet loss, time 4146ms pipe 4 [root@TOMSIKR-NTB2 system32]# ifconfig eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 172.17.119.3 netmask 255.255.240.0 broadcast 172.17.127.255 inet6 fe80::215:5dff:fe43:5f40 prefixlen 64 scopeid 0x20 ether 00:15:5d:43:5f:40 txqueuelen 1000 (Ethernet) RX packets 0 bytes 0 (0.0 B) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 49 bytes 2686 (2.6 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10 loop txqueuelen 1000 (Local Loopback) RX packets 36 bytes 3692 (3.6 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 36 bytes 3692 (3.6 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

[root@TOMSIKR-NTB2 system32]# traceroute 1.1.1.1 traceroute to 1.1.1.1 (1.1.1.1), 30 hops max, 60 byte packets 1 TOMSIKR-NTB2 (172.17.119.3) 3142.327 ms !H 3142.315 ms !H 3142.315 ms !H

Diagnostic Logs

image

The WSL network adapter doesn't show up in ipconfig, but it seems the IP range it uses is 172.17.112.1 - 172.17.127.254, ie 172.17.112.0/20

My internal adapter is on 172.32.0.0/24

I can get both VM and WSL networking working, but I need to remove all HyperV network adapters and add them manually. That works until I need to reboot.

github-actions[bot] commented 4 months ago

Hi I'm an AI powered bot that finds similar issues based off the issue title.

Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one and thumbs upping the other issue to help us prioritize it. Thank you!

Closed similar issues:

Note: You can give me feedback by thumbs upping or thumbs downing this comment.

chanpreetdhanjal commented 4 months ago

Please follow the networking diagnostic script. https://github.com/microsoft/WSL/blob/master/CONTRIBUTING.md#collect-wsl-logs-for-networking-issues

It should create a folder like [WslNetworkingLogs-date_ver.zip]