You can now access Linux filesystems in Windows 10 and WSL 2 Insider

    You can now access Linux filesystems in Windows 10 and WSL 2

    You can now access Linux filesystems in Windows 10 and WSL 2

    Category: Insider
    Posted: 10 Sep 2020

    Starting with Windows Insiders preview build 20211, WSL 2 will be offering a new feature: wsl --mount. This new parameter allows a physical disk to be attached and mounted inside WSL 2, which enables you to access filesystems that arenít natively supported by Windows (such as ext4).

    So, if youíre dual booting with Windows & Linux using different disks, you can now access your Linux files from Windows!

    Getting started

    To mount a disk, open a PowerShell window with administrator privileges and run:

    wsl --mount <DiskPath>

    To list the available disks in Windows, run:

    wmic diskdrive list brief

    To unmount and detach the disk from WSL 2, run

    wsl --unmount <Diskpath>

    The disks paths are available under the ĎDeviceIDí columns. Usually under the \\.\\\.\PHYSICALDRIVE* format. Below is an example of mounting a specific partition of a given hard disk into WSL and browsing its files.



    Accessing these files with File Explorer

    Once mounted, itís also possible to access these disks through the Windows explorer by navigating to \wsl$ and then to the mount folder.



    Limitations

    By default, wsl --mount attempts to mount the disk as ext4. To specify a filesystem, or for more advanced scenarios, check out Mount a disk in WSL 2.

    Also please note that this feature comes with the limitation that only physical disks can be attached to WSL 2. At this time, itís not possible to attach a single partition. More details on the limitations here.

    Give us your feedback!

    If you run into any issues, or have feedback for our team please file an issue on our Github , and if you have general questions about WSL you can find all of our team members that are on Twitter on this twitter list.



    Pierre Boulay
    Software Engineer II, Linux on Windows


    Source: https://devblogs.microsoft.com/comma...ows-and-wsl-2/
    Brink's Avatar Posted By: Brink
    10 Sep 2020


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 11:44.
Find Us




Windows 10 Forums