aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authormattrude <[email protected]>2012-02-25 23:44:15 -0600
committermattrude <[email protected]>2012-02-25 23:44:15 -0600
commit7a6bc450bf5169aa5ac9be408a4713723de02be4 (patch)
tree43c86f8a699a647e640306175bc714ead231d89f /scripts
parenta428216f8d8c8ec36de5623adf247b8cdb3e3635 (diff)
downloadtime.mattrude.com-7a6bc450bf5169aa5ac9be408a4713723de02be4.tar.gz
time.mattrude.com-7a6bc450bf5169aa5ac9be408a4713723de02be4.tar.bz2
time.mattrude.com-7a6bc450bf5169aa5ac9be408a4713723de02be4.zip
updating
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/do-rrd-update3
-rwxr-xr-xscripts/templates/graphs.cgi24
-rw-r--r--scripts/templates/tail2
-rw-r--r--scripts/templates/template-host2
4 files changed, 17 insertions, 14 deletions
diff --git a/scripts/do-rrd-update b/scripts/do-rrd-update
index 7279a5e..0ba2e5a 100755
--- a/scripts/do-rrd-update
+++ b/scripts/do-rrd-update
@@ -40,3 +40,6 @@ rm /tmp/ntp-rrdstats.$$
#echo "N:${NOFFSET}:${NSJIT}:${NCJIT}:${NWANDER}:${NFREQ}:${NDISPER}:${CLIENTS}:${LIMITED}:${KOD}"
echo "INSERT INTO status (date, host, offset, freq, sjit, cjit, wander, disp) VALUES ('${DATE}', '${1}', '${NOFFSET}', '${NSJIT}', '${NCJIT}', '${NWANDER}', '${NFREQ}', '${NDISPER}');" |sqlite3 ntpstatus.sqlite
+echo "select * from status WHERE host = $1 ORDER BY date DESC;" |sqlite3 -separator ',' rrd/ntpstatus.sqlite > $1.csv
+
+ssh $1 /home/matt/bin/ntp/ntp_clients_stats > ../logs/$1.log
diff --git a/scripts/templates/graphs.cgi b/scripts/templates/graphs.cgi
index 9486ba0..6af4e69 100755
--- a/scripts/templates/graphs.cgi
+++ b/scripts/templates/graphs.cgi
@@ -125,20 +125,20 @@ sub graph_clients($$) {
"DEF:limited=$rrd:limited:LAST",
"DEF:kod=$rrd:kod:LAST",
'AREA:clients#002A97FF:Clients:',
- 'GPRINT:clients:LAST:Current\:%8.2lf %s',
- 'GPRINT:clients:AVERAGE:Average\:%8.2lf %s',
- 'GPRINT:clients:MIN:Minimum\:%8.2lf %s',
- 'GPRINT:clients:MAX:Maximum\:%8.2lf %s\n',
+ 'GPRINT:clients:LAST:Current\:%8.3lf %s',
+ 'GPRINT:clients:AVERAGE:Average\:%8.3lf %s',
+ 'GPRINT:clients:MIN:Minimum\:%8.3lf %s',
+ 'GPRINT:clients:MAX:Maximum\:%8.3lf %s\n',
'AREA:limited#ffff00:Limited:',
- 'GPRINT:limited:LAST:Current\:%8.2lf %s',
- 'GPRINT:limited:AVERAGE:Average\:%8.2lf %s',
- 'GPRINT:limited:MIN:Minimum\:%8.2lf %s',
- 'GPRINT:limited:MAX:Maximum\:%8.2lf %s\n',
+ 'GPRINT:limited:LAST:Current\:%8.0lf %s',
+ 'GPRINT:limited:AVERAGE:Average\:%8.0lf %s',
+ 'GPRINT:limited:MIN:Minimum\:%8.0lf %s',
+ 'GPRINT:limited:MAX:Maximum\:%8.0lf %s\n',
'AREA:kod#F51D30FF: K O D :',
- 'GPRINT:kod:LAST:Current\:%8.2lf %s',
- 'GPRINT:kod:AVERAGE:Average\:%8.2lf %s',
- 'GPRINT:kod:MIN:Minimum\:%8.2lf %s',
- 'GPRINT:kod:MAX:Maximum\:%8.2lf %s\n',
+ 'GPRINT:kod:LAST:Current\:%8.0lf %s',
+ 'GPRINT:kod:AVERAGE:Average\:%8.0lf %s',
+ 'GPRINT:kod:MIN:Minimum\:%8.0lf %s',
+ 'GPRINT:kod:MAX:Maximum\:%8.0lf %s\n',
);
}
diff --git a/scripts/templates/tail b/scripts/templates/tail
index 70dc804..f9f32de 100644
--- a/scripts/templates/tail
+++ b/scripts/templates/tail
@@ -4,7 +4,7 @@
<p><a href='http://time.mattrude.com'>Home</a> | <a href='/status/'>Status</a> | <a href='/documentation/'>Documentation</a> | <a href='https://github.com/mattrude/time.mattrude.com'>Source</a></p>
</div>
<div class="footer-right">
- <p>Copyright &copy; 2009 &mdash; 2011 by <a href='http://mattrude.com'>Matt Rude</a></p>
+ <p>Copyright &copy; 2009 &mdash; 2012 by <a href='http://mattrude.com'>Matt Rude</a></p>
</div>
</div>
</div>
diff --git a/scripts/templates/template-host b/scripts/templates/template-host
index dd25688..255ef77 100644
--- a/scripts/templates/template-host
+++ b/scripts/templates/template-host
@@ -25,7 +25,7 @@ cjit clock jitter
wander clock frequency wander (PPM)
disp total dispersion to the primary reference clock
</pre>
-<p>You may also download POOL&rsquo;s <a href='/rrd/POOL.rrd'>RRD</a> file or view it&rsquo;s <a href='/csv.php?host=POOL'>CSV</a> file.</p>
+<p>You may also download POOL&rsquo;s <a href='/rrd/POOL.rrd'>RRD</a> file or view it&rsquo;s <a href='/rrd/POOL.csv'>CSV</a> file.</p>
<h2>Host POOL, Daily Status</h2>
<div id="graphs" class="center">
<p><a href="/status/POOL/clients/"><img src="/bin/graphs-POOL.cgi?0-clients" alt="Clients" /></a></p>