Installing WSL on Windows 11

Wondering how to install WSL on Windows 11? Then you've come to the right place! This tutorial explains how to install Windows Subsystem for Linux on Windows 11 in order to use Linux distributions from Windows. And yes, that's what WSL is all about: making it possible to use Linux, or Linux GUI applications, from a Windows machine without creating a virtual machine.

Activating WSL functionality on Windows 11 is relatively straightforward, as we shall see. To date, WSL supports various Linux distributions such as Ubuntu, Debian, Kali Linux and openSUSE.

1. Activating WSL on Windows 11

Under Windows 11, Microsoft has further simplified the installation of the WSL functionality. It will be installed directly in version 2, i.e. WSL 2, to enable better support for Linux distributions, in particular to have a complete Linux kernel.

Open a PowerShell console or Command Prompt as administrator on your PC. To install WSL on Windows 11, simply execute this magic command:

wsl --install

During this installation process, the computer will install several components, including a Hyper-V layer which is essential for WSL 2 to function properly. It will also deliver WSL with a Linux distribution installed by default on your PC: Ubuntu. Here's what you need to get:

install WSL on Windows 11

You can update the WSL Linux kernel on your Windows 11 PC at any time with the following command:

wsl --update

The message "Checking for updates..." will appear, and if there is an update, it will be installed automatically. In general, the command "wsl" followed by a parameter is used to manipulate WSL on Windows from the command line.

I've shown you how to install WSL on Windows 11 with the " wsl -install "But it's also possible to install it from the Microsoft Store or from optional Windows features. The choice is yours, but I find this method simple and effective: it's my preference.

2. Installing a Linux distribution in WSL

We have just seen how to install WSL on Windows 11but how do you install a Linux distro?

Ubuntu is installed by default, and this is no coincidence, as Microsoft and Canonical (the publisher of Ubuntu) have a special relationship, so it's surely a partnership. However, you can install another Linux distribution from the available list.... You can either go directly to the Microsoft Store and search for "WSL", or you can do it from the command line....

The following command lists the available distributions:

wsl --list --online

In the list that appears, you can locate the name of the distribution you wish to install. Then, to install it :

wsl --install -d NAME-DISTRIBUTION

Once installed, the Linux distribution is accessible from the Start menu of your Windows 11 machine. There's no limit to the number of Linux distributions you can install in parallel on your Windows 11 PC... except that this will consume disk space on your PC.

To conclude this tutorial, here are a few basic commands that are well worth knowing... Even if the possibilities are numerous with WSL.

To list the Linux distributions installed on your PC :

wsl --list

To set a default Linux distribution when interacting with WSL :

wsl --set-default Debian

To shut down a Linux distribution :

wsl --terminate Debian

Thanks to this article from the Computer Tutorials box, you'll be able to install WSL on Windows 11! You're ready to take your first steps with Linux on Windows! It may come as a surprise, but it works just fine!

Resources :

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *