1828154 Members
2789 Online
109975 Solutions
New Discussion

vmstat (al,os ......)

 
jousif
Frequent Advisor

vmstat (al,os ......)

Hi admins,
how can I undersatand what is (al , os ...)
mean from the vmstat command .
else the man vmstat,
please advise I want to know how the system memory is used,
many thanks.
4 REPLIES 4
Steven E. Protter
Exalted Contributor

Re: vmstat (al,os ......)

Shalom jousif,

vmstat measures use of virtual memory.

Virtual memory is disk that is used to swap processes from memory to disk when there is more need for memory than memory.

With memory prices low, the ideal system never actually pages to disk using vm, it reserves memory for swap but never uses it.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Stuart Browne
Honored Contributor

Re: vmstat (al,os ......)

Actually, 'vmstat' shows the current memory usage, as well as the virtual memory usage, as well as some basic disk-io, and system process stats.

Typical output of vmstat:

procs -----------memory---------- ---swap-- -----io---- --system-- ----cpu----
r b swpd free inact active si so bi bo in cs us sy id wa
1 0 604916 115680 62476 278680 6 4 2 2 1 1 24 9 62 5

of

procs -----------memory---------- ---swap-- -----io---- --system-- ----cpu----
r b swpd free buff cache si so bi bo in cs us sy id wa
1 33 624408 7508 5220 27916 6 4 2 2 1 1 24 9 62 5


(this will look screwey, damn lack of fixed-width fonts!).

These are all detailed in the man page.

I use this output with MRTG to map current memory usage.

Other ways to get the current memory usage are to use 'free', or to directly 'cat /proc/meminfo'. All of these tools look at that for their details anyway.

'free' (which is basically the same as the top section of the 'top' command) shows things the clearest.

Total memory. Free memory. Total swap. Free swap.

Be aware that the Buffers and Cache values are automatically assigned, and change regularly. If you have a system that is using lots of swap, and the Buffers and Cache values aren't that big, then definately get more memory.
One long-haired git at your service...
Muthukumar_5
Honored Contributor

Re: vmstat (al,os ......)

Use this,

http://www.tech-recipes.com/solaris_system_administration_tips165.html

to interpret output.

--
Muthu
Easy to suggest when don't know about the problem!
jousif
Frequent Advisor

Re: vmstat (al,os ......)

many thanks to browne & protter
I mean when I issue the command
% vmstat -P
the output what means ( al,os ...)
thanks.