WSL icon indicating copy to clipboard operation
WSL copied to clipboard

Error code: Wsl/Service/CreateInstance/0x80040326 when starting WSL Distro

Open sleavitt opened this issue 3 years ago • 39 comments

Windows Version

Microsoft Windows [Version 10.0.19045.2788]

WSL Version

1.1.3.0

Are you using WSL 1 or WSL 2?

  • [x] WSL 2
  • [ ] WSL 1

Kernel Version

5.15.90.1

Distro Version

Ubuntu 22.04

Other Software

No response

Repro Steps

Open Windows Terminal, open a new tab for a Linux Distro. --OR-- Open Command Prompt or PowerShell, type "ubuntu" and hit enter. --OR-- Open VSCode, Click Terminal -> New Terminal, and select a Linux (WSL) distro.

Expected Behavior

Distro should open normally.

Actual Behavior

Error: 0x80040326 Error code: Wsl/Service/CreateInstance/0x80040326 Press any key to continue...

Diagnostic Logs

No response

sleavitt avatar Mar 30 '23 00:03 sleavitt

The timing of this in relation to when https://github.com/microsoft/WSL/issues/9866 was opened seems suspicious, as I'm not a huge believer in coincidence. However, the error code on my issue is different (though the error number is the same), and WSL does not open in VSCode, so I'm opening this as a separate issue.

sleavitt avatar Mar 30 '23 00:03 sleavitt

Appears to be related to #9866 in that issuing "wsl --update" from a PowerShell prompt updated WSL which seemed to fix it.

WSL version: 1.1.6.0 Kernel version: 5.15.90.1

However, I'd love to know what broke it in the first place, as I hadn't manually updated WSL recently. Closing issue as fixed.

sleavitt avatar Mar 30 '23 01:03 sleavitt

Appears to be related to #9866 in that issuing "wsl --update" from a PowerShell prompt updated WSL which seemed to fix it.

Same issue and use "wsl --upate" fixed it.

tbwdxd avatar Mar 30 '23 01:03 tbwdxd

same issue here: wsl-update fixes the issue. Thanks sleavitt

HeriYantodotDev avatar Mar 30 '23 01:03 HeriYantodotDev

Same! I was in several terminal sessions working and they were all closed with WSL error. Rebooted machine which didn't fix and found this post! wsl --update worked but what the heck broke it in real time?

lminor avatar Mar 30 '23 02:03 lminor

Same issue here with Chinese Win11 22H2, run wsl --update Fixed the issue, thanks sleavitt

yexingok avatar Mar 30 '23 02:03 yexingok

I had the same issue on Windows 10, wsl --update fixed it for me too.

easrng avatar Mar 30 '23 02:03 easrng

same issue, did wsl --update didn't work, but after sometime I got windows notification about successful update and then it started working again.

m-shahbaz-kharal avatar Mar 30 '23 02:03 m-shahbaz-kharal

same issue as the rest above and fix. why would wsl just break by itself without an update? this is raising reliability questions on what should now be a stable platform.

ystxn avatar Mar 30 '23 03:03 ystxn

had the exact same issue when starting windows 11 an hour ago. Resolution wsl --update

adamshawvipps avatar Mar 30 '23 03:03 adamshawvipps

same issue here: wsl-update and wsl --shutdown fixes the issue.

bitis avatar Mar 30 '23 03:03 bitis

Appears to be related to #9866 in that issuing "wsl --update" from a PowerShell prompt updated WSL which seemed to fix it.

WSL version: 1.1.6.0 Kernel version: 5.15.90.1

However, I'd love to know what broke it in the first place, as I hadn't manually updated WSL recently. Closing issue as fixed.

I can’t thank you sleavitt enough. When I install visutal studio 2022 and just reboot the system a few minutes ago ,then encountered the problem. Just use the comand wsl --update in Powershell, and every things are back to normal.

nilyang avatar Mar 30 '23 03:03 nilyang

Thank you. That must have been one of the quickest problem-->solution sprints I had :)

SaurabhKoverhoop avatar Mar 30 '23 04:03 SaurabhKoverhoop

Same issue here. The timing is indeed suspicious. The command is wsl --update not wsl-update I don't like when my things self-destruct.

Robert-Ernst avatar Mar 30 '23 04:03 Robert-Ernst

Same issue here, but I on wsl --update I get a "severe error" message. Not very helpful...

PS C:\WINDOWS\system32> wsl --update
Installation: Windows-Subsystem für Linux
Schwerwiegender Fehler

However, uninstalling "Oracle VirtualBox" (I should never have installed it in the first place, I know...), deactivating the windows feature "Windows Subsystem for Linux" and re-activating it again solved the issue for me.

tbraun-hk avatar Mar 30 '23 05:03 tbraun-hk

Same issue here, but I on wsl --update I get a "severe error" message. Not very helpful...

PS C:\WINDOWS\system32> wsl --update
Installation: Windows-Subsystem für Linux
Schwerwiegender Fehler

However, uninstalling "Oracle VirtualBox" (I should never have installed it in the first place, I know...), deactivating the windows feature "Windows Subsystem for Linux" and re-activating it again solved the issue for me.

@tbraun-hk Use

wsl --shutdown
wsl --update

pfrajsifx avatar Mar 30 '23 07:03 pfrajsifx

Windows 10 Had to run

wsl --shutdown
wsl --update

Unfortunately, I found this ticket after having tried just about everything else, so my windows terminal settings are reset etc. Bummer

hkjels avatar Mar 30 '23 08:03 hkjels

After being stuck on a Chat GPT4 dialog on how to check the health of my WSL2 I'm so glad to have found this thread. Everything described above worked also for me.

wsl --shutdown wsl --update

I feedbacked this thread to GPT-4, maybe it will learn from it.

strzyzewski avatar Mar 30 '23 11:03 strzyzewski

I used the command "wsl --update", but it didn't return right result and it was always stay in "Checking for update...". How should i do?

Y-Torches avatar Mar 30 '23 14:03 Y-Torches

I used the command "wsl --update", but it didn't return right result and it was always stay in "Checking for update...". How should i do?

Are you able to monitor the network traffic to check if any firewall rules are blocking the update request? For example turning off the Windows firewall might help.

strzyzewski avatar Mar 30 '23 14:03 strzyzewski