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

--mount support for USB flash drive #9290

Open
byte-me-stan opened this issue Dec 9, 2022 · 13 comments
Open

--mount support for USB flash drive #9290

byte-me-stan opened this issue Dec 9, 2022 · 13 comments
Labels

Comments

@byte-me-stan
Copy link

byte-me-stan commented Dec 9, 2022

Is your feature request related to a problem? Please describe.
Not able to mount USB flash drive in wsl. It fails to attach to WSL 2. Same issue for NTFS, FAT and exFAT.

Describe the solution you'd like
USB flash drive should be able to mount using wsl --mount command and allow to access from /dev/sdb

Describe alternatives you've considered
NA

Additional context
image

Windows 11 Home
Version 22H2 OS build 22621.819

@xiao-k233
Copy link

I have this problem too!
image

@zweistein22
Copy link

same error here.

Probably related to #8885 and
#9283

@zweistein22
Copy link

here is a solution: well done
https://github.com/jovton/USB-Storage-on-WSL2

@byte-me-stan
Copy link
Author

byte-me-stan commented Dec 15, 2022

@zweistein22 kindly ignore my previous question. I found the answer. It doens't have an extension at all.

Cheers mate !

@andrsmllr
Copy link

Same here.
Mounting a USB drive to WSL works with an external USB drive (ext4 FS), but does not work with an external USB flash drive (exFAT FS).
Will try the workaround (use iSCSI to connect drive from Windows to WSL) mentioned above. It's not a solution imho.

@williamjshipman
Copy link

Mounting the root partition from a Raspberry Pi (connected via USB after running rpiboot) does not work. I get the same error code as above, even though this is an ext4 partition.

@alpinemobile
Copy link

I'm getting the same behavior that andrsmllr mentioned.
Fix this please. Thanks

@xiao-k233
Copy link

i think we can solve it
use usbipd

@rhubear25
Copy link

i think we can solve it use usbipd

According to thread (actually referenced above) ....
https://github.com/jovton/USB-Storage-on-WSL2
.... USB/IP not yet supported on WSL2 bc of existing WSL2 limitations.

The solution in said thread is to use iSCSI emulation to get around limitations of both WSL2 & USB/IP.

@ayan4m1
Copy link

ayan4m1 commented Mar 26, 2024

Same issue. Extremely disappointing. 😭 I needed a win today, but no.

@4nu81
Copy link

4nu81 commented Mar 28, 2024

Same issue.
Using iscsi is not a solution. It's a try to get away with bad design.
Very disappointing.

@pawelzwronek
Copy link

As a workaround I cloned whole sd card to a file and mounted it with sudo losetup -fP --show /mnt/d/backup/rpi5.raw
Then mount ext4 partition:

lsblk /dev/loop0
sudo mount /dev/loop0p2 /home/p/rpi_backup/ext4_mount

@jeremy-ekers
Copy link

I am getting this error with a microSD card.

C:\Users\jeremy>wmic diskdrive list brief
Caption DeviceID Model Partitions Size
asmedia ASM------ SCSI Disk Device \.\PHYSICALDRIVE1 asmedia ASM----- SCSI Disk Device 1 -------------
SDHC Card \.\PHYSICALDRIVE2 SDHC Card 2 15924142080
NVMe PC SN810 NVMe WDC 512GB \.\PHYSICALDRIVE0 NVMe PC SN810 NVMe WDC 512GB 4 512105932800

C:\Users\jeremy>wsl --mount \.\PHYSICALDRIVE2 --partition 2
The system cannot find the drive specified.
Error code: Wsl/Service/AttachDisk/HCS/0x8007000f

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