Skip to main content

Upgrading to WSL2 from WSL1 on Windows 10.

Updating from WSL1 to WSL2 would need you to update your Windows to 2004 or 20H2 . Just check your "Windows Update Settings" from start menu and make sure you have at least 2004.

Optional: You may like to register for Windows Insider program if you are reading this article before 20H2 is publicly available.

Note: You do not need Hyper-V enabled for WSL2

However you need to uninstall WSL from "Turn Windows Features on or off" and reinstall. Reboot.


Now one may think WSL2 should be installed, but we are not there yet. You may see below error on running the respective command.

This is because the WSL2 kernel is not installed yet.

Get the kernel installer from here 

When you double click the msi installer you may face below blocker


This is pretty misleading because you have WSL installed. Basically the run fails due to limited authorisation. So just run a Powershell as Administrator and run the executable from there it should install just fine.

Now go to App Store and try installing Ubuntu 20.04 LTS and it should install just fine.

See the new version with below command.

wsl -l -v

Note that WSL2 doesn't replace WSL1. If you had installed Ubuntu in WSL1, it will still be there.


Comments

Popular posts from this blog

Running your Hello World Alexa Skill without AWS Lambda

If you are here because you are trying to build an Alexa App, but you do not want to run it in AWS Lambda, then here you go! You will need an Alexa Developer account. Then you need to create a Skill from the developer console. You need to choose HTTPS endpoint instead of AWS Lambda Now time to start coding! This demo will use Nodejs for building the skill. It will also use ASK SDK to avoid writing a lot of boilerplate code. We will use express framework to start a local endpoint and let ngrok be the public proxy to which Alexa sends data. To be continued..