-
Notifications
You must be signed in to change notification settings - Fork 820
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
All WSL commands hang (including wsl --shutdown) but WSL is constantly using 30-40% CPU #8529
Comments
I have this issue as well. Killing the WSL process from taskmanager recovers, but it does it again. Especially (but not only) after it comes back from sleep. |
Looks like something is wrong with your trace, could you please collect a trace using these instructions? |
Hello! Could you please provide more logs to help us better diagnose your issue? To collect WSL logs, download and execute collect-wsl-logs.ps1 in an administrative powershell prompt:
The scipt will output the path of the log file once done. Once completed please upload the output files to this Github issue. Click here for more info on logging Thank you! |
Could you also share the output of Thanks! |
This issue has been automatically closed since it has not had any author activity for the past 7 days. If you're still experiencing this issue please re-open it. Thank you! |
I'm not the original poster, but I'm having a similar issue: every
I attached the logs from collect-wsl-logs.ps1: |
Same problem here. Killing WSL from Task Manager solves the issue but is obviously not ideal. |
Same here; this just started happening in the last few days; Please re-open this MSFT! |
Same here. Need to terminate the process from task manager. This issue started after updated WSL to the Store version. |
Please reopen, this issue should not have been closed. This happens all the time, usually after waking the computer from sleep. Usually a simple This problem is really frustrating as it forces me to restart Docker and all containers, as well as my IDE, which with large projects can take some time. |
I was literally about to comment the same thing! This issues has been driving me CRAZY!!! My wsl version is:
Please can we reopen and address this? |
What's worse, if this happens and I forget to close my IDE before terminating WSL, when I reopen the project everything needs to be reindexed. While the entire restart process takes seconds to do and I could live with this inconvenience, indexing can take minutes, which is not inconvenient - it's infuriating. It is simply unacceptable that this issue persists and I'm absolutely blown away that this seems to be ignored on purpose. |
Same issue here. After coming back from sleep Vmmem brings CPU usage to 100% |
Same here @ddonov, when docker desktop is running and notebook awakes from sleep. My workaround is to kill the wslservice.exe in a admin powershell: |
ERROR: The process "wslservice.exe" not found |
This worked for me. Thanks a lot! Previously I would do a hard reset. |
did you start powershell as admin? |
yes |
This workaround doesn't work for me either but |
This is some kind of joke, right? |
Facing same issues, Couldn't end process (vmmem) from task manager, it says access denied, also powershell command to taskkill also says process not found. |
+1 this issue occurs for me on a new SP9 SQ3 on 22H2 22621.755 in debian bullseye on WSL2 with the systemctl flag enabled in wslconfig. WSL hangs when I stop a docker container. I then need to restart wsl but wsl --shutdown hangs. only rebooting or taskkill /f /im wslservice.exe seems to fix it. Issue should not be closed @craigloewen-msft hello friend can you help us? If there's anything I can do to share more info on how to reproduce please let me know. Thanks and big shoutout to you folks working on WSL, it TOTALLY ROCKS <3 |
To all those affected here, as this is already closed. I can't reproduce on my work laptop, but can reproduce on both my weak, 'personal' laptops. Work machine has 64GB Ram and personal laptops have 16GB (Yeah, I know). Worse when multiple instances of vscode are running under WSL. If everyone here has low-ish memory, this could be the culprit. |
Hi folks, reopening this so it can be visible to the WSL team. It was closed automatically since we didn't get any feedback from the original author. Thanks for flagging us on it! |
PLEASE FIX WHATEVER IS CAUSING THIS!!! There are literally DOZENS of threads online about this issue, including several on this GitHub repo! All was good in Win10, now WSL goes zombie after a sleep/hybernate and it is not even clear how to bring it back without rebooting the WHOLE SYSTEM. |
ceciogit dixit:
please try insert this into `/etc/wsl.conf` and let us know if im on the right way..
… and none of my two distros even have this file.
|
If it is the same problem as in the issues #8696 and #6982 then I would like to shed some light - it is being collectively solved in this thread and talked with Microsoft already. Meanwhile, you can make a test using custom WSL kernel to check if that solves this issue for you (and, of course, report to that thread also). P.S. this issue is since late 2019 :) |
Actually not related.. ive retried without SystemD on Boot - Same Issue ,also tried with last Kernel as suggested by @onereal7 , and .. no. i give up on this. VmWare and LetsGo.. |
Just a heads up - there's another similar but unrelated (I assume) bug for WSL on ARM that seems to have been fixed in the latest pre-release of Windows 11 (24H2). It seems as though some work has been done on WSL for this release. It may be worth trying out 24H2 to see if this issue is resolved too. |
pre-release 2.3.11 released yesterday. |
I suspect in my case it is being cause by the Sophos security software. Normally vmmem would not hang, but when it does, I see a constant sophos security scan taking place. I also had to kill it using: taskkill /f /im wslservice.exe |
I ended up finding my way to this issue, because I've just encountered this same problem years later. I recently reinstalled Windows 10 after upgrading my system from an I9-9900k with 32GB RAM to a R9 7950x3d, with 128GB RAM. So no, unfortunately I don't think it has to do with RAM capacity. Prior to upgrading I'd never noticed this issue. But today I noticed that after waking up from hibernation vmmem was using about 50% of my CPU, and all wsl commands hung indefinitely. Killing the process hung my whole computer and I had to hit the reset button. I'm amazed, and also not surprised at the same time that this issue is still a problem years later. Hopefully this doesn't become a regular occurrence, I just spent a lot of time getting my Windows installation set up the way I like it, and I really don't want to have to immediately tackle the project of setting up Debian with KVM to run my Windows install after days of setup work. Though with the whole forced Win11 update looming, I guess that's inevitable anyways... Edit: I didn't see the custom kernel or the update before posting, I'll try updating WSL and see what happens. |
Whether it's a RAM issue or not I cannot say, however, I can say, that in this regard, it definitely does not matter how much RAM your machine has, what matters is how much of that RAM you assign to the WSL-virtual machine |
Do you need to collect some diagnostic info? It happens pretty often to me (i.e. right now) so I can try to collect it (given instructions)
Ubuntu 24.04 LTS in WSL2. |
baterja dixit:
It might be important: I hibernate my laptop and rarely restart.
Nah, happens to me on a device that’s always running (though a
laptop, it’s placed in a switch room at the office, I only use
it remotely).
|
I want to use remote ssh service ,so I modified .wslconfig, and all wsl commands hang as described.
I think |
This process is eating up 16GB of memory without anyway of killing it, just awesome! |
I can't believe this issue is still opening after 3 years. |
Has anyone who's experienced this issue upgraded to 24H2 and then still experienced it? Other very similar bugs with the WSL have been fixed on ARM using 24H2. But before I ever get an x64 machine with Windows I'd love to hear if it's also been fixed on that platform. |
WSLg apps will randomly freeze, and CANNOT be killed. When this happens It's insanely frustrating, and wastes so much time every week. |
The taskkill command from further up in the thread has saved me all my restarts. When wsl freezes, I run that command, and open wsl again. No more reboots necessary. |
@benhillis Can you maybe assign someone else to this task if you aren't working on it? And have you escalated it to someone like a manager yet, or are there any experts who understand the problem? Same for related issues like |
updated to latest wsl prerelease. issue seems to be gone now. |
I said that too early, issue still present. |
I am having a freeze in Powershell after running wsl --shutdown command. |
Same problem here. |
I have been using the custom kernel that was mentioned by onereal7, following these instructions. So far, after a month with the new kernel, I have not had another hang like the ones that previously plagued me every few days. I don't know if it really has fixed the issue, but it is very promising. I'm using Windows 10 22H2, WSL 2.2.4.0, with CentOS7 and Alma9 distros. |
|
I just posted this on a similar issue; hope it helps others.
|
So if I understand right, if you use this feature on MS's multiuser operating system, then the only solution that avoids restarting the whole OS is to be an administrator on that multiuser operating system. |
I have the same problem, WSL2 freeze! And |
Same issue here 😞 |
Does the command |
Version
Microsoft Windows [Version 10.0.22621.160]
WSL Version
Kernel Version
5.10.102.1
Distro Version
Ubuntu 20.04
Other Software
No response
Repro Steps
This mostly seems to be happening when the device wakes from sleep - after a system restart, I can access the WSL distro as expected
wsl --shutdown
Expected Behavior
Actual Behavior
Diagnostic Logs
Feedback Hub logs: https://aka.ms/AAh9fcl
The text was updated successfully, but these errors were encountered: