Skip to content
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

Localhost is not accessible from windows in mirrored mode #11172

Open
1 of 2 tasks
IndigoAdagio opened this issue Feb 18, 2024 · 16 comments
Open
1 of 2 tasks

Localhost is not accessible from windows in mirrored mode #11172

IndigoAdagio opened this issue Feb 18, 2024 · 16 comments
Labels

Comments

@IndigoAdagio
Copy link

Windows Version

10.0.22631.3155

WSL Version

2.0.14.0

Are you using WSL 1 or WSL 2?

  • WSL 2
  • WSL 1

Kernel Version

5.15.133.1-1

Distro Version

Debian 11

Other Software

No response

Repro Steps

Run a Flask app in WSL and want to view it via Windows chrome.
10.12.13.129 is the IP addr of both Windows and WSL thanks to newest WSL 2.0 update

~ > python3 server.py                                                                                                                                                           
 * Serving Flask app 'Order Statistics'
 * Debug mode: on
WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead.
 * Running on all addresses (0.0.0.0)
 * Running on http://127.0.0.1:8000
 * Running on http://10.12.13.129:8000
Press CTRL+C to quit

My .wslconfig:

[experimental]
autoMemoryReclaim=dropcache
networkingMode=mirrored
dnsTunneling=true
firewall=true
autoProxy=true
sparseVhd=true
hostAddressLoopback=true

[wsl2]
localhostforwarding=true

[network]
generateResolvConf = true
generateHosts = true
[boot]
systemd=true

ifconfig in WSL:

~ ❯ ifconfig
docker0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        inet 172.17.0.1  netmask 255.255.0.0  broadcast 172.17.255.255
        ether 02:42:73:05:3d:d4  txqueuelen 0  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

eth2: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 10.12.13.129  netmask 255.255.255.0  broadcast 10.12.13.255
        inet6 fe80::9d37:c517:1515:fa5e  prefixlen 64  scopeid 0x20<link>
        ether ec:63:d7:ad:ae:a3  txqueuelen 1000  (Ethernet)
        RX packets 238  bytes 16645 (16.2 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 51  bytes 5742 (5.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<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 46  bytes 4093 (3.9 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 46  bytes 4093 (3.9 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

loopback0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether 00:15:5d:4e:8d:b7  txqueuelen 1000  (Ethernet)
        RX packets 18  bytes 1208 (1.1 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 115  bytes 19254 (18.8 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

ifconfig -all in Windows:

PS C:\Users\jianqiao.chen> ipconfig -all

Windows IP 配置

   主机名  . . . . . . . . . . . . . : DESKTOP-P30B40R
   主 DNS 后缀 . . . . . . . . . . . : xx.com.cn
   节点类型  . . . . . . . . . . . . : 混合
   IP 路由已启用 . . . . . . . . . . : 否
   WINS 代理已启用 . . . . . . . . . : 否
   DNS 后缀搜索列表  . . . . . . . . : xx.com.cn

以太网适配器 以太网:

   媒体状态  . . . . . . . . . . . . : 媒体已断开连接
   连接特定的 DNS 后缀 . . . . . . . :
   描述. . . . . . . . . . . . . . . : Intel(R) Ethernet Connection (10) I219-V
   物理地址. . . . . . . . . . . . . : 84-A9-38-57-23-2B
   DHCP 已启用 . . . . . . . . . . . : 否
   自动配置已启用. . . . . . . . . . : 是

以太网适配器 以太网 4:

   连接特定的 DNS 后缀 . . . . . . . :
   描述. . . . . . . . . . . . . . . : VirtualBox Host-Only Ethernet Adapter
   物理地址. . . . . . . . . . . . . : 0A-00-27-00-00-17
   DHCP 已启用 . . . . . . . . . . . : 否
   自动配置已启用. . . . . . . . . . : 是
   本地链接 IPv6 地址. . . . . . . . : fe80::2cbb:49ff:8d9f:62c0%23(首选)
   IPv4 地址 . . . . . . . . . . . . : 192.168.56.1(首选)
   子网掩码  . . . . . . . . . . . . : 255.255.255.0
   默认网关. . . . . . . . . . . . . :
   DHCPv6 IAID . . . . . . . . . . . : 1091174439
   DHCPv6 客户端 DUID  . . . . . . . : 00-01-00-01-2C-27-82-88-84-A9-38-57-23-2B
   TCPIP 上的 NetBIOS  . . . . . . . : 已启用

未知适配器 本地连接:

   媒体状态  . . . . . . . . . . . . : 媒体已断开连接
   连接特定的 DNS 后缀 . . . . . . . :
   描述. . . . . . . . . . . . . . . : TAP-Windows Adapter V9 for OpenVPN Connect
   物理地址. . . . . . . . . . . . . : 00-FF-F8-29-5D-19
   DHCP 已启用 . . . . . . . . . . . : 否
   自动配置已启用. . . . . . . . . . : 是

无线局域网适配器 本地连接* 9:

   媒体状态  . . . . . . . . . . . . : 媒体已断开连接
   连接特定的 DNS 后缀 . . . . . . . :
   描述. . . . . . . . . . . . . . . : Microsoft Wi-Fi Direct Virtual Adapter
   物理地址. . . . . . . . . . . . . : EC-63-D7-AD-AE-A4
   DHCP 已启用 . . . . . . . . . . . : 是
   自动配置已启用. . . . . . . . . . : 是

无线局域网适配器 本地连接* 10:

   媒体状态  . . . . . . . . . . . . : 媒体已断开连接
   连接特定的 DNS 后缀 . . . . . . . :
   描述. . . . . . . . . . . . . . . : Microsoft Wi-Fi Direct Virtual Adapter #2
   物理地址. . . . . . . . . . . . . : EE-63-D7-AD-AE-A3
   DHCP 已启用 . . . . . . . . . . . : 否
   自动配置已启用. . . . . . . . . . : 是

以太网适配器 VMware Network Adapter VMnet1:

   连接特定的 DNS 后缀 . . . . . . . :
   描述. . . . . . . . . . . . . . . : VMware Virtual Ethernet Adapter for VMnet1
   物理地址. . . . . . . . . . . . . : 00-50-56-C0-00-01
   DHCP 已启用 . . . . . . . . . . . : 是
   自动配置已启用. . . . . . . . . . : 是
   本地链接 IPv6 地址. . . . . . . . : fe80::eee:e9f5:bdda:16c4%13(首选)
   IPv4 地址 . . . . . . . . . . . . : 192.168.253.1(首选)
   子网掩码  . . . . . . . . . . . . : 255.255.255.0
   获得租约的时间  . . . . . . . . . : 2024年2月18日 16:53:26
   租约过期的时间  . . . . . . . . . : 2024年2月18日 17:53:37
   默认网关. . . . . . . . . . . . . :
   DHCP 服务器 . . . . . . . . . . . : 192.168.253.254
   DHCPv6 IAID . . . . . . . . . . . : 1174425686
   DHCPv6 客户端 DUID  . . . . . . . : 00-01-00-01-2C-27-82-88-84-A9-38-57-23-2B
   TCPIP 上的 NetBIOS  . . . . . . . : 已启用

以太网适配器 VMware Network Adapter VMnet8:

   连接特定的 DNS 后缀 . . . . . . . :
   描述. . . . . . . . . . . . . . . : VMware Virtual Ethernet Adapter for VMnet8
   物理地址. . . . . . . . . . . . . : 00-50-56-C0-00-08
   DHCP 已启用 . . . . . . . . . . . : 是
   自动配置已启用. . . . . . . . . . : 是
   本地链接 IPv6 地址. . . . . . . . : fe80::3bad:4191:8da3:db71%16(首选)
   IPv4 地址 . . . . . . . . . . . . : 192.168.133.1(首选)
   子网掩码  . . . . . . . . . . . . : 255.255.255.0
   获得租约的时间  . . . . . . . . . : 2024年2月18日 16:53:26
   租约过期的时间  . . . . . . . . . : 2024年2月18日 17:53:23
   默认网关. . . . . . . . . . . . . :
   DHCP 服务器 . . . . . . . . . . . : 192.168.133.254
   DHCPv6 IAID . . . . . . . . . . . : 1207980118
   DHCPv6 客户端 DUID  . . . . . . . : 00-01-00-01-2C-27-82-88-84-A9-38-57-23-2B
   主 WINS 服务器  . . . . . . . . . : 192.168.133.2
   TCPIP 上的 NetBIOS  . . . . . . . : 已启用

无线局域网适配器 WLAN:

   连接特定的 DNS 后缀 . . . . . . . : xx.com.cn
   描述. . . . . . . . . . . . . . . : Intel(R) Wi-Fi 6 AX201 160MHz
   物理地址. . . . . . . . . . . . . : EC-63-D7-AD-AE-A3
   DHCP 已启用 . . . . . . . . . . . : 是
   自动配置已启用. . . . . . . . . . : 是
   本地链接 IPv6 地址. . . . . . . . : fe80::9d37:c517:1515:fa5e%20(首选)
   IPv4 地址 . . . . . . . . . . . . : 10.12.13.129(首选)
   子网掩码  . . . . . . . . . . . . : 255.255.255.0
   获得租约的时间  . . . . . . . . . : 2024年2月18日 16:53:27
   租约过期的时间  . . . . . . . . . : 2024年2月20日 8:48:03
   默认网关. . . . . . . . . . . . . : 10.12.13.254
   DHCP 服务器 . . . . . . . . . . . : 10.12.13.127
   DHCPv6 IAID . . . . . . . . . . . : 166486999
   DHCPv6 客户端 DUID  . . . . . . . : 00-01-00-01-2C-27-82-88-84-A9-38-57-23-2B
   DNS 服务器  . . . . . . . . . . . : 10.12.13.127
                                       8.8.8.8
   TCPIP 上的 NetBIOS  . . . . . . . : 已启用

I've tried to disable Windows firewall but still cannot access to localhost

Expected Behavior

  1. curl http://localhost:8000 is accessible
  2. curl http://10.12.13.129:8000 is accessible

Actual Behavior

In Windows:

  1. curl http://localhost:8000 is not accessible
  2. curl http://10.12.13.129:8000 is accessible

In WSL:

  1. curl http://localhost:8000 is accessible
  2. curl http://10.12.13.129:8000 is accessible

Diagnostic Logs

No response

@Slamik
Copy link

Slamik commented Feb 27, 2024

The same. From today. Yesterday was everything ok.
domain.com points to 127.0.0.1 in hosts.
When access from another WSL2 instance - ok.
From Windows - timeout.

@simon-weber
Copy link

simon-weber commented Feb 29, 2024

Same here. It happened some time this week I think.

Switching to NAT mode fixes it, but that also makes the outbound internet connection is too unstable for me to use (it usually drops within a minute).

Here's some things I found in similar networking issues that had no effect:

  • hostAddressLoopback true/false
  • firewall=false and disabling hyper-v firewall entirely
  • windows network reset
  • reinstalling virtual machine platform optional feature
  • upgrading wsl to 2.0.14.0 (I can't remember what I was running initially, but I think it was another recent 2.0.x version)

@simon-weber
Copy link

The best workaround I've found for web dev is to run a browser inside wsl2 instead.

@rbruhn
Copy link

rbruhn commented Mar 3, 2024

@simon-weber Thanks for the NAT solution. I've been working on this for days trying to figure out why it suddenly stopped working. I have a git push on the 24th. On the 27th, Windows updated to version 23H2.

Edit: I have another Windows 11 computer that is working. I performed all the current Window updates and WSL is still working correctly. Meaning, WSL is mirrored and I can reach domain names. So it's not the update.

I took a look at the differences between the two and it appears the non-working is coming up short when creating the network connections. Not sure why or how to fix it.

WSL Mirrored Working: https://gist.github.com/rbruhn/348eaadddedf415472ab6aaf0823a572
WSL Mirrored Not Working: https://gist.github.com/rbruhn/c05f72cf9fdbe000852a080bf725ff14

@rbruhn
Copy link

rbruhn commented Mar 4, 2024

I exported my working version of ubuntu 20.04 and moved it over to the other computer. Removed the one that wasn't working, then imported. I got everything up and working. Then, I performed "apt update && apt upgrade"

The upgrade broke it again. So, something in the upgrading of Ubuntu is breaking WSL.

@deadcoder0904
Copy link

deadcoder0904 commented Mar 4, 2024

I'm not sure if I'm using mirrored mode but I have nothing in my .wslconfig.

I'd love for localhost to work. Currently, I have to point it to 0.0.0.0 which is inconvenient. It took an insane amount of my time with redis service in docker. Even there I had to change REDIS_HOST=localhost to REDIS_HOST=0.0.0.0 which is annoying..

Edit: Even 0.0.0.0 didn't work. I had to use my ip to get redis working.

Another Edit: Even my ip didn't work. I gues my error was due to this which I feel is unrelated but idk.

Please make this simple. Its annoying to use Windows because of these random issues.

@Slamik
Copy link

Slamik commented Mar 4, 2024

I exported my working version of ubuntu 20.04 and moved it over to the other computer. Removed the one that wasn't working, then imported. I got everything up and working. Then, I performed "apt update && apt upgrade"

The upgrade broke it again. So, something in the upgrading of Ubuntu is breaking WSL.

True. I did an apt upgrade before.

@Slamik
Copy link

Slamik commented Mar 4, 2024

I filter out updates history not related to Ubuntu. The list of packages that may cause the issue:

- netplan.io:amd64 (0.104-0ubuntu2~20.04.2, 0.104-0ubuntu2~20.04.4)
- cloud-init:amd64 (23.3.1-0ubuntu1~20.04.1, 23.4.3-0ubuntu0~20.04.1)
- systemd:amd64 (245.4-4ubuntu3.22, 245.4-4ubuntu3.23)
- systemd-timesyncd:amd64 (245.4-4ubuntu3.22, 245.4-4ubuntu3.23)
- libsystemd0:amd64 (245.4-4ubuntu3.22, 245.4-4ubuntu3.23)
- libpam-systemd:amd64 (245.4-4ubuntu3.22, 245.4-4ubuntu3.23)
- libnss-systemd:amd64 (245.4-4ubuntu3.22, 245.4-4ubuntu3.23)
- systemd-sysv:amd64 (245.4-4ubuntu3.22, 245.4-4ubuntu3.23)

UPD.

Downgrade all these packages but didn't achieve nothing.

apparmor/focal-updates 2.13.3-7ubuntu5.3 amd64 [upgradable from: 2.13.3-7ubuntu5]
cloud-init/focal-updates 23.4.4-0ubuntu0~20.04.1 all [upgradable from: 23.1.2-0ubuntu0~20.04.2]
libapparmor1/focal-updates 2.13.3-7ubuntu5.3 amd64 [upgradable from: 2.13.3-7ubuntu5]
libnetplan0/focal-updates 0.104-0ubuntu2~20.04.4 amd64 [upgradable from: 0.99-0ubuntu1]
libnss-systemd/focal-updates 245.4-4ubuntu3.23 amd64 [upgradable from: 245.4-4ubuntu3]
libpam-systemd/focal-updates 245.4-4ubuntu3.23 amd64 [upgradable from: 245.4-4ubuntu3]
libsystemd0/focal-updates 245.4-4ubuntu3.23 amd64 [upgradable from: 245.4-4ubuntu3]
netplan.io/focal-updates 0.104-0ubuntu2~20.04.4 amd64 [upgradable from: 0.99-0ubuntu1]
systemd-sysv/focal-updates 245.4-4ubuntu3.23 amd64 [upgradable from: 245.4-4ubuntu3]
systemd-timesyncd/focal-updates 245.4-4ubuntu3.23 amd64 [upgradable from: 245.4-4ubuntu3]
systemd/focal-updates 245.4-4ubuntu3.23 amd64 [upgradable from: 245.4-4ubuntu3]

@rbruhn
Copy link

rbruhn commented Mar 4, 2024

@Slamik These are the packages that show in mine before upgrade. When I have time, I might go through them one by one.

bind9-dnsutils/focal-updates,focal-security 1:9.16.48-0ubuntu0.20.04.1 amd64 [upgradable from: 1:9.16.1-0ubuntu2.16]
bind9-host/focal-updates,focal-security 1:9.16.48-0ubuntu0.20.04.1 amd64 [upgradable from: 1:9.16.1-0ubuntu2.16]
bind9-libs/focal-updates,focal-security 1:9.16.48-0ubuntu0.20.04.1 amd64 [upgradable from: 1:9.16.1-0ubuntu2.16]
binutils-common/focal-updates,focal-security 2.34-6ubuntu1.9 amd64 [upgradable from: 2.34-6ubuntu1.8]
binutils-x86-64-linux-gnu/focal-updates,focal-security 2.34-6ubuntu1.9 amd64 [upgradable from: 2.34-6ubuntu1.8]
binutils/focal-updates,focal-security 2.34-6ubuntu1.9 amd64 [upgradable from: 2.34-6ubuntu1.8]
cloud-init/focal-updates 23.4.4-0ubuntu0~20.04.1 all [upgradable from: 23.3.3-0ubuntu0~20.04.1]
dns-root-data/focal-updates 2023112702~ubuntu0.20.04.1 all [upgradable from: 2019052802]
dnsmasq-base/focal-updates,focal-security 2.90-0ubuntu0.20.04.1 amd64 [upgradable from: 2.80-1.1ubuntu1.7]
gir1.2-nm-1.0/focal-updates,focal-security 1.22.10-1ubuntu2.4 amd64 [upgradable from: 1.22.10-1ubuntu2.3]
less/focal-updates,focal-security 551-1ubuntu0.2 amd64 [upgradable from: 551-1ubuntu0.1]
libbinutils/focal-updates,focal-security 2.34-6ubuntu1.9 amd64 [upgradable from: 2.34-6ubuntu1.8]
libctf-nobfd0/focal-updates,focal-security 2.34-6ubuntu1.9 amd64 [upgradable from: 2.34-6ubuntu1.8]
libctf0/focal-updates,focal-security 2.34-6ubuntu1.9 amd64 [upgradable from: 2.34-6ubuntu1.8]
libhashkit2/focal 1.1.4-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 1.1.3-1+ubuntu20.04.1+deb.sury.org+1]
libmemcached11/focal 1.1.4-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 1.1.3-1+ubuntu20.04.1+deb.sury.org+1]
libnm0/focal-updates,focal-security 1.22.10-1ubuntu2.4 amd64 [upgradable from: 1.22.10-1ubuntu2.3]
libssl-dev/focal-updates,focal-security 1.1.1f-1ubuntu2.22 amd64 [upgradable from: 1.1.1f-1ubuntu2.21]
libssl1.1/focal-updates,focal-security 1.1.1f-1ubuntu2.22 amd64 [upgradable from: 1.1.1f-1ubuntu2.21]
libtiff5/focal-updates,focal-security 4.1.0+git191117-2ubuntu0.20.04.12 amd64 [upgradable from: 4.1.0+git191117-2ubuntu0.20.04.11]
libuv1/focal-updates,focal-security 1.34.2-1ubuntu1.5 amd64 [upgradable from: 1.34.2-1ubuntu1.3]
linux-libc-dev/focal-updates,focal-security 5.4.0-172.190 amd64 [upgradable from: 5.4.0-171.189]
ltrace/focal-updates 0.7.3-6.1ubuntu1.1 amd64 [upgradable from: 0.7.3-6.1ubuntu1]
mongodb-org-database-tools-extra/focal 4.4.29 amd64 [upgradable from: 4.4.28]
mongodb-org-mongos/focal 4.4.29 amd64 [upgradable from: 4.4.28]
mongodb-org-server/focal 4.4.29 amd64 [upgradable from: 4.4.28]
mongodb-org-shell/focal 4.4.29 amd64 [upgradable from: 4.4.28]
mongodb-org-tools/focal 4.4.29 amd64 [upgradable from: 4.4.28]
mongodb-org/focal 4.4.29 amd64 [upgradable from: 4.4.28]
network-manager/focal-updates,focal-security 1.22.10-1ubuntu2.4 amd64 [upgradable from: 1.22.10-1ubuntu2.3]
ngrok/buster 3.6.0 amd64 [upgradable from: 3.5.0]
openssl/focal-updates,focal-security 1.1.1f-1ubuntu2.22 amd64 [upgradable from: 1.1.1f-1ubuntu2.21]
php8.1-mongodb/focal 1.17.2-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 1.17.0-1+ubuntu20.04.1+deb.sury.org+1]
php8.2-mongodb/focal 1.17.2-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 1.17.0-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-cli/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-common/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-curl/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-dev/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-fpm/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-mbstring/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-mongodb/focal 1.17.2-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 1.17.0-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-mysql/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-opcache/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-readline/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-sqlite3/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-xml/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3-zip/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 amd64 [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
php8.3/focal 8.3.3-1+ubuntu20.04.1+deb.sury.org+1 all [upgradable from: 8.3.2-1+ubuntu20.04.1+deb.sury.org+1]
python3-cryptography/focal-security 2.8-3ubuntu0.3 amd64 [upgradable from: 2.8-3ubuntu0.2]
tcpdump/focal-updates 4.9.3-4ubuntu0.3 amd64 [upgradable from: 4.9.3-4ubuntu0.2]
tzdata/focal-updates,focal-security 2024a-0ubuntu0.20.04 all [upgradable from: 2023d-0ubuntu0.20.04]
unzip/focal-updates 6.0-25ubuntu1.2 amd64 [upgradable from: 6.0-25ubuntu1.1]

@yunsii
Copy link

yunsii commented Mar 26, 2024

Any progress here?

@rbruhn
Copy link

rbruhn commented Mar 26, 2024

I gave up. As much as I tried to pinpoint which one, I never could. For now, I'm simply using NAT mode.

@Slamik
Copy link

Slamik commented Mar 28, 2024

I gave up. As much as I tried to pinpoint which one, I never could. For now, I'm simply using NAT mode.

The same :)

@cveld
Copy link

cveld commented Jun 21, 2024

Just recently access from Windows to a WSL service stopped working when using mirrored mode. Neither using the full eth ip yields results. It yields in a long time-out. Longer than if I curl to a port that is not used. 20 secs vs 2 secs.
I also reverted to NAT mode. But now I can't access Windows services from WSL through localhost anymore. Ideally mirrored mode should just work. I noticed that I have 3 eth adapters with eth0 being the correct one. Maybe wsl is not connecting to the correct eth adapter? Also see #10884

@Soappyooo
Copy link

A possible solution for me is #11600 (comment), turning on the mobile hotspot of Windows makes localhost services on Windows accessible for WSL.

@shigenobuokamoto
Copy link

in case accessing from Windows, does doing the following make any difference?

curl.exe http://localhost:8000

@CatalinFetoiu
Copy link
Collaborator

Hi. Can you please collect networking logs by following the instructions below?
https://github.com/microsoft/WSL/blob/master/CONTRIBUTING.md#collect-wsl-logs-for-networking-issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests