How to install Windows Subsystem for Linux – complete Guide

windows subsystem for linux
source: from kali.org

Windows Subsystem for Linux (WSL) allows users to run a Linux terminal environment. Also, install packages from the Kali archive, and run Linux applications and workflows on Windows 10.

You may want to run Kali Linux or Ubuntu on your Windows 10. In this article, we are going to see how you can run Kali Linux or Ubuntu in Windows 10.

In the previous article we saw how to install kali Linux properly on your computer in 2021, now let us see how to run it on Windows 10.

What is Windows Subsystem for Linux (WSL)?

The Windows Subsystem for Linux lets developers run a GNU/Linux environment. Then, as you know already what is WSL now let us see what is WLS 2.

What is WSL 2?

WSL 2 is a new version of the Windows Subsystem for Linux architecture that powers the Windows Subsystem for Linux to run ELF64 Linux binaries on Windows. 

What are the prerequisites to Install Win-Kex?

First, let us see what are prerequisites before jump on installing Win-Kex.

To install Win-Kex you need to have Windows 10 version 2004 or higher running on your computer. Also, using windows Terminal.

You may also like How to install Kali NetHunter on an Android device.

Installation of Windows Subsystem for Linux

There are 2 options available for installing Windows Subsystem for linux (WSL):

  • Simplified install: The wsl –install simplified install command requires that you join the  Windows Insiders Program and install a preview build of Windows 10.
  • Manual install: It follows the six steps that will discuss in this article.

Also, if you run into an issue during installation, Windows provide the Troubleshooting installation.

In this article, we are going to discuss Manual Installation.

Install Kali Linux in Windows Subsystem on Linux 2

Step 1- Enable the Windows Subsystem for Linux.

In order to install Kali Linux, you must first enable the “Windows Subsystem for Linux”, then, open Windows PowerShell as administrator and run:

dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart

Then, after running this command, Restart windows PowerShell, then reopen it again, and run:

Step 2 – Check requirements for running WSL 2

To update to WSL 2, you must be running Windows 10.

  • For x64 systems: Version 1903 or higher, with Build 18362 or higher.
  • For ARM64 systems: Version 2004 or higher, with Build 19041 or higher.
  • Builds lower than 18362 do not support WSL 2. Use the Windows Update Assistant to update your version of Windows.

To check your version and build number, select Windows + R type winver, select ok. or you can enter ver command in windows command prompt.

Step 3- Enable virtual Machine feature

enable virtual machine

Before installing WSL 2, you must enable the Virtual Machine Platform optional feature. Your machine will require virtualization capabilities to use this feature.

dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart

Then, Restart your machine to complete the WSL install update to WSL2.

Step – 4 Download the Linux Kernel update package

After you finished restarting your pc, then download and install the WSL2 Linux Kernel from here: https://aka.ms/wsl2kernel.

Step 5 – Set WSL 2 as your default version

Then open PowerShell as administrator and run:

wsl --set-default-version 2

Step 6 – Install your Linux distribution of choice

This last step is the installation of Kali Linux from the Microsoft Store. Also, to upgrade an existing WSL1 kali-linux installation, type: wsl --set-version kali-linux 2

After you have installed Kali Linux from Wicrosoft Store, Then run kali and finish the initial setup: set up your username and password

Install Win-Kex

Win-Kex
kali@kali:~$ sudo apt update
kali@kali:~$ sudo apt install -y kali-win-kex

Refer to the Win-KeX Win usage documentation for further information.

3 thoughts on “How to install Windows Subsystem for Linux – complete Guide”

  1. Pingback: Linux tutorial for beginners – Linux guide in 2021

Comments are closed.

Scroll to Top

Discover more from Tgeniusclub

Subscribe now to keep reading and get access to the full archive.

Continue reading