I have just installed WSL 2 but I have difficulties to launch it.

My installation

I did the official installation from Microsoft. Manual installation, I chose "Ubuntu" in the Microsoft Store and it installed Ubuntu 20.04 :

I have a Dell Inspiron 5593, processor Intel(R) Core(TM) i7-1065G7 CPU. I am on Windows 10, version 2004, build 19041.1083.

The issues

  • When I execute wsl or wsl.exe in the command prompt or power shell, nothing happens.

  • When I search "wsl" in the taskbar and click on the icon, a Linux terminal appears and disappears quickly.

  • After I followed the previous points, wsl.exe --list --all --verbose in the power shell gives me :

    NAME STATE VERSION docker-desktop-data Stopped 2 docker-desktop Stopped 2 Ubuntu Stopped 2 

(with a * before "docker-desktop-data")

  • The only way I have found to launch it is to go to the Microsoft Store, find Ubuntu and click on the "launch" button. Then a terminal opens and I can execute Linux commands without other issue.
  • When I try to execute WSL commands (except wsl.exe --list --all --verbose) on command prompt or power shell it says my command is invalid and prints the usage informations.

What I tried to solve the problem

  • Execute sudo apt get-update on a Linux terminal.
  • Open the Windows settings, clicked "check for updates" and I don't have any update to do.
  • Make sure "Windows sub system for Linux" is enabled in Windows settings.
  • Read the following links :

"Troubleshooting installation" section at the end of the installation page :

  • And other old links, apparently trying to solve an elder bug from august/september 2020 :

WSL Bash doesn't start and tried the two answers

  • Link in french :
  • Reboot my computer everytime I tried a solution
2

1 Answer

Could be wrong/no default distribution. Try setting the default distribution:

wsl --set-default Ubuntu 

If that fails, try unregistering and reinstalling the distribution.

wsl --unregister Ubuntu 

then go to the Microsoft store and click Launch.

3

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy