-
Notifications
You must be signed in to change notification settings - Fork 854
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
WSL 2 mirrored networking breaks NFS mounts (“Connection timed out”) #12508
Comments
Logs are required for review from WSL teamIf this a feature request, please reply with '/feature'. If this is a question, reply with '/question'. How to collect WSL logsDownload and execute collect-wsl-logs.ps1 in an administrative powershell prompt:
The script will output the path of the log file once done. If this is a networking issue, please use collect-networking-logs.ps1, following the instructions here Once completed please upload the output files to this Github issue. Click here for more info on logging View similar issuesPlease 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! Open similar issues:
Closed similar issues:
|
Logs attached |
Diagnostic information
|
Just want to confirm that I am seeing the same thing after upgrading wsl with bridged mode being deprecated. NFS is completely broken in wsl2 with mirrored networking, works fine on my other Linux boxes. Info:
Logs: WslLogs-2025-01-31_18-26-08.zip Networking Logs: WslNetworkingLogs-2025-01-31_18-28-01.zip |
same issue |
BUMP. Is there any work being done to address this? To deprecate Bridged mode and not have a working replacement (at least not working with NFS as it previously did) in Mirrored mode is a shame. Pretty much every file I want to access within wsl2 is located on my Unraid NAS so wsl2 is just dead for me until/if someone comes up with a fix for this weird issue. |
Is anyone able to get this to work with even NAT networking? Seems like a firewall issue because I can't get it to work with NAT networking either. sudo mount -v NFS_HOST_IP:/mnt/user/data/media/movies /mnt/nfs/movies mount.nfs: timeout set for Tue Feb 11 15:57:23 2025
mount.nfs: trying text-based options 'vers=4.2,addr=NFS_HOST_IP,clientaddr=NFS_CLIENT_IP'
mount.nfs: mount(2): Invalid argument
mount.nfs: trying text-based options 'vers=4,minorversion=1,addr=NFS_HOST_IP,clientaddr=NFS_CLIENT_IP'
mount.nfs: mount(2): Operation not permitted
mount.nfs: trying text-based options 'addr=NFS_HOST_IP'
mount.nfs: prog 100003, trying vers=3, prot=6
mount.nfs: trying NFS_HOST_IP prog 100003 vers 3 prot TCP port 2049
mount.nfs: prog 100005, trying vers=3, prot=17
mount.nfs: trying NFS_HOST_IP prog 100005 vers 3 prot UDP port 42220
mount.nfs: mount(2): Permission denied
mount.nfs: Operation not permitted Does this have something to do with Hyper-V firewall? Bridged mode this was working fine but with NAT or mirrored I am unable to get NFS mounts to work. Sigh. Edit: I was able to get nfs mounts to work using "insecure" option on the NFS host with NAT networking (I'm assuming this works for mirrored as well). Bridged didn't require this since there was no port translation. So we're back to square one of broken NFS on WSL2 with mirrored networking (where there should be no port translation going on). |
Windows Version
Microsoft Windows [Version 10.0.26100.2894]
WSL Version
WSL version: 2.3.26.0 Kernel version: 5.15.167.4-1 WSLg version: 1.0.65 MSRDC version: 1.2.5620 Direct3D version: 1.611.1-81528511 DXCore version: 10.0.26100.1-240331-1435.ge-release Windows version: 10.0.26100.2894
Are you using WSL 1 or WSL 2?
Kernel Version
5.15.167.4-microsoft-standard-WSL2
Distro Version
Ubuntu 22.04.5 LTS
Other Software
When using WSL 2 mirrored networking mode, any attempt to mount an NFS share from within WSL 2 fails with errors:
Key Observations
Request
Thank you for looking into this issue!
Repro Steps
Enable mirrored networking (set networkingMode=mirrored in .wslconfig).
Install NFS client tools in WSL:
Attempt to mount an exported NFS share:
The command eventually returns an error:
Expected Behavior
The NFS share should mount successfully inside WSL 2, just like it does from a Raspberry Pi or other standard Linux environment on the same LAN.
Actual Behavior
The mount attempt times out.
No traffic is visibly blocked by the Windows Firewall (which I turned off for testing).
Reverting to non-mirrored networking mode in .wslconfig and restarting WSL immediately fixes the issue.
So it appears mirrored networking specifically interferes with NFS.
Diagnostic Logs
From wsl client with mirrored networking:
After disabling mirrored networking:
The text was updated successfully, but these errors were encountered: