SAR(1) RISC/os Reference Manual SAR(1)
NAME
sar - system activity reporter
SYNOPSIS
sar [-ubdycwaqvmprDSA] [-o file] t [ n ]
sar [-ubdycwaqvmprDSA] [-s time] [-e time] [-i sec]
[-f file]
DESCRIPTION
sar, in the first instance, samples cumulative activity
counters in the operating system at n intervals of t
seconds, where t should be 5 or greater. If the -o option
is specified, it saves the samples in file in binary format.
The default value of n is 1. In the second instance, with
no sampling interval specified, sar extracts data from a
previously recorded file, either the one specified by -f
option or, by default, the standard system activity daily
data file /usr/adm/sa/sadd for the current day dd. The
starting and ending times of the report can be bounded via
the -s and -e time arguments of the form hh[:mm[:ss]]. The
-i option selects records at sec second intervals. Other-
wise, all intervals found in the data file are reported.
In either case, subsets of data to be printed are specified
by option:
-u Report CPU utilization (the default):
%usr, %sys, %wio, %idle - portion of time running in
user mode, running in system mode, idle with some pro-
cess waiting for block I/O, and otherwise idle. When
used with -D, %sys is split into percent of time ser-
vicing requests from remote machines (%sys remote) and
all other system time (%sys local).
-b Report buffer activity:
bread/s, bwrit/s - transfers per second of data between
system buffers and disk or other block devices;
lread/s, lwrit/s - accesses of system buffers;
%rcache, %wcache - cache hit ratios, i. e.,
(1-bread/lread) as a percentage;
pread/s, pwrit/s - transfers via raw (physical) device
mechanism.
-d Report activity for each block device, e. g., disk or
tape drive. When data is displayed, the device specif-
ication dsk- is generally used to represent a disk
drive. The device specification used to represent a
tape drive is machine dependent. The activity data
reported is:
%busy, avque - portion of time device was busy servic-
ing a transfer request, average number of requests
Printed 11/19/92 Page 1
SAR(1) RISC/os Reference Manual SAR(1)
outstanding during that time;
r+w/s, blks/s - number of data transfers from or to
device, number of bytes transferred in 512-byte units;
avwait, avserv - average time in ms. that transfer
requests wait idly on queue, and average time to be
serviced (which for disks includes seek, rotational
latency and data transfer times).
-y Report TTY device activity:
rawch/s, canch/s, outch/s - input character rate, input
character rate processed by canon, output character
rate;
rcvin/s, xmtin/s, mdmin/s - receive, transmit and modem
interrupt rates.
-c Report system calls:
scall/s - system calls of all types;
sread/s, swrit/s, fork/s, exec/s - specific system
calls;
rchar/s, wchar/s - characters transferred by read and
write system calls.
When used with -D, the system calls are split into
incoming, outgoing, and strictly local calls.
-w Report system swapping and switching activity:
swpin/s, swpot/s, bswin/s, bswot/s - number of
transfers and number of 512-byte units transferred for
swapins and swapouts (including initial loading of some
programs);
pswch/s - process switches.
-a Report use of file access system routines:
iget/s, namei/s, dirblk/s.
-q Report average queue length while occupied, and % of
time occupied:
runq-sz, %runocc - run queue of processes in memory and
runnable;
swpq-sz, %swpocc - swap queue of processes swapped out
but ready to run.
-v Report status of process, i-node, file tables:
text-sz, proc-sz, inod-sz, file-sz, lock-sz -
entries/size for each table, evaluated once at sampling
point;
ov - overflows that occur between sampling points for
each table.
-m Report message and semaphore activities:
msg/s, sema/s - primitives per second.
-p Report paging activities:
Page 2 Printed 11/19/92
SAR(1) RISC/os Reference Manual SAR(1)
vflt/s - address translation page faults (valid page
not in memory);
%dmnd - % of vflts which required zeroing or filling;
%cache - % of vflts for which page is in page cache;
%swap - % of vflts for which page is on swap;
%pgfil - % of vflts for which page is in a file;
pflt/s - page faults from protection errors (illegal
access to page) or "copy-on-writes";
%cow - % of pflts which are "copy-on-write";
%steal - % of pflts for which we had to steal a page;
pgfil/s - vflt/s satisfied by page-in from file system;
rclm/s - valid pages reclaimed for free list.
-r Report unused memory pages and disk blocks:
freemem - average pages available to user processes;
freeswap - disk blocks available for process swapping.
-D Report Remote File Sharing activity:
When used in combination with -u or -c, it causes sar
to produce the remote file sharing version of the
corresponding report. -u is assumed when neither -u or
-c is specified.
-S Report server and request queue status:
Average number of Remote File Sharing servers on the
system (serv/lo-hi), % of time receive descriptors are
on the request queue (request %busy), average number of
receive descriptors waiting for service when queue is
occupied (request avg lgth), % of time there are idle
servers (server %avail), average number of idle servers
when idle ones exist (server avg avail).
-A Report all data. Equivalent to -udqbwcayvmprSD.
EXAMPLES
To see today's CPU activity so far:
sar
To watch CPU activity evolve for 10 minutes and save data:
sar -o temp 60 10
To later review disk and tape activity from that period:
sar -d -f temp
FILES
/usr/adm/sa/sadd daily data file, where dd are digits
representing the day of the month.
Printed 11/19/92 Page 3
SAR(1) RISC/os Reference Manual SAR(1)
SEE ALSO
sar(1M) in the System Administrator's Reference Manual.
Page 4 Printed 11/19/92