How can I calculate exact memory used on AIX system?

I already checked memory on AIX with "svmon -G" and vmstat (as the figure). I see the value "inuse" nearly=97% use memory, free=3%. However, the value "pin=cache" nearly=26%.

Can I calculate total free memory= free+ pin = 29% ?
please help me!
Thanks so much!

What is "in use" on a AIX system depends on your definition of "in use". We have had this discussion quite a few times here, just have a search in this board with the keywords "memory used vmstat" and you will find a lot of threads.

The AIX kernel tries to make use of as much memory as is possible. If the memory is not used for programs it will automatically be used for I/O caching, network buffers, etc.. Once it *is* needed these buffers will be decreased in size again. This is steered via several options in the kernel tunables, namely the ones controlled by vmo .

Depending on your AIX version issue vmo -a with or without the "-F" option. Take a look at "maxperm%" and "minperm%". I bet maxperm% is set to 97 as you say 3% of the memory is free.

What exactly is your problem or what are you trying to achieve?

bakunin

PS: I'd be more concerned with the 6 processes in the blocked-queue (in the last line of vmstat output), as this means there are processes, which could run save for having to wait for some I/O.

I have read on the website "UNIX Health Check - AIX memory consumption".
So I want to know how this calculation right?

Thanks a lot!

from the Sample attached you are using computational (for real work) approx 29 GB of your memory - you have about 44 GB. Anything above the computational memory up to 97% may be needed for caching and buffering.
I am with Bakunin, you might have an IO issue as your number of blocked IOs is pretty high. Maybe you do not have enough filesystem buffers, maybe your runqueues on the disks are too low.
Regards
zxmaus

Thanks for yours help!

I just checked the system with "iostat" command .
I saw several hard drives have "% tm_act" approx 98%.
The system was I/O bound.

Regards
thanhcx!

To answer your question: yes, the calculation is correct: "virtual" is the memory really needed by programs (on a long-term basis) and "size" is the memory installed (all these numbers in memory pages - a page is usually 4k in AIX). As long as the "virtual number" is lower than the "size" number (minus some slack - the author says 10%, which is a good rule-of-thumb value) everything is fine, otherwise the system is memory-bound in most cases.

I hope this helps.

bakunin

1 Like