WSL icon indicating copy to clipboard operation
WSL copied to clipboard

How to get back a fresh WSL?

Open hungcao181 opened this issue 10 years ago • 5 comments

I lost my password to run sudo. I have tried to turn the feature off and then turn on again but it get back the old system, not a fresh one. I would like to have a fresh one to start over or someway to get back my password. Is there any way to do this? thanks

hungcao181 avatar Jul 01 '16 01:07 hungcao181

In Powershell, lxrun /uninstall and lxrun /install

crvv avatar Jul 01 '16 08:07 crvv

lxrun.exe /uninstall /full

benhillis avatar Jul 01 '16 13:07 benhillis

You can also change your password by changing the default user to root, launching bash, and using the passwd tool.

lxrun.exe /setdefaultuser root

benhillis avatar Jul 01 '16 14:07 benhillis

@crvv @benhillis thanks a bunch! it works for me.

hungcao181 avatar Jul 04 '16 07:07 hungcao181

Going to close this out since this is covered in our FAQ.

benhillis avatar Jul 07 '16 15:07 benhillis