SAR(1) | User Commands | SAR(1) |
sar - system activity reporter
sar [-aAbcdgkmpqruvwy] [-o filename] t [n]
sar [-aAbcdgkmpqruvwy] [-e time] [-f filename] [-i sec]
[-s time]
In the first instance, the sar utility samples cumulative activity counters in the operating system at n intervals of t seconds, where t should be 5 or greater. If t is specified with more than one option, all headers are printed together and the output can be difficult to read. (If the sampling interval is less than 5, the activity of sar itself can affect the sample.) If the -o option is specified, it saves the samples in filename in binary format. The default value of n is 1.
In the second instance, no sampling interval is specified. sar extracts data from a previously recorded filename, either the one specified by the -f option or, by default, the standard system activity daily data file /var/adm/sa/sadd for the current day dd. The starting and ending times of the report can be bounded using the -e and -s arguments with time specified in the form hh[:mm[:ss]]. The -i option selects records at sec second intervals. Otherwise, all intervals found in the data file are reported.
The following options modify the subsets of information reported by sar.
-a
-A
-b
bread/s, bwrit/s
lread/s, lwrit/s
%rcache, %wcache
pread/s, pwrit/s
If run in a non-global zone and the pools facility is active, these values reflect activity on the processors of the processor set of the pool to which the zone is bound.
-c
scall/s
sread/s, swrit/s, fork/s, exec/s
rchar/s, wchar/s
If run in a non-global zone and the pools facility is active, these values reflect activity on the processors of the processor set of the pool to which the zone is bound.
-d
%busy, avque
read/s, write/s, blks/s
avwait
avserv
For more general system statistics, use iostat(8), sar(8), or vmstat(8).
See System Administration Guide: Advanced Administration for naming conventions for disks.
-e time
-f filename
-g
pgout/s
ppgout/s
pgfree/s
pgscan/s
%ufs_ipf
If run in a non-global zone and the pools facility is active, these values reflect activity on the processors of the processor set of the pool to which the zone is bound.
-i sec
-k
sml_mem, alloc, fail
lg_mem, alloc, fail
ovsz_alloc, fail
-m
msg/s, sema/s
If run in a non-global zone and the pools facility is active, these values reflect activity on the processors of the processor set of the pool to which the zone is bound.
-o filename
-p
atch/s
pgin/s
ppgin/s
pflt/s
vflt/s
slock/s
If run in a non-global zone and the pools facility is active, these values reflect activity on the processors of the processor set of the pool to which the zone is bound.
-q
runq-sz, %runocc
swpq-sz, %swpocc
-r
freemem
freeswap
-s time
-u
%usr, %sys, %wio, %idle
If run in a non-global zone and the pools facility is active, these values reflect activity on the processors of the processor set of the pool to which the zone is bound.
-v
proc-sz, inod-sz, file-sz, lock-sz
ov
-w
swpin/s, swpot/s, bswin/s, bswot/s
pswch/s
If run in a non-global zone and the pools facility is active, these values reflect activity on the processors of the processor set of the pool to which the zone is bound.
-y
rawch/s, canch/s, outch/s
rcvin/s, xmtin/s, mdmin/s
If run in a non-global zone and the pools facility is active, these values reflect activity on the processors of the processor set of the pool to which the zone is bound.
Example 1 Viewing System Activity
The following example displays today's CPU activity so far:
example% sar
Example 2 Watching System Activity Evolve
To watch CPU activity evolve for 10 minutes and save data:
example% sar -o temp 60 10
Example 3 Reviewing Disk and Tape Activity
To later review disk and tape activity from that period:
example% sar -d -f temp
/var/adm/sa/sadd
exec(2), fork(2), attributes(7), iostat(8), sar(8), vmstat(8)
System Administration Guide: Advanced Administration
The sum of CPU utilization might vary slightly from 100 because of rounding errors in the production of a percentage figure.
May 13, 2017 | OmniOS |