Bash now fails with error 0x8007002
Issue) Windows Subsystem for Linux fails to launch with error Error: 0x80070002 Press any key to continue...
Nothing shows up in the logs.
I have uninstalled/reinstalled numerous times, completely deleted the C:\Users\XXXX\AppData\Local\lxss directory and each time when I launch bash that is the error. It worked before but my health went bad for a while and when I got well enough to start using it again that was and is the error I get.
I have tried every solution and then some and still nothing. Sigh. I really don't want to have to go back to Cygwin and or Mingw32
Any ideas?
From Control/Programs and Features/Turn Windows features on or off
Please fill out the issue template.
This bug-tracker is monitored by developers and other technical types. We like detail! So please use this form and tell us, concisely but precisely, what's up. Please fill out ALL THE FIELDS!
If you have a feature request, please post to the UserVoice.
If this is a console issue (a problem with layout, rendering, colors, etc.), please post to the console issue tracker.
Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues. Instead, send dumps/traces to [email protected], referencing the GitHub bug number. Ideally, please configure your machine to capture minidumps, repro the issue, and send the minidump from "C:\Windows\minidump".
Your Windows build number: Microsoft Windows [Version 10.0.16299.248]
What you're doing and what's happening: Clicking the icon What's wrong / what should be happening instead: Error: 0x80070002 Press any key to continue... it should drop me to a bash shell
Strace of the failing command, if applicable: (If some_command is failing, then run strace -o some_command.strace -f some_command some_args, and link the contents of some_command.strace in a gist here) not sure how ,. strace -o bash.strace 'strace' is not recognized as an internal or external command
See our contributing instructions for assistance.
Could you please collect logs while trying to launch?
https://github.com/Microsoft/WSL/blob/master/CONTRIBUTING.md#8-detailed-logs
This is mysterious... Lxcore is failing to launch the init binary.
Could you share the contents of the [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Lxss] registry key?
I'll take a look at your logs when I get into the office. In the meantime I see you are still using the legacy distro (installed via lxrun). Could you try a distro from the store?
First uninstall the legacy distro via "lxrun.exe /uninstall"
Update: Took a look at your registry key and everything looks normal. I suspect something got corrupted in your legacy distro install. Definitely try to install a distro from the Microsoft Store and let me know if that still gives you problems.
how many distros are there? I've ONLY installed via turn on/off windows features.
So I ran this
`Microsoft Windows [Version 10.0.16299.248] (c) 2017 Microsoft Corporation. All rights reserved.
C:\WINDOWS\system32>lxrun.exe /uninstall Warning: lxrun.exe is only used to configure the legacy Windows Subsystem for Linux distribution. Distributions can be installed by visiting the Windows Store: https://aka.ms/wslstore
This will uninstall Ubuntu on Windows. This will remove the Ubuntu environment as well as any modifications and new applications with the exception of:
C:\Users\Craig\AppData\Local\lxss\home C:\Users\Craig\AppData\Local\lxss\root
Type "y" to continue: y Uninstalling...
C:\WINDOWS\system32>`
Then unchecked it via the add/remove features.
and after a reboot now what.
I have a working bash shell again :) Thanks.
C:\WINDOWS\system32>lxrun.exe /uninstall Warning: lxrun.exe is only used to configure the legacy Windows Subsystem for Linux distribution. Distributions can be installed by visiting the Windows Store: https://aka.ms/wslstore_
I know you have it working but I just wanted to point this out. As you can see by the error, lxrun.exe is for legacy WSL. Take a look at Settings/Apps/Ubuntu/Advanced Options
From there you have two choices:
- Repair (If the app is not working right, we can try to repair it. The app's data wont be affected)
- Reset (If the app still isn't working right, reset it. The app's data will be deleted)
@TheQuestor Wait i don't get it how did you fix it please tell me i really need to fix it
ok the steps "I" took are.
Control Panel/Programs and Features/Turn windows features on and off go down to Windows Subsystem for Linux and toggle it off if it is already ticked and click ok if it is not ticked then tick it and click ok. If it was on and you turned it off then go back and renable it and click ok.
Then go to Microsoft store and download whatever flavor of Linux you wish to run. I use Ubuntu. Just search for Ubuntu and download and install it.
Once done you "should" have a working bash again.
At this point don't forget to run sudo apt-get update && sudo apt-get dist-upgrade to make sure you're all patched and upgraded and good to go.
Glad to hear this is working for you now.
@TheQuestor Hey an, wanted to thank you for your post. Your solution worked for me. I was worried I was going to have to do another clean install. ooof.
Hello
PS C:\Users\shahj\Downloads\Ubuntu-16.04> wslconfig.exe
Performs administrative operations on Windows Subsystem for Linux
Usage:
/l, /list [/all] - Lists registered distributions.
/all - Optionally list all distributions, including distributions that
are currently being installed or uninstalled.
/s, /setdefault <DistributionName> - Sets the specified distribution as the default.
/u, /unregister <DistributionName> - Unregisters a distribution.
I first got a list of all the Windows Subsystems for Linux currently installed on the machine:
PS C:\Users\batman\Downloads\Ubuntu-16.04> wslconfig.exe /l
Windows Subsystem for Linux Distributions:
Ubuntu-18.04 (Default)
Ubuntu
I then deleted them both:
PS C:\Users\batman\Downloads\Ubuntu-16.04> wslconfig.exe /u Ubuntu
Unregistering...
PS C:\Users\batman\Downloads\Ubuntu-16.04> wslconfig.exe /l
Windows Subsystem for Linux Distributions:
Ubuntu-18.04 (Default)
PS C:\Users\batman\Downloads\Ubuntu-16.04> wslconfig.exe /u Ubuntu-18.04
Unregistering...
Ensured there were no existing subsystems:
PS C:\Users\batman\Downloads\Ubuntu-16.04> wslconfig.exe /l
Windows Subsystem for Linux has no installed distributions.
Distributions can be installed by visiting the Windows Store:
https://aka.ms/wslstore
PS C:\Users\batman\Downloads\Ubuntu-16.04>
And I was up and running again!
Just re-installed the Windows Subsystem for Linux again.
I gave up on WSL a while back and went with cygwin. For grins I just tried reinstalling per the above instructions and still no DNS to IP translation. I'm now at Windows 1803.