It's just pure lack of memory. Perhaps a memory leak, or simply overload of your VPS of what it can handle.
Clearing swap isn't going to help you if it's an overload. Because it will happen again very soon. To clear, restart VPS.
I m having High swap used in the server. Actually the one where i m having high swap used is a vps. How can i clear the swap files in CentOS 4.2?
Thanks.
Regards





It's just pure lack of memory. Perhaps a memory leak, or simply overload of your VPS of what it can handle.
Clearing swap isn't going to help you if it's an overload. Because it will happen again very soon. To clear, restart VPS.
I am cooking up some projects...
How much RAM do you have and what do you run on it? ouput of 'top -c' and 'ps waux' is usually a good start.
Actually my vps is not having high load. About 1 - 2 server load. Ram usage is about 60% but swap usage is raising day by day. Now it is 86%Originally Posted by James
And thanks for that suggestion. When i restart my vps it reduce the swap usage, but within 6-8 hours it get again high swap usage. Is that mean i need memory upgrade?
Regards





Yes, or take the memory hogging account/s off the server.Originally Posted by talence
I am cooking up some projects...
I m confused now. I contacted with my DC and they cleared my swap memory. Now it is 47%, i didn't upgrade memory even.Originally Posted by NetCafe
Note: I m housed with SAVVIS.
I m just curious to know how this can be done.
Regards
Swap is your hdd space and nothing to do with physical ram being "reboot" or what nots.
When your ram is used up, the system begings to use swap, like virtual memory in windows?





Again, clearing swap only temporarily fixed the problem, when the processes come back you'll face the same situation again. Only a matter of time.
Ram 60 percent / Swap 50 percent is still too high to my taste.
I am cooking up some projects...
Originally Posted by James
Correct. Same thing, and it is certainly ease to know that we dont add virtual memories like RAM Lol. But actually Swap Memory depends on the swap files reduction of coursely. (Same like Windows) Again, currently running process make the swap memory load. So its quite like if you get low swap memory used, but high physical memory used, no matter, your server will not be hung easily. But high swap makes problem.the system begings to use swap, like virtual memory in windows?
Its still not high. As if you use 95% of your RAM and getting 50% swap your server will not hang, some process might get stopped because of lack memory. But if you get high swap like 80-90% then it is risky of course.Ram 60 percent / Swap 50 percent is still too high to my taste.
Swap files depend on the cache system of your server softwares and the sites you are using. Usually blogs, forums, CMS lots people use caches. Like Vb uses more cache then IPB and PHPBB. On Blog Wordpress uses high. All this cache when get saved then load the swap. And its a big process depends on your HDD space as Netcafe said. If you are having 40% swap and getting swap cleared, then you certainly for about 25-30 days will be free may be your server having Vb or Wordpress hosted.Again, clearing swap only temporarily fixed the problem, when the processes come back you'll face the same situation again. Only a matter of time.
Regards
Bookmarks