I cannot figure out VPS cached memory



I am constantly struggling with large amounts of cached memory on my VPS. Rebooting only helps briefly and then it tends to shoot back up to over 400 MB. That is way too much for my site still being in the developmental stage.

And it was not always this way. It use to stay below 300 when I was running both Drupal and Wikipedia. Last week, I took down the Drupal site, and it still was hitting the 512 MB edge.

Is there any way to clear the memory cache or to limit it in size? And can anyone give me good instructions to see just where the cached memory is going?

Thanks In Advance,
Cassie Ellen


Using nginx I excluded certain files (downloads) from being cached in the nginx.conf and it greatly reduced my cached memory useage. It floats between 40 and 200mb now. If you are using Apache then all bets are off. Count on a lot of memory being used.


I am running into the same issues,… also in setting up a Drupal site (GAWD what a resource hog!). One of the things I have noticed is that if I stay logged in using HeidiSQL and it goes idle (when I get called away) the cached memory skyrockets! Same was true with FileZilla.

So closing any apps linking to your server unless they are being actively used, seems to help a LOT!


I was running both mediawiki and a drupal site. Then I completely shut down the dripal site, and the memory still stayed high. Next, I shut down mediawiki and still the cached memory stayed high. The only other apps I use are ssh and some command line apps to check memory usage.

I had once watched the memory go high and it was caused by some problem with postfix. I did not have mail turned on for the server. When I did, most of the memory problems seemed to go away running just wikipedia. I have not tried to get the drupal site back up again.

What still frustrates me is that if anything drives up the cached memory, it takes 4 to 6 hours for the memory to be released. Well, short of rebooting which I do not want to get into a habit of doing.

Thanks for the response,
Cassie Ellen


This is probably not very helpful, but just to relate an odd experience I had:

Running a few WordPress sites on my VPS…had some high cache levels for several months. I tried several restarts, adjusting PHP Versions, other random things here and there…
A few weeks ago (I think it was a few weeks ago,cannot remember the exact date) Dreamhost was having some server issues. My sites were all down for several hours. When they came back up, lo and behold my cache level was way down (riding under 250mb) and since then has been staying that low.

I have no idea what occured to reset my RAM levels like that, but I hope it sticks!

My sites are all in Irvine, CA

My thought is that if you wanted to reset, you could request for your vps-server and database-server to be moved to a different data-center, which might possibly result in a kind of reset…

This is pure speculation, but if you have tried everything else then you probably don’t have anything to lose by it.


Did you finally found the answer? I got the same issue! Thanks in advance, to share if it’s work for you!