- The memory utilization on the jenkins controller is close to the limit
- Why is all the memory on my Jenkins server used?
- free -m shows all the memory on my linux server as used
- CloudBees Jenkins Enterprise
# free -m total used free shared buffers cached Mem: 8178088 8041548 136540 0 0 3802444 -/+ buffers/cache: 4239104 3938984
In order to find the real memory consumption you should look in the
-/+ buffers/cache: used and free columns instead. In the above example the actual memory used is 4.23GB, while 3.93GB is free memory.
The Mem used column displays the sum of
-/+ buffers/cache: used + disk cache(
cached column at end). The disk cache is a method used in *nix operating systems to prevent disk I/O and stores it in memory. This is used to cache things like jars, log files, text files, etc.
If you would like to clean up the disk cache you can run the command:
echo 3 | sudo tee /proc/sys/vm/drop_caches to see the Mem used and free column change (but this is not required since the OS will do this over time for you).
Please check with your OS provider for other methods to more aggressively flush cache.