3
3
I'm new to Unix but interested learn, so started trying to use bash/Ubuntu on Windows. Unfortunately, bash crashed and now bash/Ubuntu seems to be broken as most folders are now missing from the Ubuntu root folder, i.e.:
root@Desktop:~# ls
root@Desktop:~# cd /root
root@Desktop:~# ls
root@Desktop:~# ls -a
. .. .bashrc .profile
I don't have a %localappdata%\lxss
folder (I'm pretty certain this is where the Linux root was originally). I appear to have a %localappdata%\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc
folder, which is apparently the new location for the Linux root, but it is not complete (i.e. doesn't contain a ...\LocalState\rootfs
folder).
After searching for solutions on here and elsewhere, I've tried:
- Completely uninstalling Ubuntu\bash from Windows with
lxrun.exe /uninstall full
. - As above, in conjunction with disabling and re-enabling the Windows Subsystem for Linux (beta) feature too.
- Running:
apt-get remove upstart
,apt-get remove udev
,apt-get autoremove
in bash.
Unfortunately none of the above have solved the problem. Can anybody suggest a way to perform a complete 'factory reset'?
bash is a program. It can run, for example, in a
cmd.exe
window (if you have it built as a Windows executable). Ubuntu is a Linux distribution - which is built around the Linux kernel, that runs on the "bare metal" - not as a Windows application. So it's not quite clear what you mean when you write "base/Ubuntu" is broken. – einpoklum – 2018-01-03T19:45:20.8171Which version are you trying to run: the beta release from the developers' options, or the official release from the Windows store, available with the 1709 upgrade? If you have both installed, then I can imagine that the installation would get confused. Make sure both are uninstalled, then re-install the version you want to use. Note that it is not unusual to have only a few files in the
root
home directory:ls /
will show whether you have a reasonable directory structure. – AFH – 2018-01-03T19:46:21.117You are trying solutions for the legacy (Beta) WSL. You need to use the commands for the current version of WSL which only work on 1709. In order to reset WSL on Windows 10 Version 1709 you need to remove Ubuntu from the Windows Store then simply install it again from the Windows Store. – Ramhound – 2018-01-03T21:25:35.800
If you are not running the current build of Windows 10 Version 1709, update your question with a screenshot of the output of
winver
, be sure to remove any license or PPI. – Ramhound – 2018-01-03T21:38:53.803Hi @Ramhound. I think you're correct, thank you -- the problem appears to have stemmed from my confusion between the legacy (Beta) WSL that I had been running and WSL on Windows 10 Version 1709, which I am running. – Robert – 2018-01-03T22:50:20.693