WSL2 Mirrored Mode - No Interfaces except LOCALHOST
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 33.7k
- Forks
- 1.8k
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 116
Description
### Windows Version
Windows 11 GAC 23H2 (cmd.exe /c ver reports Microsoft Windows [Version 10.0.22631.5335]?)
### WSL Version
0.0.0.0
### Are you using WSL 1 or WSL 2?
- [x] WSL 2
- [ ] WSL 1
### Kernel Version
5.15.167.4-1
### Distro Version
Ubuntu 22.04.5 LTS; Red Hat Enterprise Linux release 9.5 (Plow)
### Other Software
WSL version: 2.4.13.0
Kernel version: 5.15.167.4-1
WSLg version: 1.0.65
MSRDC version: 1.2.5716
Direct3D version: 1.611.1-81528511
DXCore version: 10.0.26100.1-240331-1435.ge-release
Windows version: 10.0.22631.5335
When I start WSL.exe with "networkMode=mirrored", only the loopback interface is created. (Running wsl-vpnkit, the wsltap interface is also created, but fails since it cannot reach the network.)
Per [#10650](https://github.com/microsoft/WSL/issues/10650), I have tried it with "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip6\Parameters" set to 0xFF (default on our laptops), and set to 0x20. After terminating the distros and shutting down and restarting WSL.exe, the problem recurs on both distros (Ubuntu, RHEL).
I have verified that "Windows Defender Firewall with Advanced Security" is off (corporate policy).
Per #[12399](https://github.com/microsoft/WSL/issues/12399), I ran a webserver on Windows. It is accessible from Windows at http://127.0.0.1:8100. It is not accessible from either distro at any of the addresses configured on loopback: 0.0.0.0, 127.0.0.1, or 10.255.255.254.
Per #[12632](https://github.com/microsoft/WSL/issues/12632), Does not seem to be relevant, but does mention wsl-vpnkit. I believe the wsl-vpnkit issue is a symptom, not a cause.
### Repro Steps
From windows:
wsl.exe --terminate -D RHEL91
wsl.exe --shutdown
(make config changes)
wsl.exe -d RHEL91 date
Inside RHEL91:
```bash
$ ip addr show
1: lo: mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet 10.255.255.254/32 brd 10.255.255.254 scope global lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
973: wsltap: mtu 1500 qdisc noop state DOWN group default qlen 1000
$ ip route show
$
```
In addition, the linux NetworkManager tools (nmtui, nmcli) do not see any links, so you cannot "Activate A Connection".
Additionally, running with networkMode=nat is not fully working. That mode worked fine last week. Corporate installed updates in the last week, but I do not know which ones. (I tried mirrored mode since nat mode only shows eth0, does not set a default route, and has connectivity problems to some networks. That's an issue for another day!)
### Expected Behavior
I expect ip link show to have 3 interfaces: loopback, eth0, and wsltap. I expect a subnet limited route on eth0, and a default route on eth0.
### Actual Behavior
```bash
$ ip addr show
1: lo: mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet 10.255.255.254/32 brd 10.255.255.254 scope global lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
973: wsltap: mtu 1500 qdisc noop state DOWN group default qlen 1000
```
### Diagnostic Logs
.wslconfig:
```
[wsl2]
autoProxy=false
guiApplications=true
[experimental]
autoMemoryReclaim=gradual
networkingMode=mirrored
``
Network logs will be incomplete. WSL distros are not installed for my Admin account, and it does not have internet access. I ran it as my ordinary user account.
[WslNetworkingLogs-2025-05-15_11-34-33.zip](https://github.com/user-attachments/files/20231014/WslNetworkingLogs-2025-05-15_11-34-33.zip)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the .wslconfig networkingMode=mirrored setting and reproduce the issue using the supplied wsl.exe commands, ip addr show, and ip route show steps. Inspect the attached WSL networking logs and compare the mirrored-mode setup with the expected eth0, wsltap, subnet route, and default route. Done means both distros expose the expected interfaces and routes with working connectivity.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- linux
- Domain
- networking, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 47/100