wsltty icon indicating copy to clipboard operation
wsltty copied to clipboard

wsltty may cause WSL to hang (Windows 10)

Open DanKaplanSES opened this issue 1 year ago • 4 comments

Every couple of months my WSL hangs until I restart my computer or kill WSL related processes in the task manager. By "hangs," I mean clicking on the terminal icon on my taskbar does not bring up a window, or, it brings up a window that never shows a prompt. I'll go into more detail at the bottom of this issue, or you can see the details I've already described in the WSL tracker

In the title, I use the word "may" because I'm not hundred percent sure wsltty is responsible, but I do have some evidence. When my WSL hangs:

  1. Killing wslbridge2.exe in the task manager sometimes unfreezes WSL so that the wsl --shutdown command completes.
  2. I can't find wslbridge2.exe in the task manager when my system is "stuck," but all the other WSL process seem to be running.

I know this isn't enough information to troubleshoot, but is there a way to generate wsltty logs or wslbridge2.exe logs the next time this happens so that I may be able to provide enough troubleshooting information to rule wsltty out as the cause?

Thanks!


Here's how I start wsltty: %LOCALAPPDATA%\wsltty\bin\mintty.exe --tabbar=4 -o "KeyFunctions=t:new-window-cwd;w:close;AppID=wsltty" --WSL="Ubuntu" --configdir="%APPDATA%\wsltty" -h always - Notice that if an error were causing this problem, the shortcut is set to keep the window open so I could see it: since the window doesn't open at all or doesn't print anything when it opens, WSL/wsltty seems to be experiencing some sort of deadlock. I also want to note that when I'm in this state, no wsl.exe commands complete: if I run wsl --shutdown, the command never finishes.

DanKaplanSES avatar Sep 22 '24 20:09 DanKaplanSES

clicking on the terminal icon

which means the wsltty icon or the native WSL console icon?

is there a way to generate wsltty logs or wslbridge2.exe logs

I'm afraid no. @Biswa96 ?

mintty avatar Sep 23 '24 08:09 mintty

I do not use the WSL anymore and ready to give away the wslbridge2 repository if anyone is interested to maintain it.

Biswa96 avatar Sep 23 '24 13:09 Biswa96

clicking on the terminal icon

which means the wsltty icon or the native WSL console icon?

Sorry, I didn't notice this question until now. I'm clicking on an Ubuntu icon in my taskbar, but I manually changed the icon to look like this. I don't remember what it originally looked like.

If you are asking me if it's a Windows terminal or wsltty, the latter:

Here's how I start wsltty: %LOCALAPPDATA%\wsltty\bin\mintty.exe --tabbar=4 -o "KeyFunctions=t:new-window-cwd;w:close;AppID=wsltty" --WSL="Ubuntu" --configdir="%APPDATA%\wsltty" -h always -

If I haven't provided the information you're looking for, could you word your question a different way because I don't think I understand what you are asking.

DanKaplanSES avatar Oct 13 '24 00:10 DanKaplanSES

Have you updated to wsltty 3.7.6?

mintty avatar Oct 13 '24 03:10 mintty

Released 3.8.0 which drops the wslbridge gateway by default.

mintty avatar Aug 23 '25 02:08 mintty