microsoft / WSL

Issues found on WSL
https://docs.microsoft.com/windows/wsl
MIT License
17.48k stars 822 forks source link

WSL installation fails with error "0x8007019e" plus "wsl -l -v" gives an error "Wsl/0x80080005" #12071

Closed Khajiit-Rakaj closed 1 month ago

Khajiit-Rakaj commented 1 month ago

Windows Version

10.0.22631.37372

WSL Version

2.2.4.0

Are you using WSL 1 or WSL 2?

Kernel Version

5.15.153.1-2

Distro Version

Ubuntu 22.04

Other Software

No response

Repro Steps

wsl --install wsl -l -v

Expected Behavior

wsl --install should install default distro as Ubuntu and lauch it wsl -l -v should give WSL version

Actual Behavior

Executing wsl --install command returns an error "0x8007019e The Windows Subsystem for Linux has not been enabled.".

wsl --install Ubuntu is already installed. Launching Ubuntu... Error: 0x8007019e The Windows Subsystem for Linux has not been enabled.

Press any key to continue... The operation completed successfully.

Executing wsl -l -v command returns an error "Wsl/0x80080005".

wsl -l -v Server execution failed Error code: Wsl/0x80080005

Diagnostic Logs

WSL logs WslLogs-2024-08-08_13-30-30.zip For reasons I don't understand, during the execution of repro steps, in Process manager I found two icons for Linux subsystems and, therefore, created two WSL dump files in case it will be needed wsl.zip wsl-2.zip

Khajiit-Rakaj commented 1 month ago

The first problem I ran into was an error "0x8007019e", which appeared when I tried to open Ubuntu after the installation (the first time installation didn't give any error). I tried to troubleshoot it following this issue https://github.com/microsoft/WSL/issues/10850. However, during troubleshooting I ran into error "Wsl/0x80080005". Then I tried to troubleshoot second error with this issue https://github.com/microsoft/WSL/issues/10305, but nothing helped. Developer mode is enabled, Hardware Virtualization is enabled and there is no "Windows Subsystem for Linux" in Windows components

github-actions[bot] commented 1 month ago

View similar issues

Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one and thumbs upping the other issue to help us prioritize it!

Open similar issues:

Closed similar issues:

Note: You can give me feedback by thumbs upping or thumbs downing this comment.

Diagnostic information
Multiple log files found, using: https://github.com/user-attachments/files/17110404/WslLogs-2024-08-08_13-30-30.zip
Detected appx version: 2.2.4.0

OneBlue commented 1 month ago

@Khajiit-Rakaj: This is interesting, I don't see a WSL optional feature in the logs. Which version of Windows are you using ?

Khajiit-Rakaj commented 1 month ago

@OneBlue I'm using Windows 10 (version 10.0.22631.37372). Can you, please, explain, what is the issue you've mentioned about and how can I use it to solve my problem?

OneBlue commented 1 month ago

@Khajiit-Rakaj: The issue is essentially that your machine is missing an optional component to run WSL. Do you see this in optionalfeatures.exe ?

image

Khajiit-Rakaj commented 1 month ago

@OneBlue No, as I mentioned above, there is no "Windows Subsystem for Linux" in optionalfeatures.exe

OneBlue commented 1 month ago

Interesting. Can you share a screenshot of winver, and a screenshot of regedit for the Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion key ?

Khajiit-Rakaj commented 1 month ago

Yes, sure. However, I found out that my Windows' version is different in winver compared to Command prompt information (I added both screenshots, but now I have no idea, which version is right) 1 2 3

Khajiit-Rakaj commented 1 month ago

@OneBlue, can you, please, explain, which Windows version am I having? And what are possible reasons, why Windows' versions in winver and Command prompt are different?

OneBlue commented 1 month ago

@Khajiit-Rakaj: I'm actually not sure. Your windows build might be in a bad state. You can try to run "sfc /scannow" to try to get it back to a proper state but unfortunately if the optional component doesn't show at all it might be that you'll need to re-install Windows to solve this.

Khajiit-Rakaj commented 1 month ago

@OneBlue I ran "sfc /scannow" and rebooted system, but there still no "Windows Subsystem for Linux" in Windows components and I got the same errors. My last question: is there a possibility, that my problems arise from hardware? I have gaming MSI laptop, which may have caused these problems, but I don't sure

OneBlue commented 1 month ago

Ok. Unfortunately I'm not sure what could cause this. The only thing I can recommend would be to re-install windows at that point. Sorry :(