Windows 10: Install Windows Subsystem for Linux with a single command

Discus and support Install Windows Subsystem for Linux with a single command in Windows 10 News to solve the problem; Windows 10 administrators who want to install WSL, the Windows Subsystem for Linux, can do so running a single command on Windows 10 versions 2004 and... Discussion in 'Windows 10 News' started by GHacks, Aug 1, 2021.

  1. GHacks
    GHacks New Member

    Install Windows Subsystem for Linux with a single command


    Windows 10 administrators who want to install WSL, the Windows Subsystem for Linux, can do so running a single command on Windows 10 versions 2004 and later.

    Microsoft introduced the enhancement in Insider preview builds back in October 2020, and has now pushed the improvement in recent updates for Windows 10 versions 2004, 20H2 and 21H1.

    The enhancement is included in KB5004296, which is an optional update for the listed versions of Windows 10; since updates are cumulative, the new functionality will be introduced on the August 2021 Patch Day to all devices via Windows Updates. Optional updates are installed only on systems if administrators become active, for instance by seeking for the update or downloading it from the Microsoft Update Catalog website.

    Microsoft makes no mention of the WSL improvement in the release notes. A post on Microsoft's Dev Blog by Craig Loewen confirms the inclusion of the new install option for WSL on Windows 10 version 2004 and higher.

    All it takes is to open an elevated command prompt and run the command wsl.exe --install to install WSL on the device. By default, Ubuntu will be installed on the device as it is the default Linux distribution if no distribution is specified.

    The main advantage of the new method is that the installation is much faster. Previously, you had to install all required components separately on the device.

    Install Windows Subsystem for Linux with a single command install-wsl-windows-10-command.png

    Here is an overview of the commands and what you may use them for. Note that some commands can only be run after WSL has been installed on the device.

    1. Select Start.
    2. Type cmd.exe
    3. Select Run as administration.
    • wsl.exe --install
      • installs the Ubuntu distribution and WSL on the device.
    • wsl --list --online
      • lists all available Linux distributions that you may install using the wsl command. Currently, these are:
      • Ubuntu Ubuntu
      • Debian Debian GNU/Linux
      • kali-linux Kali Linux Rollin
      • openSUSE-42 openSUSE Leap 42
      • SLES-12 SUSE Linux Enterprise Server v12
      • Ubuntu-16.04 Ubuntu 16.04 LTS
      • Ubuntu-18.04 Ubuntu 18.04 LTS
      • Ubuntu-20.04 Ubuntu 20.04 LTS
    • wsl --install -d <DistroName>
      • installs the selected distribution. Replace <DistroName> with the name of the distribution. Can be used to install additional distributions as well.
    • wsl --update
      • updates the WSL Linux kernel manually.
    • wsl --update rollback
      • rolls back to the previous WSL kernel version.
    • wsl --status
      • displays general information about the status of the Windows Subsystem for Linux installation.
    • wsl --help
      • displays the list of command parameters.

    The command will install version 2 of WSL on the device. You can check that by running wsl with the status parameter after a successful installation. If you see version 2, the second version of the Windows Subsystem for Linux is installed.

    Closing Words


    The new commands make it easier to install WSL on a Windows 10 device. The only command missing is uninstall, as you cannot use the command line tool to remove a WSL installation from the device again. Microsoft did not mention if the tool will also be included in Windows 11, but it seems likely.

    Now You: have you used WSL on Windows If not, would you?

    Thank you for being a Ghacks reader. The post Install Windows Subsystem for Linux with a single command appeared first on gHacks Technology News.

    read more...
     
    GHacks, Aug 1, 2021
    #1

  2. Windows Subsystem Linux

    Hello,

    We would like to know more about the issue you're experiencing with using
    Windows Subsystem for Linux
    . Kindly answer the following questions:

    • Are you developing a program, an app, or a software for Linux?
    • Is your Window 10 PC connected to a domain?
    • Are you managing a Windows Server PC?
    • What troubleshooting steps have you tried so far?
    • Can you tell us the Version and OS build of your Windows 10 device? You can find this information by clicking the
      Start button, type About your PC, and then press
      Enter.

    We need the following information in order to determine if we need to refer your concern to the
    TechNet forums or the Microsoft Developer Network (MSDN) forums.

    For now, we suggest reviewing these support articles to find out if there's an issue with the installation of
    Windows Subsystem for Linux:


    We'll be waiting for your response.
     
    Devlin Sco, Aug 1, 2021
    #2
  3. Nikhar_K Win User
    Unable to enable Windows Subsystem for Linux

    Hi,



    Thank you for writing to Microsoft Community Forums.



    I understand that you have downloaded Linux Terminal from Microsoft Store and you are getting an error when running the PowerShell command. However, as per the article

    Windows Subsystem for Linux Installation Guide for Windows 10
    you need to run the PowerShell command first and then install the required Linux distribution from the store. I suggest you to try running the PowerShell command
    first and check.



    For more information on Windows Subsystem for Linux, please refer the articles

    Windows Subsystem for Linux Documentation
    and

    Troubleshooting Windows Subsystem for Linux
    .



    If the issue persists, I suggest you to post your query in
    TechNet forums
    , where we have support professionals and experts on this query to assist you with the appropriate details.



    Regards,

    Nikhar Khare

    Microsoft Community - Moderator
     
    Nikhar_K, Aug 1, 2021
    #3
  4. Install Windows Subsystem for Linux with a single command

    Windows subsystem for Linux

    If you want to install Ubuntu on Windows 10, you'll have to create a virtual machine and then install Ubuntu in the virtual machine.

    The subsystem for Linux lets you to run Linux command-line tools in Windows.
     
    0dcafe6b-10a8-4bc9-b8b2-213ccfc2f28c, Aug 1, 2021
    #4
Thema:

Install Windows Subsystem for Linux with a single command

Loading...
  1. Install Windows Subsystem for Linux with a single command - Similar Threads - Install Subsystem Linux

  2. cannot install Windows Subsystem for Linux

    in Windows 10 Gaming
    cannot install Windows Subsystem for Linux: I am using Windows 11 OS build 22631.3155 on a desktop PC. I was using Windows Subsystem for Linux WSL about two years without problem. I did a Windows Reset to remove malware and now WSL does not work. If I click on Start > Ubuntu the error message is...
  3. cannot install Windows Subsystem for Linux

    in Windows 10 Software and Apps
    cannot install Windows Subsystem for Linux: I am using Windows 11 OS build 22631.3155 on a desktop PC. I was using Windows Subsystem for Linux WSL about two years without problem. I did a Windows Reset to remove malware and now WSL does not work. If I click on Start > Ubuntu the error message is...
  4. WSL Windows Subsystem For Linux "wsl" command not found

    in Windows 10 Gaming
    WSL Windows Subsystem For Linux "wsl" command not found: Guys help, I've contacted ms support multiple times and none of the agents have been able to solve the issue.so, I have Windows Subsystem for Linux WSL with Ubuntu installed. yesterday, i tried to install docker, and it was kind of a mess, so i just uninstalled it in every...
  5. WSL Windows Subsystem For Linux "wsl" command not found

    in Windows 10 Software and Apps
    WSL Windows Subsystem For Linux "wsl" command not found: Guys help, I've contacted ms support multiple times and none of the agents have been able to solve the issue.so, I have Windows Subsystem for Linux WSL with Ubuntu installed. yesterday, i tried to install docker, and it was kind of a mess, so i just uninstalled it in every...
  6. WSL Windows Subsystem For Linux "wsl" command not found

    in Windows 10 BSOD Crashes and Debugging
    WSL Windows Subsystem For Linux "wsl" command not found: Guys help, I've contacted ms support multiple times and none of the agents have been able to solve the issue.so, I have Windows Subsystem for Linux WSL with Ubuntu installed. yesterday, i tried to install docker, and it was kind of a mess, so i just uninstalled it in every...
  7. Windows Subsystem for Linux

    in Windows 10 Gaming
    Windows Subsystem for Linux: Hello,Could you please provide me with the answers to the following questions regarding Windows Subsystem for Linux 2 + Kernel?When was the release date for version 5.10.60.1 of this application? Is version 5.10.60.1 still supported will receive updates, security or...
  8. Issue with installing linux subsystem.

    in Windows 10 Installation and Upgrade
    Issue with installing linux subsystem.: Hi, I was trying to isntall linux subsystem through powershell, and when I tried to use "Enable-WindowsOptionalFeature -Online -FeatureName VirtualMachinePlatform" command, I get a following error, Enable-WindowsOptionalFeature : Feature name VirtualMachinePlatform is...
  9. Linux Subsystem

    in Windows 10 Installation and Upgrade
    Linux Subsystem: So i have downloald Linux Terminal from Microsoft Store i have turned on the developer options but the last thing i need to do is to turn on Linux Subsystem. I tried to turn it on from PowerShell by typing the followin command Enable-WindowsOptionalFeature -Online...
  10. Windows subsystem for Linux

    in Windows 10 Customization
    Windows subsystem for Linux: I am getting the message " We couldn't complete the updates … undoing changes" when I restart the computer after enabling WSL in the "Programs and Features" settings. I am running windows 10 home ver 1803 installed on 05 Aug 2018 OS Build 17134.191 Due to this, I am unable...