wslg
wslg copied to clipboard
Windows disappear after network change
Windows Version
Microsoft Windows [Version 10.0.22621.1992]
WSL Version
1.3.15.0
Are you using WSL 1 or WSL 2?
- [X] WSL 2
- [ ] WSL 1
Kernel Version
Kernel version: 5.15.90.4-1
Distro Version
Ubuntu 20.04
Other Software
IntelliJ
Repro Steps
After my windows laptop wake up from hibernation, my IntelliJ window is gone. The application is still running according to the Windows terminal from where I started it.
Expected Behavior
My IntelliJ window should be available.
Actual Behavior
The IntelliJ application is gone.
Diagnostic Logs
Hard to record anything for this problem, I think.
Can confirm this myself, too. Additionally the windows "re-appear", when I open another new window in WSL (doesn't matter what application).
Unfortunately that doesn't work for me. Have just started both firefox and emacs (I don't have that many linux UI apps), but IntelliJ stayed in the shadows :-(
I also encountered this point. After recovering from hibernation, the IntelliJ window disappears and cannot be restored unless I restart wsl
same for me, started after recent pre-release upgrade
WSLg ( x86_64 ): 1.0.57+Branch.main.Sha.0ce123fc070038f61516c223c8c02b9606526bac
Mariner: VERSION="2.0.20230630"
DirectX-Headers:
mesa:
pulseaudio: 6f045ff0dca233a939a2aba815f84d177e294122
FreeRDP: c4030980b29322a9cb2190711a5fadeeeb8b6a33
weston: 26dc435ce884a57b3780592199482e3f0c221b12
Can confirm this myself, too. Additionally the windows "re-appear", when I open another new window in WSL (doesn't matter what application).
it reappers but completely unresponsible for me.
not sure if it is relevant, but there are some errors in wlog.log:
[18:48:23:095] [11:11] [ERROR][com.freerdp.core.transport] - BIO_read returned a system error 11: Resource temporarily unavailable
[18:48:23:095] [11:11] [ERROR][com.freerdp.core] - transport_read_layer:freerdp_set_last_error_ex ERRCONNECT_CONNECT_TRANSPORT_FAILED [0x0002000D]
[18:48:23:100] [11:11] [ERROR][com.freerdp.core.transport] - BIO_should_retry returned a system error 32: Broken pipe
[18:48:23:100] [11:11] [ERROR][com.freerdp.core.transport] - BIO_should_retry returned a system error 32: Broken pipe
[18:48:23:100] [11:11] [ERROR][com.freerdp.core.transport] - BIO_should_retry returned a system error 32: Broken pipe
Confirm the same - all GUI windows (Google Chrome, IntelliJ IDEA) are gone after resuming laptop from hibernation. Problem started after upgrade to WSL 2.0.0.0
Having met this problem recently, I am getting used to it since some popup windows such as JetBrains Toolbox suddenly disappears then randomly shows up in any circumstances. 😂
Having met this problem recently, I am getting used to it since some popup windows such as JetBrains Toolbox suddenly disappears then randomly shows up in any circumstances. 😂
In addition to this, at a few moments, some Linux applications automatically got focused (active) though I did not touch it.
Having the same problem with the latest pre-release wsl 2.0.6.0. The GoLand windows appear occasionally when I open gedit
from shell.
Same here with emacs 29.1, pgtk build, seems something similar to https://github.com/microsoft/wslg/issues/1058
with emacs, starting a second instance brings back the hidden one but I cannot interact with it at all, I can only close it from the "X" in the the taskbar preview
with emacs starting a second instance brings back the hidden one but I cannot interact with it at all, I can only close it from the "X" in the the taskbar preview
Exactly the same for me. The only way to restore is to kill emacs or restart emacs server(if you use one) entirely and rerun it.
This is happening whenever I use Rstudio via Ubuntu. Closing the lid of my laptop for some time hides the window. The thing is, I have optimized my power setting to prevent sleep and allow for background activity, so closing the lid in my case only turns off the display but doesn't put the laptop to sleep.
Using WSL version: 2.0.9.0 in Windows 10 Enterprise.
The problem happened in my system after the latest Windows update.
WSL : 2.0.9.0
Core: 5.15.133.1-1
WSLg : 1.0.59
MSRDC : 1.2.4677
Direct3D : 1.611.1-81528511
DXCore : 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows : 10.0.22621.2715
Thanks @ jonasPoehler , I'm run lightweight Linux GUI App mousepad
every time my computer wake up from hibernate for bring back my WSL environment Emacs.
Same here after update to Microsoft Windows [Version 10.0.19045.3693]
WSL version: 2.0.9.0
Kernel version: 5.15.133.1-1
WSLg version: 1.0.59
MSRDC version: 1.2.4677
Direct3D version: 1.611.1-81528511
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.19045.3693
Issue happens both after sleep and hybernation likewise, but running another GUI app, brings the window back.
I also noticed that the C:\Program Files\WSL\msrdc.exe
process which is running before the sleep - and has the windows attached to it - gets replaced after wakeup with a new instance that does not hold any windows. Although the start parameters are identical in both instances:
msrdc.exe /v:171997E8-A97C-4903-B849-7B6CC984CDD3 /hvsocketserviceid:09F2930D-FACB-11E6-BD58-64006A7986D3 /silent /wslg /plugin:WSLDVC_PACKAGE /wslgsharedmemorypath:WSL\171997E8-A97C-4903-B849-7B6CC984CDD3\wslg "C:\Program Files\WSL\wslg.rdp"
msrdc.exe /v:171997E8-A97C-4903-B849-7B6CC984CDD3 /hvsocketserviceid:09F2930D-FACB-11E6-BD58-64006A7986D3 /silent /wslg /plugin:WSLDVC_PACKAGE /wslgsharedmemorypath:WSL\171997E8-A97C-4903-B849-7B6CC984CDD3\wslg "C:\Program Files\WSL\wslg.rdp"
Can confirm. Emacs and Rstudio both disappear after sleep. Opening a new emacs window restores both. ps shows that emacs is still running after sleep, even though it can't be seen.
$ ps -ef | grep emacs xxxx 56954 32029 1 12:00 pts/4 00:00:00 emacs ../../notes.txt xxxx 56970 56833 0 12:01 pts/6 00:00:00 grep --color=auto emacs
Dont know why my emacs completely frozen after restore. Probably because I self built it with pgtk..
might be same/related to issue #1092 and/or issue #1108?
Hi, Please try to unplug/plug the network interface and see if it reproduces, we should try and merge all these issues that have the same root cause. Thanks,
I can reproduce this behavior if I disconnect from WiFi as described here:
https://github.com/microsoft/wslg/issues/1092
Thanks @alonbl for the hint.
I can reproduce this behavior if I disconnect from WiFi as described here:
- #1092
Same here.
System info: https://github.com/microsoft/wslg/issues/1098#issuecomment-1826277372
Hello @jepet, Can you please modify the title? this is triggered by network change event. Thanks,
The stderr.log suggests that msrdc is stopping similar to what @martin-rueegg wrote.
[15:34:32.847] <5>WSLGd: Run:108: pid 1115 exited with status 0, /init /mnt/c/Program Files/WSL/msrdc.exe msrdc.exe /v:AE690EF1-D9D3-4987-BCFC-85F059BCDC04 /hvsocketserviceid:5632CD8E-FACB-11E6-BD58-64006A7986D3 /silent /wslg /plugin:WSLDVC_PACKAGE /wslgsharedmemorypath:WSL\AE690EF1-D9D3-4987-BCFC-85F059BCDC04\wslg C:\Program Files\WSL\wslg.rdp
Error: debug scope named 'rdp-audio' is already registered.
Error: debug scope named 'rdp-audio-in' is already registered.
The XKEYBOARD keymap compiler (xkbcomp) reports:
> Warning: Unsupported maximum keycode 569, clipping.
> X11 cannot support keycodes above 255.
> Internal error: Could not resolve keysym XF86FullScreen
Errors from xkbcomp are not fatal to the X server
[15:34:41.342] <5>WSLGd: Run:108: pid 1274 exited with status 0, /init /mnt/c/Program Files/WSL/msrdc.exe msrdc.exe /v:AE690EF1-D9D3-4987-BCFC-85F059BCDC04 /hvsocketserviceid:5632CD8E-FACB-11E6-BD58-64006A7986D3 /silent /wslg /plugin:WSLDVC_PACKAGE /wslgsharedmemorypath:WSL\AE690EF1-D9D3-4987-BCFC-85F059BCDC04\wslg C:\Program Files\WSL\wslg.rdp
Error: debug scope named 'rdp-audio' is already registered.
Error: debug scope named 'rdp-audio-in' is already registered.
The XKEYBOARD keymap compiler (xkbcomp) reports:
> Warning: Unsupported maximum keycode 569, clipping.
> X11 cannot support keycodes above 255.
> Internal error: Could not resolve keysym XF86FullScreen
Errors from xkbcomp are not fatal to the X server
WSL version: 2.0.9.0
Kernel version: 5.15.133.1-1
WSLg version: 1.0.59
MSRDC version: 1.2.4677
Direct3D version: 1.611.1-81528511
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.22621.2715
@Microsoft: it is time to merge these duplicate issues (probably better just resolve the issue).
I can confirm that cutting the current network connection will disappear my IntelliJ window. Reconnecting and starting another application (emacs) will make it magically appear again. @alonbl: I've renamed the issue.
Is this the same problem as described here?
In any case, my current workaround is to save this script and run ~/revive.sh or something like that to get my windows back.
#/bin/bash
xclock &>/dev/null &
sleep 2
kill $(pgrep xclock)
Is this the same problem as described here?
Very unlikely: above is related to (likely) WSL1 and an external X11 server, X410, not WSLg ...
In any case, my current workaround is to save this script and run ~/revive.sh or something like that to get my windows back.
#/bin/bash xclock &>/dev/null & sleep 2 kill $(pgrep xclock)
An alternate arguably simpler one-liner if you have the xterm
package installed is to just call xterm -e exit
....
Dear @Microsoft Representative, Please review and merge #1108, #1092, #1098 bugs. Please acknowledge you accept the issue and working on a solution. Please tell us if you require any missing information from us users to make a progress. WSL is unusable when every network change/sleep/hibernate all applications need to be reopened. Forgive me that I am pasting this to all bugs, I do not know which if any you monitor. Thanks,
@hideyukn88 Could you please get this triaged? This is the most annoying issue
@atl-mk, the fix is now released with WSL 2.2.3 https://github.com/microsoft/WSL/releases/tag/2.2.3, which is still pre-release state, if you can try out, you can install it by wsl --update --pre-release
, or download msixbundle from the link, thanks!
@atl-mk, the fix is now released with WSL 2.2.3 https://github.com/microsoft/WSL/releases/tag/2.2.3, which is still pre-release state, if you can try out, you can install it by
wsl --update --pre-release
, or download msixbundle from the link, thanks!
I'm not atl-mk but i also had this problem and indeed 2.23 has improved it and allowed me to remove a few workarounds to reset my screen after network and/or monitor disconnects. Thanks!
@hideyukn88 Ever since you've messaged I've been daily driving this. The issue is MUCH improved. It's not perfect though, I think sleep/wake issues are gone and the problem that remains is transitory network states with WiFi networks and VPN applications (although improved).
I am unfortunately forced to use Cisco Secure Client AnyConnect 5.0.02075 by my workplace if that helps.
If I terminate the VPN application and connect to a WiFi network the applications appear again if I open a new application that would be using WSLg
I feel there's also a new issue where only some of the Windows reappear, but I haven't figured out a pattern here yet.
I agree with @atl-mk, it's much improved. I still see my application dissapear from time to time, and the previous workaround with starting a new GUI application no longer works. I haven't been able to pinpoint when it happens, though. I use the same AnyConnect client.