[CentOS] kbcached tuning on CentOS 4
lowen at pari.edu
Sat Sep 16 20:54:08 UTC 2006
On Monday 11 September 2006 11:30, Justin Randall wrote:
> The real concern comes from administrators or other less technical staff
> logging into the box, and getting concerned at the amount of memory used
Memory is bought to be used, not to sit idle. And memory is not 'used up'
like hard disk space is; memory in use by disk cache is instantly freeable by
the kernel, and is not 'used up' in any sense of the phrase.
> If this thought is misguided please let me know. Either way, what would
> be the correct method for tuning the kernel parameters?
Your thought is misguided. The Linux Kernel does a pretty good job of freeing
cached disk memory when processes need the memory; you don't need nor do you
want to tune it any other way.
If these admins are savvy enough to worry about memory, they are savvy enough
to be taught the difference in the types of Linux memory usage.
For instance, on my laptop right now, top tells me:
Mem: 1035160k total, 1021300k used, 13860k free, 134616k buffers
Swap: 1052216k total, 4k used, 1052212k free, 427556k cached
Ok, I have 13MB of RAM that is sitting there unused, idle, and generally not
doing something useful. I have roughly 420MB used in cache, which speeds
disk access, but that memory is instantly available if I, say, start up
OpenOffice. As long as my swap used number stays low, I'm probably OK as far
as memory goes.
Out of 1GB memory, the kernel is using roughly 99% for doing something useful.
This is a very good thing; it would be a shame to have paid for 1GB and never
use more than 512MB.
Director of Information Technology
Pisgah Astronomical Research Institute
1 PARI Drive
Rosman, NC 28772
More information about the CentOS