On Fri, Dec 29, 2000 at 06:05:35PM -0800, Gabriel Rosa wrote:
> 
> hey all,
> 
> how does one control how much memory Linux caches?

Normally, you don't.

> Is it done? Is it supposed to be done? Is it beneficial to to so? :)

Linux has a unified memory pool which it attempts to put to the best use
possible.  File caching, meta data/inodes, code pages, data pages etc.

I remember building the kernel once I upgraded my ram, was kinda eerie
how little the disk was used...

> I ask because, my new 256mb machine seems to have very little free memory,
> being as how most of it is cached, and a large chunk of it is buffered.
> 
> The machine doesn't seem slow, so I'm guessing the kernel is taking care to
> dynamically structure memory usage... but... it's a little weird seeing so
> little memory free :) It makes me think I'm wasting memory.
> 
> Here is what it looks like:
> 
> Mem:   255544K av,  250936K used,    4608K free,       0K shrd,    4444K buff
> Swap:  104384K av,       0K used,  104384K free                  210676K cached
> 
> I'm running 2.4-test12, in case it differs from the 2.2 series.

If you ram a 200 MB application I'd expect the cache to shrink...

> 
> thx
> -Gabriel
> 

Reply via email to