Reese Knowledgebase

Clear Memory Cache on Linux Server

View Kristian Reese's profile on LinkedIn


If you like this article, please +1 or Recommend via FB with the provided buttons above:

Article ID: 73
by: Reese K.
Posted: 31 Oct, 2012
Last updated: 31 Oct, 2012
Views: 2239

Our Virtuozzo VPS hwnodes would hang onto large amounts of cached memory after a period of uptime and as it grew, load average of the hwnode would correspondingly increase during activities such as container restarts, create, stop, or start.  After troubleshooting and applying virtuozzo tool and kernel updates, the problem persisted (though not as bad).  What I've noticed however, is that load average spikes were not occuring after a fresh reboot, where free -m showed a lot of free RAM as opposed to cached RAM.  After a couple of days of uptime, there was only a couple gig of free RAM and 58GB + of cached RAM (we run 150 containers per hwnode).  These conditions do not appear favorable and the system starves for resources during container restarts, etc.  Noticablely, CPU sy would skyrocket from vztop output.  After clearing cache mem via:

 sync; echo 3 > /proc/sys/vm/drop_caches

load average spikes during a container restart have stopped.

This article was:   Helpful | Not Helpful
Also listed in
folder VPS

Prev   Next
Netmasks Table     How to find dead links and delete them

RSS