HowTo - Decrease the memory usage of Spryker with Docker on WSL2
Edit on GitHubWhen running Spryker with Docker on WSL2, the memory usage of VMmem can get significant, even if the memory usage of the instance is small.
This HowTo explains how you can limit the memory usage of this process.
Prerequisites
Ensure that you are running the latest versions of:
- Windows 10
- Docker for Windows
Limiting the memory usage of VMmem
To limit the memory usage of VMmem:
- Create or update
c:\users\USERNAME\.wslconfig
withmemory
andprocessors
parameters per your hardware and performance requirements. The following example should suit most use cases.
memory=4GB # Sets the memory limit to 4 GB.
processors=2 # Sets the number of CPU cores WSL2 is allowed to use to 2.
-
Restart the LXSSMANAGER service:
-
In the Start menu, enter Services and press Enter.
-
Right-click the LXSSMANAGER service and select Restart.
Now the VMmem memory usage should not exceed the specified limit.
Thank you!
For submitting the form