WSL: Ubuntu installation stuck on WSL (Windows 10 Pro Insider Preview)
Identified Workarounds (Added by WSL maintainers)
Fix App and browser control
- Open “Window Security”
- Open “App & Browser control”
- Click “Exploit protection settings” at the bottom
- Switch to “Program settings” tab
- Add/Locate “C:\WINDOWS\System32\vmcompute.exe” in the list and expand it
- Click “Edit”
- Scroll down to “Code flow guard (CFG)” and uncheck/check “Override system settings” (CFG must be ON for this app!)
- Reboot
https://github.com/microsoft/WSL/issues/6405#issuecomment-1297311116 Thank you to: @shtormish !!
Press ctrl+c
https://github.com/microsoft/WSL/issues/6405#issuecomment-1054803355 Thank you @sparcbr
Original issue content (End of content added by WSL maintainers)
Environment
Windows build number: 21277
Your Distribution version: Ubuntu 20.04
Whether the issue is on WSL 2 and/or WSL 1: 2
Steps to reproduce
- Install the latest build of Windows Insider Preview (Dev Channel)
- Set up Windows
- Enable Hyper-V, Hypervisor Platform, Containers
- In cmd.exe (Admin):
wsl --install - Reboot
- Ubuntu window opens, says “Installing, this may take a few minutes” for several hours.
WSL logs:
Expected behavior
Ubuntu should install and ask me to configure my user account.
Actual behavior
Hangs on “installing” with no errors.
Edit 2024: Workarounds
About this issue
- Original URL
- State: open
- Created 6 years ago
- Reactions: 25
- Comments: 56
I got the same issue, but found a workaround: you just have to use ctrl+c and then it will continue and ask you for a username and password
weird but its actually worked 😂
UPD Have found fix that worked for me here https://github.com/microsoft/WSL/issues/7505
It seems that vmcompute.exe must be strictly Code flow guard (CFG) enabled, otherwise it will not work.
Here is reproduce of workaround ===>
That command needs a parameter, it would look like
wsl.exe --install -d Ubuntu. Before you do that, do:If either of those fail or hang, please collect WSL logs and post the backlink to the feedback item here. You don’t need to let it run for hours while collecting the logs, just 30 seconds or so will do, then close the window.
Had the same issue and this solved it.
I am running Windows 10 Pro version 21H1.
@oidrissi
yup, same for me.
what worked for me is running,
wsl --install Ubuntu --web-downloadsource: https://github.com/microsoft/WSL/issues/9390#issuecomment-1363478259
It works! saved my day!!!
The
--installfeature is only available on Insiders, as of 20211.Done! Surprised this is still open 3 years later 😉
Confirming this works form me as well (Win10, 22H2), thanks a lot!
Just to note, “Override system settings” was already checked (as well as “On” and “User strict CFG”), but after unchecking and checking again, clicking Apply, and restarting I was finally able to install via
wsl.##This worked. You saved my life
This actually worked for me. It’s wild, how enabling exploit protection can solve an issue insted of creating one. 😮
Incredible that this worked.
2023/12/12 - still works like a charm
Thank you. this worked for me. The
--web-downloadwas also useful in updating wsl.For Windows 11This just makes me quit the install
Have same trouble. Tried install Ubunty and debian, each time cmd window opens, says “Installing, this may take a few minutes” for several hours. Nothing helped(
Here is logs taken with recommended tool from MS WslLogs-2022-10-31_02-44-26.zip WslLogs-2022-10-31_02-36-29.zip WslLogs-2022-10-31_02-46-07.zip
9/23/2022, this is still the best solution