You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
WSL is non-responsive after waking from hibernate #8696
Hibernate machine
Start up windows
open a new terminal
Expected Behavior
Shouldn't hang
Actual Behavior
No response, terminal hangs. wsl --shutdown from command prompt also hangs, only solution is to restart the machine.
Diagnostic Logs
No response
Reacted by Joshua J Wilborn, Giorgos Sarigiannidis, Siddhardha Sukka, Francis Lacroix, David Yan, Shane Harper, Douglas Thrift, zags, Robert Franz, Mohammad Taghavi and 244 more
Reacted by Angelos Pikoulas, Spencer Layne and Lev Khobotov
Reacted by Matti Suoraniemi, Charles Jenkins, Ben Jones, xaxa, mccarthyp-snet, Gavin Shaughnessy, quispiam, Nikita Zaytsev, Janne Järveläinen, COLIN (コリン) and 184 more
Reacted by Felipe Ojeda, Luiz Mattos, Svyat Kovtun, Ruiming LU, Stefan Nikolic and a.ghrb
Same happens to me, no posible to wsl --shutdown, it hangs as well. The only solution is to restart windows, what is is quite annoying.
Reacted by Jarle Nygård, Kian Mayne, AntoineMdn, Patakfalvi Örs-Krisztián, Adri Merrett, Artur Rodkin, Xan Torres, Fubin Zhang, dani, psmolkin and 116 more
I don't think this is related to hibernation, I was also using PHPStorm (latest version which was supposed to have fixed a bug with WSL). I have finally abandoned PHPStorm and have been using VSCode for the last week or so, and no more problems with WSL crashing, it has been rock solid ever since.
Reacted by Piotr Kardasz
Reacted by Tanyo Georgiev, JPetitpierre, Daniel Parra, Nikita Zaytsev, PieterE, chokdee, Kian Mayne, khiem4, ken-cdit, jinyeng and 49 more
On Windows OS Build 22000.918, I am also getting a freeze of WSL2 on return from hibernate. CPU use is high:
I also can't stop the service:
WSL doesn't respond at all (listing doesn't work, status doesn't work, version doesn't work):
I am using the latest WSL release 0.66.2.
Restart works to bring things back but that is all that works.
Reacted by Mario, Nikita Zaytsev, Kevin Chu, Kyle McCarthy, Aldan Creo, Patakfalvi Örs-Krisztián, STX5, Sarasa Kisaragi, Artur Rodkin, Zhenhuan Chen and 38 more
Reacted by Don DuChateau, Ruben Esteche and Angelos Pikoulas
rowleya you may to try update Docker Desktop for last version (v4.12) #8703
In my case I have same problems with WSL2 and hibernate behavior. I tried to turn off hibernation but looks like my laptop dont support S1-S3 sleep mode. So updating the Docker fixed vmmem leak, but not wsl2 stucks after waking up.
I don't have Docker Desktop installed here as I use docker on WSL2 when needed. Note that there isn't a vmmem memory leak here; that is just how much memory I am using!
Of interest, I usually use eclipse within WSL2 and leave that running when hibernating. That had been working until recently, but with the issue, it also meant that the CPU usage of VMMem went very high when restoring from hibernate. On Friday I closed eclipse before hibernating, and on coming back this morning, the high CPU is gone, but WSL still won't start up again without a restart of the computer.
Reacted by Michal Schwarz, STX5, Fubin Zhang, Pavel Botvinkin, Elon Jiang, Niranjan Manjunath, Alessio Lombardi, Felipe A L Pereira, Manu, Datta - TekSystem and Angelos Pikoulas
OK, even more interesting, I saw a thread about collecting wsl logs, so I tried to do that this morning, running the process just before hibernating. It seems that the issue didn't then show up. I don't know if this means that it is something to do with the amount of time of hibernation or something... I will try to remember to run the logging process tonight again and see what happens tomorrow...
I use pycharm from WSL and once laptop wakes from hibernation, the opened app is gone and opening it again does not work. Have to wsl --shutdown to make it work WHICH IS EXTREMELY ANNOYING but trust microsoft TO NEVER FIX ANYTHING
The only fix that helped me is moving my work process from a laptop (I used Surface Pro 6 / 7+) to my Desktop PC which I build myself with pretty old MSI motherboard (MPG Z390I) - I have never seen that issue anymore (for the past 1 year), despite the fact that I've just copy-pasted all the configuration which remained at the virtual disk AS IS (simply copied .vhdx file from a path specified at registry path Computer\HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Lxss\{randon uuid}\BasePath from a laptop to desktop and then tweaked the reference of it to a new path at the PC)
Surface Pro 7+ Config:
Edition Windows 10 Pro
Version 221-12
OS Build 19045.6093
WSL version: 2.0.14.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.6093
DesktopPC Config
Edition Windows 10 Pro
Version 221-12
OS Build 19045.6093
WSL version: 2.4.12.0
Kernel version: 5.15.167.4-1
WSLg version: 1.0.65
MSRDC version: 1.2.5716
Direct3D version: 1.611.1-81528511
DXCore version: 10.0.26100.1-240331-1435.ge-release
Windows version: 10.0.19045.6093
Having to force-restart WSL every time my laptop goes to sleep is really a toll on productivity. I've been trying to resist for years, but maybe , as a developper, I should just make my life easier and switch to a mac.
Reacted by esuter-ki, Rohan Gayen and Michał Cywiński
Having to force-restart WSL every time my laptop goes to sleep is really a toll on productivity. I've been trying to resist for years, but maybe , as a developper, I should just make my life easier and switch to a mac.
Try it on task scheduler. Was the only solution for me. wsl -d $InstanceName -e bash -c "echo alive $(date)"
paddyfink can you check your kernel version? as of March 2025, this was supposed to be fixed with the 6.6.X branch of the WSL kernel from Microsoft: #6982 (comment)
Comprehensive Analysis: Sleep/Wake WSL Failure with BSOD During Recovery
I encountered this issue today (2025-12-31) and performed an in-depth analysis. Adding my findings here as they may help others and provide additional data for Microsoft.
Summary
After Windows woke from overnight standby/hibernate:
WSL commands failed with Wsl/Service/E_UNEXPECTED
LxssManager service was stopped, but distribution showed as "Running" (inconsistent state)
Existing shell sessions inside WSL were still functional - proving the VM was alive, only the Windows↔VM communication (vsock) was broken
Manually restarting LxssManager didn't help - services entered "zombie running" state
Attempting Stop-Service vmcompute -Force caused a BSOD (dxgkrnl.sys crash)
Also hitting this on Windows 11 Insider Dev — devcontainer/Docker Desktop (WSL2 backend) becomes unusable after the host hibernates: containers report "Up" but docker exec fails at the nsexec/setns layer (failed to open /proc/<pid>/ns/ipc: No such file or directory). Confirmed wsl --shutdown, restarting vmcompute/LxssManager, and removing/recreating the container do not fix it — only a full Windows restart recovers.
Worth flagging for anyone seeing a sudden uptick: Windows is rolling out a new adaptive hibernate policy (Insider Preview Build 28120.2630, July 2026) that hibernates more readily at lower battery to reduce Modern Standby drain. That means machines that previously stayed in Modern Standby (and survived fine) are now escalating to full Hibernate far more often — so this long-open bug is getting tripped more frequently, not because anything about our setup changed. For anyone doing dev container work on a laptop, this is a genuine showstopper: the workflow depends on WSL2 state surviving sleep, and right now it doesn't.
I noticed that the issue doesn't happen when I close all VS Code & terminal windows. The next morning, I can see that services are still running in WSL (e.g. MongoDB, ...).
Today at EOD, I will close VS Code and keep the terminal up to see what happens.
Turning off the hibernation timeout fixes this for me on my Windows PC.
On battery, Kernel-Power Event 42 showed Hibernate from Sleep - Fixed Timeout every night, followed by a WSL hang. Disabling the on-battery timeout (elevated prompt):
2 nights (update) with no hang and no VS Code Remote-WSL freeze (WSL 2.6.3.0). It still hibernates via Standby Battery Budget Exceeded without issue. Only a few nights, so not a confirmed fix.
Activity
roja45 commentedon Aug 6, 2022
roja45 commentedon Aug 6, 2022
roja45 commentedon Aug 8, 2022
WslLogs-2022-08-08_08-43-05.zip
logs captured while trying to restart wsl
De-Been-Tech-Solutions commentedon Aug 9, 2022
WSL has found it hard to reconnect to the PC's storage by the sounds of things.
The next time this happens, I believe restarting WSL will fix it, as it does appear to have a memory leak as well.
Close then re-open is what I meant by this.
roja45 commentedon Aug 9, 2022
But how do I restart wsl? wsl --shutdown just hangs.
De-Been-Tech-Solutions commentedon Aug 9, 2022
You close it.
Then you re-open it.
De-Been-Tech-Solutions commentedon Aug 9, 2022
If it won't close, open task manager then kill the process from there.
david-dlc-cerezo commentedon Aug 16, 2022
Same happens to me, no posible to
wsl --shutdown, it hangs as well. The only solution is to restart windows, what is is quite annoying.QuentinLemCode commentedon Aug 16, 2022
Hello

Same issue for me, the wsl command hangs at each command
Edit : I managed to relaunch it without restarting windows by killing all wsl processes in task manager
roja45 commentedon Aug 16, 2022
I don't think this is related to hibernation, I was also using PHPStorm (latest version which was supposed to have fixed a bug with WSL). I have finally abandoned PHPStorm and have been using VSCode for the last week or so, and no more problems with WSL crashing, it has been rock solid ever since.
pnmcosta commentedon Sep 7, 2022
I'm on 22000.918 I do get an error after hibernate wake:

Only a full restart fixes it! 👎
rowleya commentedon Sep 8, 2022
On Windows OS Build 22000.918, I am also getting a freeze of WSL2 on return from hibernate. CPU use is high:

I also can't stop the service:

WSL doesn't respond at all (listing doesn't work, status doesn't work, version doesn't work):

I am using the latest WSL release 0.66.2.
Restart works to bring things back but that is all that works.
egorgam commentedon Sep 11, 2022
rowleya you may to try update Docker Desktop for last version (v4.12) #8703
In my case I have same problems with WSL2 and hibernate behavior. I tried to turn off hibernation but looks like my laptop dont support S1-S3 sleep mode. So updating the Docker fixed vmmem leak, but not wsl2 stucks after waking up.
rowleya commentedon Sep 12, 2022
I don't have Docker Desktop installed here as I use docker on WSL2 when needed. Note that there isn't a vmmem memory leak here; that is just how much memory I am using!
Of interest, I usually use eclipse within WSL2 and leave that running when hibernating. That had been working until recently, but with the issue, it also meant that the CPU usage of VMMem went very high when restoring from hibernate. On Friday I closed eclipse before hibernating, and on coming back this morning, the high CPU is gone, but WSL still won't start up again without a restart of the computer.
rowleya commentedon Sep 12, 2022
OK, even more interesting, I saw a thread about collecting wsl logs, so I tried to do that this morning, running the process just before hibernating. It seems that the issue didn't then show up. I don't know if this means that it is something to do with the amount of time of hibernation or something... I will try to remember to run the logging process tonight again and see what happens tomorrow...
491 remaining items
developer992 commentedon Aug 5, 2025
Still an issue.
I use pycharm from WSL and once laptop wakes from hibernation, the opened app is gone and opening it again does not work. Have to wsl --shutdown to make it work WHICH IS EXTREMELY ANNOYING but trust microsoft TO NEVER FIX ANYTHING
wvolkov commentedon Aug 5, 2025
The only fix that helped me is moving my work process from a laptop (I used Surface Pro 6 / 7+) to my Desktop PC which I build myself with pretty old MSI motherboard (MPG Z390I) - I have never seen that issue anymore (for the past 1 year), despite the fact that I've just copy-pasted all the configuration which remained at the virtual disk AS IS (simply copied .vhdx file from a path specified at registry path
Computer\HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Lxss\{randon uuid}\BasePathfrom a laptop to desktop and then tweaked the reference of it to a new path at the PC)Surface Pro 7+ Config:
DesktopPC Config
paddyfink commentedon Sep 13, 2025
Having to force-restart WSL every time my laptop goes to sleep is really a toll on productivity. I've been trying to resist for years, but maybe , as a developper, I should just make my life easier and switch to a mac.
DanielMOliveira commentedon Sep 14, 2025
Try it on task scheduler. Was the only solution for me.
wsl -d $InstanceName -e bash -c "echo alive $(date)"Crypto-Spartan commentedon Sep 15, 2025
paddyfink can you check your kernel version? as of March 2025, this was supposed to be fixed with the 6.6.X branch of the WSL kernel from Microsoft: #6982 (comment)
enBonnet commentedon Sep 22, 2025
It's actually working, but I'll take, like, 10 minutes. It does to me.
I have made a script to reset wsl:
Crypto-Spartan commentedon Sep 24, 2025
Ender Bonnet (@enBonnet) can you check your current kernel version from within WSL?
enBonnet commentedon Sep 24, 2025
Output->
6.6.87.2-microsoft-standard-WSL2I posted in another thread (#8763 (comment)) after removing docker desktop it when back to work normally after sleep/hibernate.
Edit: I have put it to sleep a couple of times during the day, and it is still working great.
dodjango commentedon Dec 31, 2025
Comprehensive Analysis: Sleep/Wake WSL Failure with BSOD During Recovery
I encountered this issue today (2025-12-31) and performed an in-depth analysis. Adding my findings here as they may help others and provide additional data for Microsoft.
Summary
After Windows woke from overnight standby/hibernate:
Wsl/Service/E_UNEXPECTEDStop-Service vmcompute -Forcecaused a BSOD (dxgkrnl.sys crash)Evidence from Logs
WSL Journal Errors:
Error 110 = ETIMEDOUT - The vsock connection between Windows and WSL VM timed out.
Windows Event Log:
The virtual network adapter (part of Hyper-V/WSL infrastructure) failed during the sleep→wake transition.
Hyper-V Logs:
No entries for the incident date - the Hyper-V services were never properly restarted after sleep.
BSOD Details (when attempting recovery)
SYSTEM_SERVICE_EXCEPTION(0x3b)dxgkrnl.sys(DirectX Graphics Kernel)STATUS_ACCESS_VIOLATIONThis links to #8459 - the GPU paravirtualization layer crashes when vmcompute is force-stopped in a corrupt state.
Full Documentation
Complete analysis with timeline, system config, and all log excerpts:
📄 https://gist.github.com/dodjango/545a8322b43697fb81f214fad245a263
Safe Workaround
When
wsl --shutdownfails and services appear "zombie running":Stop-Service -Forceon Hyper-V servicesRestart-Computerfor a clean recoveryHope this helps track down the root cause. This bug has been open since 2019 (#4311) and affects many users.
enBonnet commentedon Jan 2, 2026
Torsten Mattetat (@dodjango) Can I try to run
Restart-Computerafter each wake up?danielniccoli commentedon Feb 19, 2026
Same issue here. vmmemWSL blown up to over 13 GB. Also using Docker.
WslLogs-2026-02-19_14-09-18.zip
I'm really confused at this issue. It has over 500 comments, is 3.5 years old and it wasn't even assigned to someone. Why is this ignored?
chemwolf6922 commentedon Apr 28, 2026
Hi everyone, we introduced a partial fix for this issue in the 2.7.3 pre-release version. Since the issue is hard to reproduce, it would be very helpful if you could try this out and help validate if the issue is resolved. Thanks.
https://github.com/microsoft/WSL/releases/tag/2.7.3
InfantLab commentedon Aug 31, 2026
Also hitting this on Windows 11 Insider Dev — devcontainer/Docker Desktop (WSL2 backend) becomes unusable after the host hibernates: containers report "Up" but
docker execfails at thensexec/setnslayer (failed to open /proc/<pid>/ns/ipc: No such file or directory). Confirmedwsl --shutdown, restartingvmcompute/LxssManager, and removing/recreating the container do not fix it — only a full Windows restart recovers.Worth flagging for anyone seeing a sudden uptick: Windows is rolling out a new adaptive hibernate policy (Insider Preview Build 28120.2630, July 2026) that hibernates more readily at lower battery to reduce Modern Standby drain. That means machines that previously stayed in Modern Standby (and survived fine) are now escalating to full Hibernate far more often — so this long-open bug is getting tripped more frequently, not because anything about our setup changed. For anyone doing dev container work on a laptop, this is a genuine showstopper: the workflow depends on WSL2 state surviving sleep, and right now it doesn't.
asiby commentedon Sep 24, 2026
I noticed that the issue doesn't happen when I close all VS Code & terminal windows. The next morning, I can see that services are still running in WSL (e.g. MongoDB, ...).
Today at EOD, I will close VS Code and keep the terminal up to see what happens.
derekl-beep commentedon Nov 4, 2026
Turning off the hibernation timeout fixes this for me on my Windows PC.
On battery,
Kernel-PowerEvent 42 showedHibernate from Sleep - Fixed Timeoutevery night, followed by a WSL hang. Disabling the on-battery timeout (elevated prompt):2 nights (update) with no hang and no VS Code Remote-WSL freeze (WSL 2.6.3.0). It still hibernates via
Standby Battery Budget Exceededwithout issue. Only a few nights, so not a confirmed fix.