wsl2 fail to startup with Wsl/Service/CreateInstance/CreateVm/HCS/ERROR_FILE_NOT_FOUND
Windows Version
Microsoft Windows [版本 10.0.26100.2894]
WSL Version
2.4.10.0
Are you using WSL 1 or WSL 2?
- [x] WSL 2
- [ ] WSL 1
Kernel Version
5.15.167.4
Distro Version
Ubuntu 22.04
Other Software
No response
Repro Steps
start wsl
Expected Behavior
enter wsl shell
Actual Behavior
Wsl/Service/CreateInstance/CreateVm/HCS/ERROR_FILE_NOT_FOUND (forget to save whole terminal output, sorry)
Diagnostic Logs
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:
- WSL distro fails to start with "Error code: Wsl/Service/CreateInstance/CreateVm/HCS/ERROR_PATH_NOT_FOUND" (#11677), similarity score: 0.81
- Error code: Wsl/Service/CreateInstance/CreateVm/ConfigureNetworking/ERROR_FILE_NOT_FOUND upon executing WSL (#9840), similarity score: 0.79
Closed similar issues:
- wsl startup failed after windows update Error code: Wsl/Service/CreateInstance/CreateVm/MountVhd/HCS/ERROR_NOT_FOUND (#11253), similarity score: 0.80
- Catastrophic failure :Error code: Wsl/Service/CreateInstance/MountVhd/HCS/0x80070570 (#11849), similarity score: 0.80
- Wsl/Service/CreateInstance/CreateVm/HCS/E_INVALIDARG (#11260), similarity score: 0.79
Note: You can give me feedback by thumbs upping or thumbs downing this comment.
Diagnostic information
Detected appx version: 2.4.10.0
Detected user visible error: Wsl/Service/CreateInstance/CreateVm/HCS/ERROR_FILE_NOT_FOUND
I tried "disable 'Virtual Machine Platform' -- reboot -- enable that option again", but didn't work.
Later I tried "winget uninstall --id Microsoft.WSL" then install https://github.com/microsoft/WSL/releases/tag/2.4.8. It can enter wsl shell.
Thank you @oXoSh. This issue should be fixed in the next release.
In the meantime, you can work around the issue by manually creating a C:\Windows\System32\lxss\lib folder.
This should be fixed with https://github.com/microsoft/WSL/releases/tag/2.4.11.
Issue still occuring in 2.4.11.0:
Failed to attach disk 'C:\Program Files\WSL\system.vhd' to WSL2: The system cannot find the file specified.
Error code: Wsl/Service/CreateInstance/CreateVm/MountVhd/HCS/ERROR_FILE_NOT_FOUND
Rolling back to 2.4.8 as @oXoSh said here worked!
I just upgradede wsl with wsl --upgrade and now I cannot start any of my vms. They all error: The system cannot find the file specified. Error code: Wsl/Service/CreateInstance/CreateVm/HCS/ERROR_FILE_NOT_FOUND
wsl --version WSL version: 2.7.10.0 Kernel version: 6.18.33.2-2 WSLg version: 1.0.73.2 MSRDC version: 1.2.6676 Direct3D version: 1.611.1-81528511 DXCore version: 10.0.26100.1-240331-1435.ge-release Windows version: 10.0.26200.8655
This fixed it for me: https://github.com/microsoft/WSL/issues/40488#issuecomment-4706460260
The link in the comment is for version 2.7.8.0. I used the installer for 2.7.10.0, which you can find here: https://github.com/microsoft/WSL/releases#release-2.7.10