The Windows Subsystem for Linux lets you run command line Linux tools in Windows 10 by installing a full Linux system that can run alongside Windows. In May Microsoft announced that a major update to the Windows Subsystem for Linux was on the way, and now the first preview of WSL 2 is available.
It’s baked into the latest Windows 10 Insider Preview Build, which means that members of the Windows Insider program can take it for a spin once Preview Build 181917 (20H1) is installed.
One of the biggest changes is that WSL 2 comes with its own Linux kernel, which means that system calls no longer need to be intercepted and translated to interface with the Windows NT kernel.
Microsoft says it’s also improved file system performance significantly.
Some apps that wouldn’t work with the original version of WSL should work with WSL 2. And some apps that did work before should run faster now. Microsoft says some operations, such as unpacking a zipped tarball, are up to 20 times faster. Other tasks, such as using git clone, npm install, or cmake can be anywhere from 2 to 5 times faster.
Microsoft notes that in order to take advantage of the speedier file system performance, you’ll want to make sure to put files you plan to use frequently into the Linux root file system rather than keeping them on your C drive. But WSL 2 lets Windows apps access the Linux file system, so you should be able to copy files to and from the C drive.
In fact, if you type explorer.exe / into the bash shell, WSL 2 should launch a Windows File Explorer window that’s open to the root Linux directory.
Windows 10 build 181917 also includes some new commands for setting up and managing Linux distributions. You can find those details, along with other information about WSL 2 at the Windows Command Line Tools for Developers blog, or in the documentation page.