WSL mount external and network drives
Windows Subsystem for Linux can mount SD card, USB thumb flash drives, CD / DVD drives (CDFS), network drives, and UNC paths via “wsl –mount”. WSL can mount disk formats FAT, ExFAT or NTFS and VHD images.
For Windows 10 or those not desiring to use “wsl –mount” to mount external drives, the following can be used instead.
If Windows changes the external drive letter on a subsequent session, you need to repeat this process. These commands are typed into the Windows Subsystem for Linux Terminal.
Create a mount location in WSL and mount the drive (assume the drive shows in Windows as “F:”):
mkdir /mnt/f
mount -t drvfs f: /mnt/f
One can then create and manipulate files from both Windows and WSL on the same external drive.
For network storage, assume networked storage is already showing in Windows under \\server\share
and we want to access this network storage from WSL as /mnt/share
.
Create a mount location in WSL and mount the network share:
mkdir /mnt/share
mount -t drvfs '\\server\share' /mnt/share
Reference: external drive mount on WSL