Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

VMSTAT(8)  —  MAINTENANCE COMMANDS

NAME

vmstat − report virtual memory statistics

SYNOPSIS

vmstat [ −fsS ] [ interval [ count ] ]

DESCRIPTION

Vmstat delves into the system and normally reports certain statistics kept about process, virtual memory, disk, trap and cpu activity. 

Without options, vmstat displays a one-line summary of the virtual memory activity since the system has been booted.  If interval is specified, vmstat summarizes activity over the last interval seconds.  If a count is given, the statistics are repeated count times. 

For example, the following command displays a summary of what the system is doing every five seconds.  This is a good choice of printing interval since this is how often some of the statistics are sampled in the system. 

hal% vmstat 5
procs     memory                       page      disk      faults        cpu
r b w   avm  fre  re at  pi  po  fr  de  sr x0 x1 x2 x3  in   sy  cs  us  sy  id
2 0 0   918  286   0  0   0   0   0   0    0  1  0   0   0    4  12    5   3   5  91
1 0 0   846  254   0  0   0   0   0   0    0  6  0   1   0   42 153  31  7  40  54
1 0 0   840  268   0  0   0   0   0   0    0  5  0   0   0   27 103  25  8  26  66
1 0 0   620  312   0  0   0   0   0   0    0  6  0   0   0   26  76  25  6  27  67
^C
hal%

The fields of vmstat’s display are:

procsReports the number of processes in each of the three following states:

rin run queue

bblocked for resources (i/o, paging, etc.) 

wrunnable or short sleeper (< 20 secs) but swapped

memoryReports on usage of virtual and real memory.  Virtual memory is considered active if it belongs to processes which are running or have run in the last 20 seconds. 

avmnumber of active virtual Kbytes

fresize of the free list in Kbytes

pageReports information about page faults and paging activity.  The information on each of the following activities is averaged each five seconds, and given in units per second. 

repage reclaims — but see the −S option for how this field is modified. 

atnumber of attaches — but see the −S option for how this field is modified. 

pipages paged in

popages paged out

frpages freed per second

deanticipated short term memory shortfall

srpages scanned by clock algorithm, per-second

diskReports number of disk operations per second (this field is system dependent).  For Sun systems, four slots are available for up to four drives: “x0” (or “s0” for SCSI disks), “x1”, “x2”, and “x3”. 

faultsReports trap/interrupt rate averages per second over last 5 seconds. 

in(non clock) device interrupts per second

sysystem calls per second

cscpu context switch rate (switches/sec)

cpuGives a breakdown of percentage usage of CPU time. 

ususer time for normal and low priority processes

sysystem time

idcpu idle

OPTIONS

−f Report on the number of forks and vforks since system startup and the number of pages of virtual memory involved in each kind of fork. 

−s Display the contents of the sum structure, giving the total number of several kinds of paging-related events which have occurred since boot. 

−S Report on swapping rather than paging activity.  This option will change two fields in vmstat’s “paging” display:  rather than the “re” and “at” fields, vmstat will report “si” (swap-ins), and “so” (swap-outs). 

FILES

/dev/kmem
/vmunix

Sun Release 3.2  —  Last change: 23 October 1984

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026