WSL is non-responsive after waking from hibernate
Version
Windows 11 Pro 21h2 build 22000.832
WSL Version
- [ ] WSL 2
- [ ] WSL 1
Kernel Version
5.10.60.1
Distro Version
Ubuntu 2-.04
Other Software
Docker desktop windows
Repro Steps
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


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.
But how do I restart wsl? wsl --shutdown just hangs.
You close it.
Then you re-open it.
If it won't close, open task manager then kill the process from there.
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.
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
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.
I'm on 22000.918 I do get an error after hibernate wake:

Only a full restart fixes it! 👎
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.
rowleya you may to try update Docker Desktop for last version (v4.12) https://github.com/microsoft/WSL/issues/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.
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...
It happens also to me:
WSL: 0.66.2.0 Kernel: 5.15.57.1 WSLg: 1.0.42 MSRDC: 1.2.3401 Direct3D: 1.606.4 DXCore: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp Windows: 10.0.22000.918
After hibernation (not sleeping), VmmemWSL eats 100% CPU, there is no way to shutdown, terminate or restart. I also do not see any memory leaks (memory usage is reasonable).
"Working" was said a bit too soon. It was running, but it was slow! A restart has fixed that again, but I do wonder if something is slowing things down with hibernate and then by the time it comes back (if overnight for example), it has slowed down to basically nothing at all...
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 observe exaclty the same thing. After I turned on logging, wsl doesn't hang...
Having the same issue. It must have started probably after a Windows Update around 2-3 weeks ago as it worked before.
As expected, WSL had frozen on return from hibernate this morning. I have attached the logs gathered during this time, started just before I entered hibernate, and stopped after returning; I did also try to start a WSL terminal just before stopping to ensure it was frozen. Eclipse was also open during this time but non-responsive on return (I could see the window and contents, but couldn't do anything with them).
The logs are attached below: WslLogs-2022-09-12_16-38-51.zip