* Monitoring FileSystem cache
@ 2003-08-06 13:32 wb
2003-08-07 15:34 ` Bryan Henderson
0 siblings, 1 reply; 2+ messages in thread
From: wb @ 2003-08-06 13:32 UTC (permalink / raw)
To: linux-scsi
Hi,
Are there tools available to monitor
the size of the filesystem buffer/cache ?
Are there hi water marks that limit the
size of the buffer cache or does it consume
as such memory VM as possible ?
I looked through /proc ( 2.4.20 kernel )
and I don't see anything of interest.
Curious.
Thanks.
J. Donnelly.
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Monitoring FileSystem cache
2003-08-06 13:32 Monitoring FileSystem cache wb
@ 2003-08-07 15:34 ` Bryan Henderson
0 siblings, 0 replies; 2+ messages in thread
From: Bryan Henderson @ 2003-08-07 15:34 UTC (permalink / raw)
To: linux-scsi
>Are there hi water marks that limit the
>size of the buffer cache or does it consume
>as such memory VM as possible ?
>
>I looked through /proc ( 2.4.20 kernel )
>and I don't see anything of interest.
How about /proc/meminfo?
The buffer cache does not consume as much memory as possible; its size is
controlled by a complex policy which is controlled by 9 sysctl variables,
which you can find in /proc/sys/vm/bdflush. The policy is implemented in
fs/buffer.c. That's the only documentation I know of for those sysctl
parameters.
The buffer cache will consume all available memory if there is no other
demand for that memory, and this frequently causes people to suspect buffer
cache overuse is causing a memory shortage problem. In reality, you rarely
have to "turn down" the buffer cache memory usage; it goes down at the
right times automatically.
By the way, it's worth mentioning that "the buffer cache" and "filesystem
caches" is not the same thing. An individual filesystem driver can cache
file data any way it wants. Conventionally, it uses the buffer cache
(every popular filesystem driver I know of does), but it could do other
things, including using the page cache directly. The page cache itself has
no sophisticated allocation strategy like the buffer cache. It competes
equally with virtual memory and every other use of memory for the finite
real memory.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-08-07 15:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-08-06 13:32 Monitoring FileSystem cache wb
2003-08-07 15:34 ` Bryan Henderson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox