-
Notifications
You must be signed in to change notification settings - Fork 811
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
Drives other than C: are not mounted in /mnt #1079
Comments
Sounds like #891, if the system thinks the drives are removable. If they are not removable, but mounted after the first long-running bash.exe starts, the WSL environment won't see them (e.g mounting a drive with VeraCrypt). The workaround is to mount the drives before using bash.exe. Or maybe non-NTFS drives are not mounted, I can't find a reference for that... Found it: only NTFS and ReFS filesystems are supported, which makes it similar to #801. Not saying it's a good thing that only NTFS is supported; it certainly would make things much more usable if (a) any drive Windows can mount would mount in WSL somehow and (b) linux filesystem drivers like ext3/4 could be used to mount other drives into WSL. |
I do not think the system sees them as removable, they have the fixed drive icon and don't have an "Eject" option. They are not mounted in any special way either. |
Currently only fixed NTFS drives show up under /mnt/. |
@streamholder This is my /mnt: All the drive is NTFS, X is an external unit (I don't know what program mounts it). |
@benhillis I understand that. My D: and V: drives are fixed. |
You also said they are exFAT (not NTFS) correct? That's why they aren't showing up. |
@benhillis That is correct, and that also doesn't make the removable drives by any classification. Windows doesn't look at the filesystem type to decide whether a drive is fixed or removable (rightly so). The fact that Bash On Windows (or WSL, whichever is at fault) does is a bug. |
Sorry I inadvertently closed this issue (clicked wrong button) although this issue is discussed elsewhere. WSL currently only supports NTFS drives under /mnt/. To clarify - In order for a drive to show up under /mnt/ it must meet the following criteria:
|
@benhillis "1. The drive must be a fixed drive" -> my "x" drive is an external, USB (2.0) drive and is mounted under /mnt. |
@benhillis I did not know about the second requirement. I tried to make a symlink and a junction somewhere on the C drive to the ExFAT drives, but either way it just doesn't show up in Bash. |
@streamholder you need to format using NTFS. |
@iz0eyj Yeah - that would be the obvious solution. However, that is not a possibility for me. Those hard disk contain data that has to be easily accessible from other platforms, and ExFAT is the only out-of-the-box solution to do that. |
@streamholder it would be possible for you to create a little NTFS partition for data exchange between WSL and Win? |
@iz0eyj Definitely, however that would not be an ideal solution at all, and furthermore it kind of defies the whole usefulness of WSL. Rebooting into Linux whenever I need Bash would be less of a hassle than manually copying data I need to use to a NTFS partition. |
@streamholder All platforms (I think except for FreeBSD maybe) support NTFS read/write now. On Mac, you can install a FUSE module or install the third-party ntfs-3g driver, and ntfs-3g on Linux. |
Would appreciate some advice on how to mount another drive in Bash. I have a dualbooted Ubuntu and Windows and I want to get Windows Bash to access the Linux partition. I'm using the Ext2Fsd program in Windows to mount the Linux partition at D:// but I don't know how to make it available to Bash. I tried making a link but it is the |
@MaxPleaner -- WSL unfortunately only supports / allows access to NTFS partitions right now. |
Is this being worked on? |
@alkis kinda. Right now each filesystem driver for win32 seems like it might needs to have its own compatibility layer registered generically somehow through drvfs or potentially could make use of an unstable and undocumented kernel-side API to provide functionality to the Linux subsystem. Right now Microsoft's solution allows mounting of most of the filesystems with Windows built-in Win32 support (CDFS, Samba network shares, NTFS, and FAT32) with sort of stripped-down functionality using Microsoft's There are a couple of other topics about this (requests to expose the kernel-side API for driver makers and to add things like the drvfs driver sources to the KMDF) as well as requests for direct support for things like FUSE (possibly implemented on top of the gvflt filter driver from GVFS). A lot of progress was made only a few builds ago that added all of the FAT32, SAMBA, and CDFS stuff. Mostly speculation, but it seems like they're making moves on these things. |
Under WSL, add to /etc/fstab then back to bash:
voila! /mnt/d now points to d: It works even with non fixed drives |
Given that the OP predates the WSL filesystem improvements introduced in 16176 I think we can call this closed. It won't mount exFAT fixed drives automatically via |
I recently ran into this error as well. What helped me solving this problem was restarting the
|
When will this issue be fixed? |
wsl supports loading an fstab, so make one |
Windows and WSL2 now supports mouting Linux filesystems https://devblogs.microsoft.com/commandline/access-linux-filesystems-in-windows-and-wsl-2/ |
I created the partition after installing WSL. This helped me might help others as well:-
To Unmount :-
|
this worked for me. Please mention this has to be run in powershell |
If folks are experiencing a problem with |
@therealkenc I just ran into the same issue with WSL2 and other people have too - see #6286 |
When do we use unmount? when we want to unplug the external ssd? |
It should be |
Drives other than the C: drives are not mounted under /mnt.
I have two more fixed drives, D: and V:, and they are not being mounted. They are both exFAT drives.
I'm on Windows 14393.105.
The text was updated successfully, but these errors were encountered: