Skip to main content
small updates, integrated some comments
Source Link
flolilo
  • 2.7k
  • 1
  • 19
  • 28

DisclaimerInfo: I tried this on a VM with Win10 Pro (v1709 & 1803) with stock Group Policy (i.e. as-is with a fresh installation).

Note that this answer shows the steps for DebianonlyDebian only. However, everything is the same for Ubuntu, SLES, openSUSE, and Kali - the only difference will be in the name of the EXE (and the URL you use).

  • Via the Windows Features GUI: e.g. Win + I --> OptionalFeatures.exe
  • With PowerShell (as administrator): Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux.
  • Choose your distro. Simply use one of these URLs: * Debian: https://aka.ms/wsl-debian-gnulinux * Ubuntu 18.04: https://aka.ms/wsl-ubuntu-1804 * Ubuntu 16.04: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12 * Kali: https://aka.ms/wsl-kali-linux
  • Via PowerShell, run Invoke-WebRequest -Uri https://aka.ms/wsl-debian-gnulinux -OutFile ~/Debian.zip -UseBasicParsing.
    • If you do not need the progress-barVia PowerShell, addrun $ProgressPreferenceInvoke-WebRequest =-Uri 'SilentlyContinue'; in the front of the command.
    • Note that https://aka.ms/wsl-debian-gnulinux -OutFile ~/Debian.zip -UseBasicParsing.
      • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
      • Note that ~/Debian.zip can be changed to whatever path and name you want.
    • You can be changed to whatever pathalso download it "per manus" - feed the URL into your browser (or download manager) and name you wantcan get it this way, too.
  • You can also download it "per manus" - feed the URL into your browser (or download manager) and you can get it this way, too.
  • Note that you can use any path - be it ~\IHateUbuntu\SLES_WSL, be it DC:\Ubuntu, etc.p.p.. It must, however, be on your system's drive (usually C:\) Thanks, @Matt Wenham!
  • Via PowerShell: Expand-Archive <ARCHIVE> <ITS_NEW_PATH>
  • Via the File Explorer's GUI
  • Or via any zipping tool, such as 7-Zip.
  1. Run Debian.exe, which is inside the unzipped folder.
  1. Set your username and password.
  2. It is recommended to update all software at the first start.
  • If error 0x80070005 shows up, you need to run the EXE as administrator. Thanks, @March Ho!
  1. It is recommended to update all software at the first start.
  • In Debian & Ubuntu, this is done by running sudo apt-get update && sudo apt-get dist-upgrade.
  1. (Optional) Put WSLyour EXE into the Start Menu.

Disclaimer: I tried this on a VM with Win10 Pro (v1709) with stock Group Policy (i.e. as-is with a fresh installation).

Note that this answer shows the steps for Debianonly. However, everything is the same for Ubuntu, SLES, openSUSE, and Kali - the only difference will be in the name of the EXE (and the URL you use).

  • Via the Windows Features GUI
  • With PowerShell (as administrator): Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux.
  • Choose your distro. Simply use one of these URLs: * Debian: https://aka.ms/wsl-debian-gnulinux * Ubuntu 18.04: https://aka.ms/wsl-ubuntu-1804 * Ubuntu 16.04: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12 * Kali: https://aka.ms/wsl-kali-linux
  • Via PowerShell, run Invoke-WebRequest -Uri https://aka.ms/wsl-debian-gnulinux -OutFile ~/Debian.zip -UseBasicParsing.
    • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
    • Note that ~/Debian.zip can be changed to whatever path and name you want.
  • You can also download it "per manus" - feed the URL into your browser (or download manager) and you can get it this way, too.
  • Note that you can use any path - be it ~\IHateUbuntu\SLES_WSL, be it D:\Ubuntu, etc.p.p..
  • Via PowerShell: Expand-Archive <ARCHIVE> <ITS_NEW_PATH>
  • Via the File Explorer's GUI
  • Or via any zipping tool, such as 7-Zip.
  1. Run Debian.exe which is inside the unzipped folder.
  1. Set your username and password.
  2. It is recommended to update all software at the first start.
  • In Debian & Ubuntu, this is done by running sudo apt-get update && sudo apt-get dist-upgrade.
  1. (Optional) Put WSL into the Start Menu.

Info: I tried this on a VM with Win10 Pro (v1709 & 1803) with stock Group Policy (i.e. as-is with a fresh installation).

Note that this answer shows the steps for Debian only. However, everything is the same for Ubuntu, SLES, openSUSE, and Kali - the only difference will be in the name of the EXE (and the URL you use).

  • Via the Windows Features GUI: e.g. Win + I --> OptionalFeatures.exe
  • With PowerShell (as administrator): Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux.
  • Choose your distro. Simply use one of these URLs: * Debian: https://aka.ms/wsl-debian-gnulinux * Ubuntu 18.04: https://aka.ms/wsl-ubuntu-1804 * Ubuntu 16.04: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12 * Kali: https://aka.ms/wsl-kali-linux
    • Via PowerShell, run Invoke-WebRequest -Uri https://aka.ms/wsl-debian-gnulinux -OutFile ~/Debian.zip -UseBasicParsing.
      • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
      • Note that ~/Debian.zip can be changed to whatever path and name you want.
    • You can also download it "per manus" - feed the URL into your browser (or download manager) and you can get it this way, too.
  • Note that you can use any path - be it ~\IHateUbuntu\SLES_WSL, be it C:\Ubuntu, etc.p.p.. It must, however, be on your system's drive (usually C:\) Thanks, @Matt Wenham!
  • Via PowerShell: Expand-Archive <ARCHIVE> <ITS_NEW_PATH>
  • Via the File Explorer's GUI
  • Or via any zipping tool, such as 7-Zip.
  1. Run Debian.exe, which is inside the unzipped folder.
  1. Set your username and password.
  • If error 0x80070005 shows up, you need to run the EXE as administrator. Thanks, @March Ho!
  1. It is recommended to update all software at the first start.
  • In Debian & Ubuntu, this is done by running sudo apt update && sudo apt upgrade.
  1. (Optional) Put your EXE into the Start Menu.
added debian and kali
Source Link
flolilo
  • 2.7k
  • 1
  • 19
  • 28

That is: turning the Store off in gpedit.mscgpedit.msc did not make a difference...

Note that this answer shows the steps for Ubuntu onlyDebianonly. However, everything is the same for Ubuntu, SLES and, openSUSE, and Kali - the only difference will be in the name of the EXE (and the URL you use).

  • Choose your distro. Simply use one of these URLs: * Debian: https://aka.ms/wsl-debian-gnulinux * Ubuntu 18.04: https://aka.ms/wsl-ubuntu-1804 * Ubuntu 16.04: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12 * Kali: https://aka.ms/wsl-kali-linux
  • Via PowerShell, run Invoke-WebRequest -Uri https://aka.ms/wsl-ubuntudebian-1604gnulinux -OutFile ~/UbuntuDebian.zip -UseBasicParsing.
    • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
    • Note that ~/UbuntuDebian.zip can be changed to whatever path and name you want.
  • You can also download it "per manus" - feed the URL into your browser (or download manager) and you can get it this way, too.
  1. Run UbuntuDebian.exe which is inside the unzipped folder.
  • In Debian & Ubuntu, this is done by running sudo apt-get update && sudo apt-get dist-upgrade.
  • Simply put a hard link of UbuntuDebian.exe into C:\ProgramData\Microsoft\Windows\Start Menu\Programs.

You are good to go now. Run UbuntuDebian.exe whenever you want WSL to run.

That is: turning the Store off in gpedit.msc did not make a difference...

Note that this answer shows the steps for Ubuntu only. However, everything is the same for SLES and openSUSE, the only difference will be in the name of the EXE (and the URL you use).

  • Choose your distro. Simply use one of these URLs: * Ubuntu: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12
  • Via PowerShell, run Invoke-WebRequest -Uri https://aka.ms/wsl-ubuntu-1604 -OutFile ~/Ubuntu.zip -UseBasicParsing.
    • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
    • Note that ~/Ubuntu.zip can be changed to whatever path and name you want.
  • You can also download it "per manus" - feed the URL into your browser (or download manager) and you can get it this way, too.
  1. Run Ubuntu.exe which is inside the unzipped folder.
  • In Ubuntu, this is done by running sudo apt-get update && sudo apt-get dist-upgrade.
  • Simply put a hard link of Ubuntu.exe into C:\ProgramData\Microsoft\Windows\Start Menu\Programs.

You are good to go now. Run Ubuntu.exe whenever you want WSL to run.

That is: turning the Store off in gpedit.msc did not make a difference...

Note that this answer shows the steps for Debianonly. However, everything is the same for Ubuntu, SLES, openSUSE, and Kali - the only difference will be in the name of the EXE (and the URL you use).

  • Choose your distro. Simply use one of these URLs: * Debian: https://aka.ms/wsl-debian-gnulinux * Ubuntu 18.04: https://aka.ms/wsl-ubuntu-1804 * Ubuntu 16.04: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12 * Kali: https://aka.ms/wsl-kali-linux
  • Via PowerShell, run Invoke-WebRequest -Uri https://aka.ms/wsl-debian-gnulinux -OutFile ~/Debian.zip -UseBasicParsing.
    • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
    • Note that ~/Debian.zip can be changed to whatever path and name you want.
  • You can also download it "per manus" - feed the URL into your browser (or download manager) and you can get it this way, too.
  1. Run Debian.exe which is inside the unzipped folder.
  • In Debian & Ubuntu, this is done by running sudo apt-get update && sudo apt-get dist-upgrade.
  • Simply put a hard link of Debian.exe into C:\ProgramData\Microsoft\Windows\Start Menu\Programs.

You are good to go now. Run Debian.exe whenever you want WSL to run.

improved readability, added manual steps
Source Link
flolilo
  • 2.7k
  • 1
  • 19
  • 28

Note that this answer shows the steps for Ubuntu only. However, everything is the same for SLES and openSUSE, the only difference will be in the name of the EXE (and the URL you use).

  1. Activate Windows Subsystem for Linux either via the "Windows Features" GUI, or, with PowerShell (as administrator): Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux.
  2. In any PowerShell-window (admin rights not needed), run Invoke-WebRequest -Uri https://aka.ms/wsl-ubuntu-1604 -OutFile ~/Ubuntu.zip -UseBasicParsing.Activate Windows Subsystem for Linux.
  • If you do not needVia the progress-bar, add $ProgressPreference =Windows 'SilentlyContinue';Features in the front of the command.GUI
  • Note thatWith PowerShell (as administrator): ~/Ubuntu.zipEnable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux can be changed to whatever you want.
  1. Download the Linux-package.
  • Also note that you can chooseChoose your distro. Simply use one of these URLs: * Ubuntu: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12
  • Via PowerShell, run Invoke-WebRequest -Uri https://aka.ms/wsl-ubuntu-1604 -OutFile ~/Ubuntu.zip -UseBasicParsing.
    • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
    • Note that ~/Ubuntu.zip can be changed to whatever path and name you want.
  • You can also download it "per manus" - feed the URL into your browser (or download manager) and you can get it this way, too.
  1. Unzip your Ubuntu.zip in PowerShell via Expand-Archive ~/Ubuntu.zip ~/Ubuntu (or via the Explorer's GUI).Unzip the downloaded archive and place it into its destination path.
  • Note that you can use any path - be it ~/Ubuntu~\IHateUbuntu\SLES_WSL can, be changed to whatever you want;it this will be the path of its installationD:\Ubuntu, etc.p.p..
  • Via PowerShell: Expand-Archive <ARCHIVE> <ITS_NEW_PATH>
  • Via the File Explorer's GUI
  • Or via any zipping tool, such as 7-Zip.
  1. Now, run Ubuntu.exe. It will install Ubuntu right into its path.
  2. Set your username and password.Run Ubuntu.exe which is inside the unzipped folder.
  • If you're new to Linux: it's bestFor the other distros, you just have to update all software atlook for the first startcorrect EXE.
  • This will now "install" your distro.
  1. Set your username and password.
  2. It is recommended to update all software at the first start.
  • In Ubuntu, this is done by running sudo apt-get update && sudo apt-get dist-upgrade.
  1. Whenever needed, run Ubuntu.exe to run WSL.
  1. (Optional) Put WSL into the Start Menu.
  • My installation didn't put WSL into the Start Menu, so I fear you will have to do that yourself. E.g. simplySimply put a hard link of Ubuntu.exe into C:\ProgramData\Microsoft\Windows\Start Menu\Programs.
  1. (Optional) Repeat for as many distributions as you like to have.

You are good to go now. Run Ubuntu.exe whenever you want WSL to run.

  1. Activate Windows Subsystem for Linux either via the "Windows Features" GUI, or, with PowerShell (as administrator): Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux.
  2. In any PowerShell-window (admin rights not needed), run Invoke-WebRequest -Uri https://aka.ms/wsl-ubuntu-1604 -OutFile ~/Ubuntu.zip -UseBasicParsing.
  • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
  • Note that ~/Ubuntu.zip can be changed to whatever you want.
  • Also note that you can choose your distro. Simply use one of these URLs: * Ubuntu: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12
  1. Unzip your Ubuntu.zip in PowerShell via Expand-Archive ~/Ubuntu.zip ~/Ubuntu (or via the Explorer's GUI).
  • Note that ~/Ubuntu can be changed to whatever you want; this will be the path of its installation.
  1. Now, run Ubuntu.exe. It will install Ubuntu right into its path.
  2. Set your username and password.
  • If you're new to Linux: it's best to update all software at the first start by running sudo apt-get update && sudo apt-get dist-upgrade.
  1. Whenever needed, run Ubuntu.exe to run WSL.
  • My installation didn't put WSL into the Start Menu, so I fear you will have to do that yourself. E.g. simply put a hard link of Ubuntu.exe into C:\ProgramData\Microsoft\Windows\Start Menu\Programs.

Note that this answer shows the steps for Ubuntu only. However, everything is the same for SLES and openSUSE, the only difference will be in the name of the EXE (and the URL you use).

  1. Activate Windows Subsystem for Linux.
  • Via the Windows Features GUI
  • With PowerShell (as administrator): Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux.
  1. Download the Linux-package.
  • Choose your distro. Simply use one of these URLs: * Ubuntu: https://aka.ms/wsl-ubuntu-1604 * openSUSE: https://aka.ms/wsl-opensuse-42 * SLES: https://aka.ms/wsl-sles-12
  • Via PowerShell, run Invoke-WebRequest -Uri https://aka.ms/wsl-ubuntu-1604 -OutFile ~/Ubuntu.zip -UseBasicParsing.
    • If you do not need the progress-bar, add $ProgressPreference = 'SilentlyContinue'; in the front of the command.
    • Note that ~/Ubuntu.zip can be changed to whatever path and name you want.
  • You can also download it "per manus" - feed the URL into your browser (or download manager) and you can get it this way, too.
  1. Unzip the downloaded archive and place it into its destination path.
  • Note that you can use any path - be it ~\IHateUbuntu\SLES_WSL, be it D:\Ubuntu, etc.p.p..
  • Via PowerShell: Expand-Archive <ARCHIVE> <ITS_NEW_PATH>
  • Via the File Explorer's GUI
  • Or via any zipping tool, such as 7-Zip.
  1. Run Ubuntu.exe which is inside the unzipped folder.
  • For the other distros, you just have to look for the correct EXE.
  • This will now "install" your distro.
  1. Set your username and password.
  2. It is recommended to update all software at the first start.
  • In Ubuntu, this is done by running sudo apt-get update && sudo apt-get dist-upgrade.
  1. (Optional) Put WSL into the Start Menu.
  • Simply put a hard link of Ubuntu.exe into C:\ProgramData\Microsoft\Windows\Start Menu\Programs.
  1. (Optional) Repeat for as many distributions as you like to have.

You are good to go now. Run Ubuntu.exe whenever you want WSL to run.

Added update-procedure & solution for link in Start Menu.
Source Link
flolilo
  • 2.7k
  • 1
  • 19
  • 28
Loading
improved readability, added all distros.
Source Link
flolilo
  • 2.7k
  • 1
  • 19
  • 28
Loading
improved readability
Source Link
flolilo
  • 2.7k
  • 1
  • 19
  • 28
Loading
Source Link
flolilo
  • 2.7k
  • 1
  • 19
  • 28
Loading