Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem installing WSL: Error code: Wsl/WSL_E_DEFAULT_DISTRO_NOT_FOUND #9338

Closed
1 of 2 tasks
mwoodpatrick opened this issue Dec 15, 2022 · 28 comments
Closed
1 of 2 tasks

Comments

@mwoodpatrick
Copy link

Version

Microsoft Windows [Version 10.0.22621.1028]

WSL Version

  • WSL 2
  • WSL 1

Kernel Version

5.15.79.1

Distro Version

Ubuntu (allegedly)

Other Software

No response

Repro Steps

On new system I ran

wsl --install

It installed wsl and says it installed Ubuntu however running

wsl -l

I get

wsl -l
Windows Subsystem for Linux has no installed distributions.

Use 'wsl.exe --list --online' to list available distributions
and 'wsl.exe --install ' to install.

Distributions can also be installed by visiting the Microsoft Store:
https://aka.ms/wslstore
Error code: Wsl/WSL_E_DEFAULT_DISTRO_NOT_FOUND

Running

wsl --install Ubuntu

I get

Ubuntu is already installed.
Launching Ubuntu...

and then in a new window I get

Installing, this may take a few minutes...
WslRegisterDistribution failed with error: 0x80370114
Error: 0x80370114 The operation could not be started because a required feature is not installed.

Press any key to continue...

Expected Behavior

WSL and Ubuntu would be installed

Actual Behavior

WSL is installed but Ubuntu is not

Diagnostic Logs

No response

@mwoodpatrick
Copy link
Author

The system did another update based on yesterday's insider release and WSL completed the install on reboot

@bhoamikhona
Copy link

how did you solve this problem?

@mwoodpatrick
Copy link
Author

I just reran

wsl --update

There was a new update and after it had completed the system behaved as expected. I'm not sure what the underlying problem was but with the versions below wsl is working for me

PS C:\Users\mlwp> wsl --version

WSL version: 1.0.3.0
Kernel version: 5.15.79.1
WSLg version: 1.0.47
MSRDC version: 1.2.3575
Direct3D version: 1.606.4
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.22623.1095

@prasanthkollipara
Copy link

how did you solve this problem?
If you are trying to create a virtual environment of Linux on Windows, the problem with the code is that our WSL is unable to reach the repo in which the distros are supposed to be. So, to solve this issue, I manually downloaded the ubuntu image from the Microsoft store.
NOTE: The problem was not solved totally but I got what I was looking for (Ubuntu environment on Windows)

@kevinwmerritt
Copy link

I'm having the exact same problem as @mwoodpatrick originally reported.

wsl --version

WSL version: 1.0.3.0
Kernel version: 5.15.79.1
WSLg version: 1.0.47
MSRDC version: 1.2.3575
Direct3D version: 1.606.4
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.22621.1105
Installing, this may take a few minutes...
WslRegisterDistribution failed with error: 0x80370114
Error: 0x80370114 The operation could not be started because a required feature is not installed.

Press any key to continue...

@csraul
Copy link

csraul commented Feb 9, 2023

I'm with the same problem, but in other moment a mensage say that already ubuntu instaled.

Error code: Wsl/Service/CreateInstance/GetDefaultDistro/WSL_E_DEFAULT_DISTRO_NOT_FOUND

@CeSiumUA
Copy link

CeSiumUA commented Feb 21, 2023

+1
Fresh W11 installation....
I have exact the same situation as 2 people above.
Installed Debian, catching:

Installing, this may take a few minutes...
WslRegisterDistribution failed with error: 0x80370114
Error: 0x80370114 The operation could not be started because a required feature is not installed.

Press any key to continue...

And while typing wsl --list:

Windows Subsystem for Linux has no installed distributions.

Use 'wsl.exe --list --online' to list available distributions
and 'wsl.exe --install <Distro>' to install.

Distributions can also be installed by visiting the Microsoft Store:
https://aka.ms/wslstore
Error code: Wsl/WSL_E_DEFAULT_DISTRO_NOT_FOUND

UPD: I've also turned on Hyper-V in Windows features, restarted, and it seems to work now

@cladoulis
Copy link

I have been experiencing this same issue with Windows 10 21H2.
Ubuntu will not load, Docker Desktop will not start, even ever Hyper-V/WSL2/Docker uninstall & reinstalls. Still trying to resolve.

@Joaquin-Gajardo
Copy link

Joaquin-Gajardo commented Mar 7, 2023

I had the same issue. Search for "Turn Windows features on or off" in the Windows search bar and ensure that "Windows Subsystem for Linux" and "Virtual Machine Platform" are on, then restart. This solved it for me.

@colby-vickerson
Copy link

I needed to go into my Bios and enable CPU Virtualization and after a restart it worked.

Steps to fix:

  1. Enable CPU Virtualization in the BIOS (restart machine)
  2. Open terminal and run: wsl.exe --install Ubuntu

@symya
Copy link

symya commented Mar 31, 2023

How to solve this question?

@TahirIqbalGit
Copy link

First, check the list of distributions by entering command in PowerShell: wsl.exe --list.
If Ubuntu shows in the list, it means Ubuntu is installed and just reboot your system.

Otherwise, If there is no distributions follow these steps:

  1. Open PowerShell as Administrator and run command: wsl.exe --update
  2. Go through this article and enable CPU Virtualization.
  3. Open PowerShell as Administrator and run command: wsl.exe --install Ubuntu

100% Fixed!

@symya
Copy link

symya commented May 11, 2023

thanks

@mlartab
Copy link

mlartab commented May 22, 2023

thank you @TahirIqbalGit it was very helpful

@savyjs
Copy link

savyjs commented May 26, 2023

I switched to version 1, installed Ubuntu, then switched to Version 2 and it works now!

1-
wsl --set-default-version 1

2-
wsl.exe --install Ubuntu

3-
wsl --set-default-version 2

@Sir-Nigma
Copy link

A solution that worked for me!

Windows > Start > Turn Windows features on or off

Enable:
Virtual Machine Platform
Windows Subsystems for Linux

Reboot > command prompt > wsl --install -d

@zeynelagca
Copy link

I needed to go into my Bios and enable CPU Virtualization and after a restart it worked.

Steps to fix:

  1. Enable CPU Virtualization in the BIOS (restart machine)
  2. Open terminal and run: wsl.exe --install Ubuntu

--install ubuntu command solved my problem

@Maxhaufe17
Copy link

I switched to version 1, installed Ubuntu, then switched to Version 2 and it works now!

1- wsl --set-default-version 1

2- wsl.exe --install Ubuntu

3- wsl --set-default-version 2

Thanks, i have solved the problem

@herinlearning
Copy link

I needed to go into my Bios and enable CPU Virtualization and after a restart it worked.

Steps to fix:

Enable CPU Virtualization in the BIOS (restart machine)
Open terminal and run: wsl.exe --install Ubuntu

1- wsl --set-default-version 1

2- wsl.exe --install Ubuntu

3- wsl --set-default-version 2

--install ubuntu command solved my problem

@yuwanlin
Copy link

yuwanlin commented Sep 25, 2023

unregister then reinstall work for me.
image

image

@wangruntao
Copy link

Version

Microsoft Windows [Version 10.0.22621.1028]

WSL Version

  • WSL 2
  • WSL 1

Kernel Version

5.15.79.1

Distro Version

Ubuntu (allegedly)

Other Software

No response

Repro Steps

On new system I ran

wsl --install

It installed wsl and says it installed Ubuntu however running

wsl -l

I get

wsl -l Windows Subsystem for Linux has no installed distributions.

Use 'wsl.exe --list --online' to list available distributions and 'wsl.exe --install ' to install.

Distributions can also be installed by visiting the Microsoft Store: https://aka.ms/wslstore Error code: Wsl/WSL_E_DEFAULT_DISTRO_NOT_FOUND

Running

wsl --install Ubuntu

I get

Ubuntu is already installed. Launching Ubuntu...

and then in a new window I get

Installing, this may take a few minutes... WslRegisterDistribution failed with error: 0x80370114 Error: 0x80370114 The operation could not be started because a required feature is not installed.

Press any key to continue...

Expected Behavior

WSL and Ubuntu would be installed

Actual Behavior

WSL is installed but Ubuntu is not

Diagnostic Logs

No response

I solve this problme by reboot

Ubuntu is already installed.
Launching Ubuntu...
Installing, this may take a few minutes...
Please create a default UNIX user account. The username does not need to match your Windows username.
For more information visit: https://aka.ms/wslusers

@mguzelel
Copy link

mguzelel commented Oct 3, 2023

Two things basically needed here: Activate in Windows features : Hyper V and Windows subsystem for linux

@felipefarinha
Copy link

Win+R > optionalfeatures: active Hyper V and Windows subsystem for linux as mentioned by friend mguzelel

@FaizaWajid
Copy link

I had the same issue. Search for "Turn Windows features on or off" in the Windows search bar and ensure that "Windows Subsystem for Linux" and "Virtual Machine Platform" are on, then restart. This solved it for me.

Thank you it worked for me :)

@npip99
Copy link

npip99 commented Dec 5, 2023

Why is this Github issue closed? It's driving me insane. Everything online and from MSFT says Hyper-V is not required. However, it will not work on my system without Hyper-V. The instructions should at least say that the Hyper-V feature may need to be enabled until this is fixed.

@lovnir
Copy link

lovnir commented Jan 10, 2024

Disabled hyper v - containers - hypervisors, kept virtual machine on and restarted now everything works.

@a358612280
Copy link

I switched to version 1, installed Ubuntu, then switched to Version 2 and it works now!
1- wsl --set-default-version 1
2- wsl.exe --install Ubuntu
3- wsl --set-default-version 2

Thanks, i have solved the problem

这个对我有用, 我遇到的问题是,无法安装ubuntu, 错误( 不存在具有所提供名称的分发。 Error code: Wsl/Service/WSL_E_DISTRO_NOT_FOUND) 还有无法安装的问题, 都解决了

@AymanBennaceur
Copy link

AymanBennaceur commented May 29, 2024

I had the same issue, here are a few steps followed to fix it:

  1. Make sure Hyper-v is enabled
  2. Make sure Virtual Machine Platform is turned on (You can do so by clicking WIN + R then searching optionalfeatures)
  3. Restart your computer and run wsl --install -d Ubuntu - this should prompt you to give a UNIX username and password this time.

Note: You need a valid activated windows to use some features.

I hope this helps!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests