|
From: | Martin Pala |
Subject: | Re: loadavg and memusage display during init |
Date: | Sat, 11 Sep 2004 20:05:48 +0200 |
User-agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.2) Gecko/20040820 Debian/1.7.2-4 |
My first though was the same, however i changed my mind :) Monit on linux displays used memory without buffer cache, the formula is: "memory_used = MemTotal - MemFree - Buffers - Cached"The reason is, that the system will use usualy as much free memory as possible for buffers/cache. This will lead to almost 100% memory usage each time, even though applications in reality need just subset of this amount.
In this context it is not so important to know how large the buffers/cache is, but rather the hit ratio of the cache. When the hit ratio is low (for example <90%), it could be usefull to add additional memory.
Similarly, when you know some absolute value which you preffer for buffers/cache, it should be sufficient to watch just real memory usage as monit does already (the rest is available for cache, i.e. high memory usage means low space for buffer cache).
We plann to add cache hit ratio monitoring support, but it has low priority currently on our todo list. Btw. the code will be highly system dependent (there are several types of caches and interfaces).
However, when there will be good reason, i think it shouldn't be problem to add buffers/cache real size monitoring - let's discusse :)
Martin John Barton wrote: ...
A question though: monit reports on my system that I am using about 55M of RAM. 'free' reports I am using about 71M. It seems that monit is displaying memory used after subtracting the memory used for cache, so it is not displaying the amount truly in use at the time. I personally would rather see the buffer included in the used memory, for a more accurate picture of how much free memory I have. You thoughts? Thanks, -John
[Prev in Thread] | Current Thread | [Next in Thread] |