Remove `wsl --unregister DISTRO_NAME` from the recommended commands to be run when "something goes wrong"
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 200
- Forks
- 53
- PR merge metrics
- No merged PRs in 30d
Description
Description
I had the below two windows updates performed
- Cumulative Update for Windows 11 Insider Preview (10.0.22623.870) (KB5018499)
- Update Stack Package - (Version 1022.1018.1012.0)
And on restart I see a window saying "Something went wrong". And was asked to run the following commands
Something went wrong.
Please restart WSL with the following command and try again:
wsl --shutdown
wsl --unregister DISTRO_NAME
But wsl --unregister DISTRO_NAME is a dangerous command and should not be run by the uninitiated.
--unregister <Distro>
Unregisters the distribution and deletes the root filesystem.
This does not seem to be a Windows WSL issue. I was redirected to this repo - here is my original issue raised in microsoft/WSL#9049
I've attached the image of the window asking me to run wsl --unregister DISTRO_NAME

Need and use case
No warning is currently given when asking the user to run wsl --unregister DISTRO_NAME .
I had previously faced this same issue ("Something went wrong") and had unknowingly ran wsl --unregister (link to my previous issue - microsoft/WSL#8992 ). Which resulted me in loosing my data, I've recovered since then. But adding a warning to let future users know of the consequence would be great.
Additional information
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Search the Ubuntu/WSL repository for the exact wsl --unregister DISTRO_NAME text and inspect the entry point that assembles the “Something went wrong” guidance. Remove that recommendation, then verify the displayed recovery instructions no longer include the destructive command.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, shell
- Domain
- cli, operating-systems
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100