7 ms·
Is this the reason Windows Task Manager seems to show Vmmem (WSL2) as gobbling up well more RAM then WSL seems to indicate is in use? I have more then enough R
by skazazes 3y ago
Is this the reason Windows Task Manager seems to show Vmmem (WSL2) as gobbling up well more RAM then WSL seems to indicate is in use?
I have more then enough RAM on my office workstation to just accept this, but on my personal gaming computer that moonlights as a dev machine, I run into issues and have to kill WSL from time to time.
- chabad360 3y agoNo, that's because WSL (until v2/very recently) didn't properly release memory back to windows. This actually would cause docker to effectively leak memory really quickly.
- sp332 3y agoI think there is some conflict between the disk cache running inside WSL and the memory management outside. I tried turning up memory pressure in WSL but it didn't help. This does work but I have to run it manually from time to time: # sync; echo 3 > /proc/sys/vm/drop_caches
- praash 3y agoThat's just one part of the issue - even after forcefully dropping Linux's caches, WSL has been unable to reclaim the memory back reliably. There has been a recent update that claims to finally fix this. You might find this package helpful: https://github.com/arkane-systems/wsl-drop-cache https://github.com/arkane-systems/wsl-drop-cache
- Dylan16807 3y agoIt's also really annoying that "drop caches" seems to be the only interface here. No way to simply limit it.
- deleted 3y ago[deleted]
- Zetobal 3y agoThe worst offense of wsl2 is writing files to ram before copying it to the native filesystem unusable with lots of data.