WSL2 regularly crashes on waking up from sleep
- Dominant language
- C++
- Stars
- 33.7k
- Forks
- 1.8k
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 116
Description
### Windows Version
Microsoft Windows [Version 10.0.26200.7623]
### WSL Version
2.6.3.0
### Are you using WSL 1 or WSL 2?
- [x] WSL 2
- [ ] WSL 1
### Kernel Version
6.6.87.2-1
### Distro Version
Ubuntu 24.04
### Other Software
Version: 1.109.2 (user setup)
Commit: 591199df409fbf59b4b52d5ad4ee0470152a9b31
Date: 2026-02-10T20:18:23.520Z
Electron: 39.3.0
ElectronBuildId: 13168319
Chromium: 142.0.7444.265
Node.js: 22.21.1
V8: 14.2.231.22-electron.0
OS: Windows_NT x64 10.0.26200
### Repro Steps
A regular regression issue, not a random crash.
Reproduces once in ~4 days.
I close the laptop at the end of the working day.
Once opening it back the next day, VSCode can't connect and asks to reload the window, which doesn't help.
On connecting to WSL through Windows Terminal, it returns Catastrophic failure Error code: Wsl/Service/E_UNEXPECTED.
wsl --shutdown is the workaround that helps.
### Expected Behavior
WSL never crashes.
This issue is really annoying, seems like there's no sense in developing under Windows - the environment is too unstable.
### Actual Behavior
VSCode can't connect and asks to reload the window, which doesn't help.
On connecting to WSL through Windows Terminal, it returns Catastrophic failure Error code: Wsl/Service/E_UNEXPECTED.
wsl --shutdown is the workaround that helps.
### Diagnostic Logs
Attached to comment: https://github.com/microsoft/WSL/issues/14193#issuecomment-4022157917
Contributor guide
Research direction
Start with the diagnostic logs attached in the linked issue comment, then reproduce the failure by waking the laptop and connecting through VS Code or Windows Terminal. Compare the failed state with the wsl --shutdown workaround; done means WSL reconnects after waking without Wsl/Service/E_UNEXPECTED.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- vscode
- Domain
- devtools, operating-systems
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100