[mrtg] mrtg and non-traffic integers

Bishop, Dean dean.bishop at tcdsb.org
Tue Oct 29 17:50:26 MET 2002


Good morning,

 i am having trouble getting non-percentage, non-traffic numbers graphed.
For example diskspace on my linux box and the total number of hosts that are
"UP" according to Nagios.

 For the first i am just feeding in the "blocks available" from 'df' and
instead of getting 93164 i get 89.15M.

 For the second, i am using a small script that outputs the number, say 11,
but it is graphed as 10.8.

 Below are the configs.  Where am i going wrong??

#Total Hosts Up / Down
Target[servers]: `/usr/local/bin/mrtghost_total.pl`  <-- returns 4 lines
"1400" "9" "1" "1"
Title[servers]: Total Hosts Up And Down
PageTop[servers]: <H1>Total Hosts Up And Down</H1>
YLegend[servers]: Hosts
ShortLegend[servers]:  Hosts
Legend1[servers]:  Hosts
LegendI[servers]: &nbsp;Hosts UP:
LegendO[servers]: &nbsp;Hosts DOWN:
MaxBytes[servers]: 5000
Factor[servers]: 1000
Options[servers]: growright, gauge, integer, absolute, nopercent


######################################################################
#                                                                    #
# this is the disk used and free on /                   #
#                                                                    #
######################################################################
Target[diskspaceusedandfree]:  `perl -e '$f="%.0f";$fmt="$f\n$f\n1\nDisk
Space Used and Free\n";@line=split " ", (qx(df));$o=sprintf
$fmt,$line[9]*1000,$line[10]*1000;print $o; print STDERR $o'`
Options[diskspaceusedandfree]: gauge
MaxBytes[diskspaceusedandfree]: 8858784000000
#ABSMax[diskspaceusedandfree]: 7858784000
kMG[diskspaceusedandfree]: M,G,T,P,X
YLegend[diskspaceusedandfree]: bytes
Unscaled[diskspaceusedandfree]: ymwd
ShortLegend[diskspaceusedandfree]: 
Legend1[diskspaceusedandfree]: Used
Legend2[diskspaceusedandfree]: Free
LegendI[diskspaceusedandfree]:  Disk Space Used
LegendO[diskspaceusedandfree]:  Disk Space Free
Title[diskspaceusedandfree]: Server Disk space used and Free on /
PageTop[diskspaceusedandfree]: <H2>Server Disk Space Used and Free on /</H2>

--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive     http://www.ee.ethz.ch/~slist/mrtg
FAQ         http://faq.mrtg.org    Homepage     http://www.mrtg.org
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi



More information about the mrtg mailing list