sudo lsusb
returns:
unable to initialize libusb: -99
What should i do to enable usb access on bash?
Support for connecting USB devices is not natively available in WSL, so you will need to install the open-source usbipd-win project.
Select the bus ID of the device you'd like to attach to WSL and run this command. You'll be prompted by WSL for a password to run a sudo command. From within WSL, run lsusb to list the attached USB devices. You should see the device you just attached and be able to interact with it using normal Linux tools.
If USB is not detected in Ubuntu or other distros, it could be due to an issue with the USB port. The best way to check this quickly is to simply use a different USB port on the same computer. If the USB hardware is now detected, then you know you have a problem with the other USB port.
Good news, it is now possible to mount USB media (including FAT formated) and network shares with drvfs on Windows 10:
Mount removable media: (e.g. D:)
$ sudo mkdir /mnt/d $ sudo mount -t drvfs D: /mnt/d
To safely unmount
$ sudo umount /mnt/d
You can also mount network shares without smbfs:
$ sudo mount -t drvfs '\\server\share' /mnt/share
You need at least Build 16176 so you might have to opt-in to the Windows Insider programm and then update Windows. Source: https://blogs.msdn.microsoft.com/wsl/2017/04/18/file-system-improvements-to-the-windows-subsystem-for-linux/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With