WSL: WSL2 causing high CPU load

Version

Microsoft Windows [Version 10.0.22000.376]

WSL Version

  • WSL 2
  • WSL 1

Kernel Version

5.10.60.1

Distro Version

Ubuntu 18.04

Other Software

No response

Repro Steps

Unsure. Here it’s enough to simply have a wsl2 shell open. Funny enough, it’s gone for now.

Expected Behavior

Taskmanager showing Vmmem with little to no cpu usage in idle, while a wsl2 shell is open.

Actual Behavior

Taskmanager show(ed) Vmmem with 5-6% constant cpu usage (on a CPU with 32 Threads), high energy consumption and makes the task manager flicker every second.

Processes inside the WSL guest are idling:

USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root         1  0.0  0.0   1744  1080 ?        Sl   23:17   0:00 /init
root         7  0.0  0.0   1752    68 ?        Ss   23:17   0:00 /init
root         8  0.0  0.0   1752    76 ?        S    23:17   0:00  \_ /init
max06        9  0.0  0.0  22988  5000 pts/0    Ss   23:17   0:00      \_ -bash
max06       98  0.0  0.0  37804  3332 pts/0    R+   23:22   0:00          \_ ps xuaf

Closing the shell (and waiting some seconds) fixes the issue, as well as terminating the guest or the virtual machine.

Diagnostic Logs

I currently hope for someone coming along with “we know that already” and “it’s gonna be fixt next update”. Otherwise I’m happy to provide whatever you ask for.

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 5
  • Comments: 17

Most upvoted comments

Thanks for reporting this @max06.

I wonder if this could be caused by wslg.

Can you try to add:

[wsl2]
guiApplications=false

To %userprofile%.wslconfig , then run wsl --shutdown, and start wsl again to see if the issue is still there ? Also, what’s the output of dmesg ?

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!