Quantcast
Channel: Active questions tagged windows-subsystem-for-linux - Ask Ubuntu
Viewing all articles
Browse latest Browse all 2821

NAS drive will not mount on some WSL2 systems

$
0
0

The same commands for mounting a NAS drive have completely different results.I have data from two computers, both are WSL2 and Windows 11.

The only clue I've come up with is the updated Linux kernal (5.15) in the system that doesn't work like the others.

Looking at the Linux "mount" docs, "drvfs" isn't a valid type value, yet it'sbeen working for years on the other systems, including WSL1.

Other than understanding what is going on, my goal is to detect which systems need which command. The "MUSICCOMP-3020" is the new one and the only one that doesn't work with the "-t drvfs". I run a Python program to mount the NAS on these and a couple of other systems, so need to reliably detect which command to use, or find a command that works on all WSL2 installations.

The captured data follows. It is showing the responses same two commands on the two computers: "MUSICCOMP-3020" and "XPS8950".

======================================

On MUSICCOMP-3020:

uname -a

Linux MUSICCOMP-3020 5.15.133.1-microsoft-standard-WSL2 #1 SMP Thu Oct 5 21:02:42 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

This works:

 sudo mount -t cifs -o guest,uid=1000,iocharset=utf8 //192.168.2.202/EX2Ult /mnt/ex2ult

This fails:

 sudo mount -t drvfs -o rw,noatime,uid=1000,gid=1000 '\\192.168.2.202\\EX2Ult' /mnt/ex2ult

The error response is:

<3>WSL (564) ERROR: MountWithRetry:307: mount(drvfs, /mnt/ex2ult, 9p, 0x00000400, cache=mmap,msize=262144,trans=virtio,aname=drvfs;path=UNC\192.168.2.202\EX2Ult;uid=1000;gid=1000;symlinkroot=/mnt/) failed: Invalid argument

======================================

On XPS8950:

uname -a

Linux XPS8950 5.10.16.3-microsoft-standard-WSL2 #1 SMP Fri Apr 2 22:23:49 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux

This works:

 sudo mount -t drvfs -o rw,noatime,uid=1000,gid=1000 '\\192.168.2.202\\EX2Ult' /mnt/ex2ult

This fails:

 sudo mount -t cifs -o guest,uid=1000,iocharset=utf8 //192.168.2.202/EX2Ult /mnt/ex2ult

The error response is:

mount: /mnt/ex2ult: bad option; for several filesystems (e.g. nfs, cifs) you might need a /sbin/mount. helper program.


Viewing all articles
Browse latest Browse all 2821

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>