dockerwindows-10hyper-v

Windows 10 consumes all free memory if hyper-v is On


Windows 10 is consuming all free memory when docker desktop is installed and hyper-v is on. I don't have any container running right now but memory usage is around 99%. I have 24GB of RAM on the system.

If I reboot the system, memory usage eventually gets to 99% after sometime (no containers are running).

If I disable Hyper-V then the memory usage always below 50%. But I need it enabled so I can use Docker desktop.

Is there anything that can be done to reduce the memory usage when docker desktop isn't running? I've already tried .wslconfig and wsl --shutdown but still memory usages is 99%.

Task Manager:

The process tab doesn't show anything that's consuming memory.

enter image description here

RamMap:

enter image description here


Solution

  • Docker is the culprit (even if no containers are running). Quitting docker releases memory. After quitting docker memory usage went from 90% to 35%.

    Docker memory usage isn't shown correctly in task manager. It shows that it's consuming 3GB but its consuming 99% of memory. Quitting docker is when all memory gets released.

    Update: It's a bug with docker version 4.11.0 and 4.11.1. Upgrading to latest version resolved the issue.