How to set Linux distro version to WSL 1 / WSL 2 in Windows 10
Windows Subsystem for Linux (WSL) (aka WSL 1) allows developers to run GNU / Linux environments - including most command line tools, utilities and applications - directly on Windows, without Modified, without anything related to traditional virtual machines or dualboot setup.
WSL 2 (Windows Subsystem for Linux 2) is a new version of the architecture in WSL that changes the way Linux distributions interact with Windows. WSL 2's primary goals are to increase file system performance and add system-wide compatibility.
Each Linux distribution can run as WSL 1 or WSL 2 and switch between versions at any time. WSL 2 is a 'major overhaul' of the underlying architecture, as well as the use of virtualization technology and the Linux kernel to enable new features.
With Windows Subsystem for Linux (WSL) enabled, you can install Linux distro applications from the Microsoft Store.
Users can set WSL 1 or WSL 2 as the default architecture used as the default version, whenever a new Linux distribution is installed.
Users can also set the Linux distro version to WSL 1 or WSL 2 for the existing installed Linux distributions at any time.
This guide will show you how to set the Linux distro version to WSL 1 or WSL 2 in Windows 10.
Set the default distro version to WSL 1 or WSL 2 for new Linux distributions
Step 1. Open PowerShell.
Step 2. Copy and paste the command below you want to use into PowerShell and press Enter.
(Make WSL 1 the default version)
wsl --set-default-version 1
Or:
(Make WSL 2 the default version)
wsl --set-default-version 2
Set the default distro version to WSL 1 or WSL 2 for new Linux distributions
Step 3. Now, you can close PowerShell if you want.
Set the distro version to WSL 1 or WSL 2 for specifically installed Linux distributions
Step 1. Open PowerShell.
Step 2. Copy and paste below command into PowerShell, press Enter and write down the name of the Linux distribution (eg "Ubuntu") you want to change version (eg "1" or "2") .
wsl --list --verbose
Note down the name of your Linux distribution
Step 3. Type the command below into PowerShell and press Enter.
wsl --set-version
Replace in the above command with the actual Linux distribution name (eg "Ubuntu") from step 2.
Replace in the above command with the number 1 (WSL 1) or 2 (WSL 2) for the default architecture you want.
For example:
wsl --set-version Ubuntu 2
Set the distro version to WSL 1 or WSL 2 for specifically installed Linux distributions
Step 4. Now, you can close PowerShell if you want.
Good luck.
You should read it
- 6 best Linux distros for gaming
- Linux distro for new, easy to use, beautiful
- Top 8 most beautiful Linux distributions in 2022
- An Introduction to Spiral Linux: A Distro for Linux Beginners
- 8 easy tools to create your own Linux Distro
- 8 Best Linux Distros for Chromebooks
- What do you know about Linux distros?
- EasyWSL tool can turn Linux docker image into Windows 10 WSL distro
May be interested
- 8 Best Linux Distros for Chromebookslinux becomes the most suitable choice for chromebooks because it provides the features that users require.
- What do you know about Linux distros?linux has existed for nearly 30 years, this is a historic journey. if you are interested in the history of some of the major linux distributions, read the following article.
- 7 great Linux distro media centers for HTPCif you are looking for an outdated linux media center or an alternative to kodibuntu, try the following open source htpc operating systems.
- These Linux distros are used in IoT deviceseven the simplest iot devices run software to stay active and most of these devices are running linux distro.
- 5 reasons why Linux distros create their own desktop environmentmost of us don't think of the desktop as separate from the operating system. the desktop is what you see on the screen - as with windows or macos. on linux, desktop options are extremely diverse.
- 17 lightweight Linux distributions bring new life to old computersolder computers are often slow and upgrading components such as ram, cpu and hard drive can alleviate performance problems. however, the best solution to bring new life to your old computer is to install a compact linux distribution.
- 5 best Ubuntu-based Linux distributions of all timeubuntu, a debian-based linux operating system, has been around since 2004; since then, some great distributions based on ubuntu's source code have been created.
- Which Linux distros will Windows 10 put into Windows 10?microsoft is trying to support linux by announcing three of the most popular linux distros will be available in the windows store. that means ubuntu, fedora and opensuse will soon appear in windows 10.
- What is the difference between Linux distributions?the following article points out the differences between linux distributions like ubuntu, fedora, linux mint, debian, opensuse and many others. why are there so many linux distributions and what are the differences between them?
- 4 interfaces and Linux distros that can be run on PinePhonepine microsystems created pinephone. some mobile interfaces for linux support pinephone. that is very interesting, but it is important that you decide which option is right for you.