Quote:
Originally Posted by
shockneck
define "free" ... AIX uses as much memory as it can and so there is only little "unused" memory. E.g. if there is some memory that is not used for program cache AIX uses the rest for file cache. Hence you end up with as little "free" memory as vmstat's "free" column gives. That does not necessarily imply that there is no memory left....
This is why i have offered "ps" as a means to find out how much memory is in fact used by processs. Add to this number the shared memory segments and you get a number you can compare to the "fre" column in vmstat. This is the best approximation to whatever you might define as "free". In my wording "free" means "unused" and vice versa, not "maybe freeable by arbitrarily complex procedures". The AIX kernel tries to use memory as efficient as possible and might show relatively little memory as free when it could do with significantly less memory too - that doesn't mean that the number is incorrect, but that maybe processes stay in memory which would otherwise have been swapped out or all sorts of buffers being full-length whereas they would be decreased in size in case of memory shortage.
All this is called "memory management" and is one of the main things a kernel has to do - and as efficiently as possible so. Still, despite all the clever mechanisms IBM might have built into the kernel, for less memory you pay a price and you pay it with performance: the one process might get swapped out but at some point in time you have to swap it in again and then the machine will have to wait for some time. Some buffer size might decrease, but this will - however slightly - affect the hit ratio and certainly not in a positive way.
Bottom line: regardless of how clever you define "free" at last it comes down to "sufficient or not". This is why every performance optimization projects should start with an SLA to agree upon. The user and the SysAdmin have to agree upon how fast exactly is "fast enough". Until then discussions about how free "free" means are pointless.
bakunin