Skip to content

Error: 0x80070040 #2980

Closed
Closed

Description

@MupEHcEH

Hello,
I receive below error message when trying to run bash on windows 10. Tried running it as admin - same error.

C:\WINDOWS\system32>bash
Error: 0x80070040
Press any key to continue...

This was working before, only thing i remember changing was to create a user account for RSA authentication to a Cisco device, but as far as I remember I was still able to launch it after.
There is similar topic #62

Tried uninstall and re-install ubuntu sub-system - still getting same error.
Also installed openSUSE and it works, but I have never used it and I'm not comfortable with it.

Any suggestions?

Thanks,

Activity

  1. bogdan-calapod commented on Apr 16, 2018

    @bogdan-calapod

    Also receive this since a few days ago. Haven't really done anything special that could cause this, but I can supply necessary logs to try and find the problem.

  2. DavGaz commented on Aug 7, 2018

    @DavGaz

    ok, this worked for me, and allowed me to reinstall the ubuntu distro.

    in cmd

    1. you can see the list of installed distros:
      wslconfig /l

    2. delete distro for the list
      wslconfig /u ubuntu

    3. try to run ubuntu distro installer
      "Installing, this may take a few minutes...
      Installation successful!..."

    Error: 0x80070040 is gone!!!

  3. jw-redpanda commented on Nov 11, 2018

    @jw-redpanda

    Encountered similar issue before (Error: 0x80070040) and it was fixed by the following:

    c:> bash.exe
    Error: 0x80070040

    List all distributions

    c:> wslconfig /l
    Windows Subsystem for Linux Distributions:
    Legacy (Default)
    Ubuntu-16.04

    Set ubuntu as default

    c:> wslconfig /setdefault Ubuntu-16.04

    test-run bash. No error is displayed

    c:> bash.exe
    username@pc-abc:[/mnt/c]:

    List again and Ubuntu is set as default

    c:> wslconfig /l
    Windows Subsystem for Linux Distributions:
    Ubuntu-16.04 (Default)
    Legacy

    Uninstall Legacy

    c:> wslconfig /u Legacy
    Unregistering...

    c:> wslconfig /l
    Windows Subsystem for Linux Distributions:
    Ubuntu-16.04 (Default)

    I don't know if it was caused by the very early legacy version of Ubuntu distribution which was uninstalled uncleanly... even though I installed Ubuntu 16.04 via Windows store later. The steps above are simply removal of the "legacy" one. Hope it also works for you.

  4. tara-raj commented on Nov 13, 2018

    @tara-raj

    As mentioned above, using wslconfig is the easiest way to resolve this issue. The error you're running into means the distribution failed to register. wslconfig /u Legacy will unregister the legacy version you have. You can use /s to set the default distribution to your desired one

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions