- Tools to Access The Linux File System from Windows
- Differences between Windows and Linux file systems
- Read-Only Access to Linux Filesystem from Windows
- Read & Write Access to Linux Filesystem from Windows
- A Deep Dive Into How WSL Allows Windows to Access Linux Files
- Let’s jump in!
- How does this story fit in with WSL 2?
- What would you like to see next?
- Access Linux filesystems in Windows and WSL 2
- Getting started
- Accessing these files with File Explorer
- Limitations
- Give us your feedback!
Tools to Access The Linux File System from Windows
One of the most popular problems with dual-booting Linux and Windows operating systems is the ability to access Windows files from within Linux but the inability of the reverse; this is due to the way Linux and Windows file systems are set up.
The point of today’s articles is to recommend the most reliable tools that you can install to easily access your Linux files from within your Windows installation. But first, you should know how the file system in Windows and Linux differ.
Differences between Windows and Linux file systems
- The Linux filesystem is case-sensitive so you can have file names like fossmint.html and Fossmint.html in the same directory. This can’t happen on Windows because the file system is not case-sensitive as sees both file names as the same.
- Windows file systems are in the FAT (FAT12, FAT16, and FAT32) and NTFS formats while Linux file systems are in Ext2, Ext3, Ext4, JFS, XFS, etc.
- Windows disks are partitioned and given letters e.g. C: for local disk and E: for a removable disk. In Linux, everything is under the root directory denoted by / and all devices are treated as files. E.g. /dev/cdrom for removable media.
- Linux doesn’t lock access to files as often as Windows and thus allows files to be deleted in situations wherein they wouldn’t be if the user was on Windows. For example, on Windows, you can’t delete a video file that was previously running a VLC without quitting the app. On Linux, you might even be able to delete the file while it’s still running in VLC.
So the most important home point is that while Linux has native support for Windows file systems i.e. NTFS and FAT, we need a 3rd party application to access Linux files from Windows.
These are the best tools available for free.
Read-Only Access to Linux Filesystem from Windows
DiskInternals Linux Reader allows users safe and quick read-only access to Ext2, Ext3, and Ext4 Linux files using a UI similar to that of the default Windows Explorer to view and extract files. It is free software but offers a pro version with extra features.
Explore2fs is a GUI drag& drop file explorer for Ex2 and Ex3 file systems. It runs on all Windows versions to allow users to read files but without the ability to make any changes.
Read & Write Access to Linux Filesystem from Windows
EX2 Installable File System for Windows is a freeware that provides Windows users will full read and write access to Linux Ext2 volumes by installing a pure kernel mode file system driver which extends the Windows file system to include the Ext2 file system.
With EX2 IFS, you can view Linux partitions in the disk management application and assign drive letters to them. Mind you, Ext2 Volume manager and Ext2 IFS need to be run with Compatibility mode enabled on Windows 8 and later.
Ext2Fsd is an open-source Linux Ext2 and Ext3 file system driver for all Windows versions with the option to access files in both read-only and read & write modes. However, Ext4 file systems load in read-only mode by default due to Ext2Fsd limited support.
Experts advise that accessing files from other operating systems is best done in read-only mode in other to avoid unfixable mistakes or data corruption. While the odds of such happening are slim in my opinion, always be careful when working with files. I’m not worried because it’s not the same as playing around in sever directories.
I hope this article is useful to you in getting on with your daily tasks. Do you already use any of the software on the list? Or do you have notable mentions to suggest? Add yours in the section below.
A Deep Dive Into How WSL Allows Windows to Access Linux Files
Three months ago, we announced that the Windows Subsystem for Linux will be able to access Linux files from Windows in the blog post: What’s new for WSL in Windows 10 version 1903, and in today’s post we will be showing you how we made these changes possible.
Let’s jump in!
We’re continuing our whiteboard series of deep dives (you can find the full list here) with a new video where Sven Groot and Craig Loewen explain the full architecture behind this new feature. You can expect to learn about how WSL currently accesses Linux files, how we’ve added a 9P file server into the init process of each Linux distro, and how Windows interacts with that 9P file server to interact with Linux files inside of your distro. So, grab a coffee and a snack, sit down, relax, and enjoy this look behind the scenes of WSL!
How does this story fit in with WSL 2?
We don’t explicitly mention WSL 2 in the video above as at the time of filming we were still finalizing the details behind WSL 2, and ultimately there are very little changes to our explanation of how Linux files are accessed from Windows with the new architecture. The only difference from the explanation in the video, is where the Linux files themselves are stored. In WSL 1, these Linux files are stored in the Windows drive (which uses the NT file system), while in WSL 2 these Linux files are stored in a virtual hard disk which uses the EXT4 file system. Every other detail on how the files are accessed remains the same.
What would you like to see next?
If you have more questions about how we use a 9P file server, accessing Linux files, or just about WSL in general you can find a list of our team members on twitter here! Please feel free to reach out to ask us any questions, and give suggestions on any other deep dives that you’d be interested in seeing.
Access Linux filesystems in Windows and WSL 2
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
wmic diskdrive list brief
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.