3 # Script to summarize ipeerstats, loopstats and clockstats files
5 # This script can be run from a cron job once per day, week or month. It
6 # runs the file-specific summary script and appends the summary data to
20 # Summarize loopstats files
22 for f
in loopstats.
[12][0-9][0-9][0-9][0-1][0-9][0-3][0-9]; do
23 d
=`echo $f | cut -f2 -d.`
24 if [ -f $f ] && [ $DATE != $d ]; then
27 awk -f loop.
awk $f >>$LOOP
29 echo "file1<-"\"${f}\" >>$SIN
30 echo "source("\""loop.S"\"")" >>$SIN
31 echo "unix("\""rm ${f}"\"")" >>$SIN
39 # Summarize peerstats files
41 for f
in peerstats
.199[4-9][0-1][0-9][0-3][0-9]; do
42 d
=`echo $f | cut -f2 -d.`
43 if [ -f $f ] && [ $DATE != $d ]; then
46 awk -f peer.
awk $f >>$PEER
52 # Summarize clockstats files
54 for f
in clockstats
.199[4-9][0-1][0-9][0-3][0-9]; do
55 d
=`echo $f | cut -f2 -d.`
56 if [ -f $f ] && [ $DATE != $d ]; then
59 awk -f clock.
awk $f >>$CLOCK
60 if [ -f /dev
/gps
[0-9] ]; then
61 awk -f itf.
awk $f >itf.
$d
62 awk -f etf.
awk $f >etf.
$d
63 awk -f ensemble.
awk $f >ensemble.
$d
64 awk -f tdata.
awk $f >tdata.
$d
71 # Process clockstat files with S and generate PostScript plots
73 for f
in itf etf ensemble tdata
; do
74 for d
in ${f}.199[4-9][0-1][0-9][0-3][0-9]; do
77 echo "file1<-"\"${d}\" >>$SIN
78 echo "source("\"${f}.S
\"")" >>$SIN
79 echo "unix("\""rm ${d}"\"")" >>$SIN