DesktopECHO / Pi-Hole-for-WSL1

Ad-blocking DNS server for Windows • Unbound pre-configured • Deployment ready in minutes • Does not require hypervisor/docker
349 stars 53 forks source link

Memory usage high (vs. Docker) #78

Closed matthew-dean closed 1 year ago

matthew-dean commented 1 year ago

Hi, I'm installing using this script on a Windows 11 mini-PC. Previously, when I set up using the official Docker image, it said that memory usage was ~35%. (I believe it was Docker on WSL2 using Alpine Linux.)

After I've installed using this script, it says memory usage is ~83% in the Admin UI. Should I be concerned with that high number and is there any reason for it?

DesktopECHO commented 1 year ago

Hi, actually Pi-hole, when running in WSL1 uses way, way less CPU and RAM than Docker.

Pi-hole "memory usage" in WSL1 will show the memory use of your native Windows session, there's no separate Linux VM. In Docker/WSL2 it's reporting free memory of whatever RAM was assigned to the virtual machine running Linux. Check Task Manager for memory usage when running in Docker, then check again running in WSL1.

You can verify for yourself (or you'll find a rogue process taking up loads of RAM, lol) Open task manager and sort by "Image Path Name"

Pi-hole -related processes take about 10 megabytes of RAM; surprisingly tiny.
image

matthew-dean commented 1 year ago

hmm ok