Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

i cannot get the sar reading for 00:00:00

Status
Not open for further replies.

lnbnatera

Technical User
Feb 14, 2006
54
0
0
HK
hi,

i was wondering why i cannot get the 00:00:00 reading from the sar output. here is a sample of what i get:

00:00:00 %usr %sys %wio %idle
01:00:00 0 0 0 100
02:00:00 0 0 0 100
03:00:00 0 0 0 100
04:00:00 0 0 0 100
05:00:00 0 0 0 100
06:00:00 0 0 0 100
07:00:00 0 0 0 100
08:00:00 0 0 0 100
08:20:00 0 0 0 100
08:40:00 6 1 0 93
09:00:00 1 0 0 99
09:20:00 0 0 0 100
09:40:00 0 0 0 100
10:00:00 0 0 0 100
10:20:00 0 0 0 100

Average 0 0 0 100

the sar syntax that i used is sar -s 00:00:00 -e 12:00:00 -f sa04.

the content of the sys crontab is:
#ident "@(#)sys 1.5 92/07/14 SMI" /* SVr4.0 1.2 */
#
# The sys crontab should be used to do performance collection. See cron
# and performance manual pages for details on startup.
#
0 * * * 0-6 /usr/lib/sa/sa1
20,40 8-17 * * 1-5 /usr/lib/sa/sa1

all i get from these settings is from 01:00:00 up to 23:00:00. i dont have a 00:00:00 reading.

is it possible to get a 00:00:00 reading from sar?

thanks
 
From the man page:

-s time
Select data later than time in the form hh[:mm].
Default is 08:00.

So perhaps set your time earlier (possibly 23:59?)?
 
It's meant to be like that. The first line is used to calculate the second. Since no data is available before 00:00:00 no figures can be displayed. It works the same on AIX / Tru64 / Solaris

Mike

"A foolproof method for sculpting an elephant: first, get a huge block of marble, then you chip away everything that doesn't look like an elephant."

 
so how can i get a 00:00:00 reading besides offsetting it?
 
As mrn said, there is no such reading. Each reading is the average from the previous 10 minutes. There is no 10 minutes between 00:00:00 and 00:00:00.

Unfortunately no data seems to be recorded in between the end of the previous day and the start of the next. The only think I can suggest is increasing the frequency of the sar data collection by modifying the crontab for the "sys" user. This means that you will miss a smaller amount of data.

For example, this will capture data every 5 minutes:

[tt]0 0-23 * * * /usr/lib/sa/sa1 300 12[/tt]

Annihilannic.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top