Linux sag command
Updated: 04/26/2017 by Computer Hope
sag [-e time] [-f file] [-i sec] [-s time] [-T term] [-x spec] [-y spec]
|-e time||Select data up to time. Default is 18:00.|
|-f file||Use file as the data source for sar. Default is the current daily data file /usr/adm/sa/sadd.|
|-i sec||Select data at intervals as close as possible to sec seconds.|
|-s time||Select data later than time in the form hh[:mm]. Default is 08:00.|
|-T term||Produce output suitable for terminal term. See tplot for known terminals. Default for term is the value of the environment variable $TERM.|
|-x spec||x axis specification with spec in the form:
name[op name]...[lo hi]name is either a string that will match a column header in the sar report, with an optional device name in square brackets, for example, r+w/s[dsk-1], or an integer value. op is +, -, *, or /, surrounded by blank spaces. Up to five names may be specified. Parentheses are not recognized. Contrary to custom, + and - have precedence over * and /. Evaluation is left to right. Thus, A/A+B*100 is evaluated as (A/(A+B))*100, and A+B/C+D is (A+B)/(C+D). lo and hi are optional numeric scale limits. If unspecified, they are deduced from the data.
Enclose spec in double-quotes ("") if it includes white space.
A single spec is permitted for the x axis. If unspecified, time is used.
|-y spec||y axis specification with spec in the same form as for -x. Up to 5 spec arguments separated by a semi-colon (;) may be given for -y. The -y default is:
See today's CPU utilization.
sar -o /tmp/tempfile 60 15
sag -f /tmp/tempfile -s $TS -e $TE -y "r+w/s[dsk]"
The above four commands, when executed in sequence, will display all activity over 15 minutes of all disk drives.
sar — Display system activity information under Solaris.