Skip to content

Console opens only after restart, then stops #4047

Closed

Description

  • Microsoft Windows [Version 10.0.17763.503]

  • opening console works only after reboot, you can open OpenSuse or Ubuntu console or type bash in cmd and all works fine, after some use if you close all windows with console you can't open again, say you open OpenSuse42.3 the window will show up but there is no prompt, if you type bash in cmd, the command will start execution and hang, no prompt will show up.
    Seems to be distro unrelated as both ubuntu and opensuse are affected.

  • What's wrong / what should be happening instead:
    Prompt never shows up, should show up after opening a console window or execution command in cmd/powershell

opensuse-bash
cmd-bash

logs.zip

Activity

  1. bigxd123 commented on Jun 24, 2019

    @bigxd123

    same problem

  2. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    same problem. any updates? this is ridiculous. i use this to make a living.

  3. benhillis commented on Jul 11, 2019

    @benhillis
    Member

    What state is the LxssManager service in while this is happening?

  4. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    LxssManager is running. It fails to stop/restart. Tried launching bash as admin and non-admin, no difference. I've been using it for months without issue. Suddenly started happening this week.

  5. benhillis commented on Jul 11, 2019

    @benhillis
    Member

    If you "sc stop lxssmanager" from admin, does the service stop or does it get stuck in the "stopping" state?

  6. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig
    C:\Windows\system32>sc stop lxssmanager
    [SC] ControlService FAILED 1061:
    
    The service cannot accept control messages at this time.
    
    C:\Windows\system32>sc query lxssmanager
    
    SERVICE_NAME: lxssmanager
            TYPE               : 30  WIN32
            STATE              : 3  STOP_PENDING
                                    (NOT_STOPPABLE, NOT_PAUSABLE, IGNORES_SHUTDOWN)
            WIN32_EXIT_CODE    : 0  (0x0)
            SERVICE_EXIT_CODE  : 0  (0x0)
            CHECKPOINT         : 0x2
            WAIT_HINT          : 0xea60
    
  7. benhillis commented on Jul 11, 2019

    @benhillis
    Member

    Thanks. This is an issue that I've been debugging for a while. In the meantime, to get back to a working state if you kill the svchost.exe that is running the LxssManager service. You can get this pid via the services tab of task manager. You can avoid this issue by leaving a window open, or launching something in the background like a detached tmux session.

  8. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    I get access denied message when trying to kill that svchost process

  9. benhillis commented on Jul 11, 2019

    @benhillis
    Member

    From task manager?

  10. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    yes, end task from task manager and also from taskkill on cmd as admin

  11. benhillis commented on Jul 11, 2019

    @benhillis
    Member

    Interesting... I can do that on my machine with no issues. My other workarounds will still work for you though as I diagnose this issue.

  12. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    ok, i will reboot i guess and then just keep a shell open. let me know if there is anything else you'd like me to try before rebooting and losing this broken state?

  13. benhillis commented on Jul 11, 2019

    @benhillis
    Member

    If possible, a dump of the service might be useful, but if you cant kill it it's unlikely you'll be able to collect a memory dump.

  14. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    nope, no luck also get access denied. next time it happens i can try again.

  15. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    after restart i can start bash. but then if i close it, and try to open again it hangs again. once again can't kill the svchost process or take a dump of it, getting access denied.

  16. 5 remaining items

  17. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    k, np, brb

  18. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    ugh, now bash starts again after closing (not something i thought i'd complain about!) i collected traces, but guessing they aren't particularly helpful?

  19. benhillis commented on Jul 11, 2019

    @benhillis
    Member

    Yeah I'd need a trace of the repro. In the past is it possible you waited about 5 minutes before attempting to re-launch?

  20. dfeinzeig commented on Jul 11, 2019

    @dfeinzeig

    when i tried a few minutes ago i successfully launched it, tried uptime, closed it, and then immediately tried to relaunch but it failed

  21. jgoeglein commented on Jul 14, 2019

    @jgoeglein

    Found this thread while having the same issue. Ran 3 log traces as described. Adding additional logs in case they help.

    Surface Pro 6. Version 10.0.18362 Build 18362

    I first ran Ubuntu directly. After that, I attempted to run bash from Powershell with the same result (screenshots below). I waited roughly a minute for each attempt.

    image

    image

    lxcoreLogs.zip

  22. jgoeglein commented on Sep 15, 2019

    @jgoeglein

    An update to try for anyone else coming along - I removed BitDefender antivirus and haven't had this issue since.

  23. arsdever commented on Oct 24, 2020

    @arsdever

    Any progress made on this scope? Still happens on my machine

  24. MerzDaniel commented on Mar 2, 2021

    @MerzDaniel

    Also (or again) hangs with the most recent windows update KB4023057 . I have no HyperV installed. Clean restart fixed it

  25. stemabo commented on Nov 29, 2021

    @stemabo

    +1 cannot open nano or vim
    Terminal appears to be fine first, but starting nano or vim results in a blanc black screen.
    Need to then hit CTRL+X to get my prompt back, this also displays some zombie-nano content: the content of the file I was trying to open in nano + a grey "GNU nano 4.8" header - but at the bottom I am back at the command prompt.
    reboot does not resolve the issue

  26. lafloresb commented on Jan 6, 2023

    @lafloresb

    The best solution that always worked for me was to:

    1. Disable WSL windows feature
    2. Restart OS
    3. Enable WSL windows feature
    4. Restart OS
    5. It is going to work again without deleting any of your WSL environments
  27. Sieboldianus commented on Feb 9, 2023

    @Sieboldianus

    WSL1 Ubuntu 18.04 LTS stopped working today after I installed Debian in another WSL1 distro using lxrunoffline. The other WSL distros (including Debian) continue to work.

    Nothing helps so far:

    • Disabling/Enabling WSL Feature
    • Stopping lxssmanager and starting again
    • Renaming .bashrc in the Ubuntu WSL distro using powershell bash
    • changing the WSL distro start user back to root (id 0)

    I have the feeling this distro is lost. It is only 1 month away from EOL for Ubuntu 18.04 LTS, so I may as well leave the ship to a new distro.

  28. sanba-anass commented on Jun 18, 2023

    @sanba-anass

    The best solution that always worked for me was to:

    1. Disable WSL windows feature
    2. Restart OS
    3. Enable WSL windows feature
    4. Restart OS
    5. It is going to work again without deleting any of your WSL environments

    u saved my day !!!!!!!!! thank u so much

  29. microsoft-github-policy-service commented on Jun 20, 2024

    @microsoft-github-policy-service
    Contributor

    This issue has been automatically closed since it has not had any activity for the past year. If you're still experiencing this issue please re-file this as a new issue or feature request.

    Thank you!

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions