[rrd-users] Percentages on the graphs

Chris Marlow marlowc at us.ibm.com
Fri Feb 9 18:32:21 MET 2001


Thanks everyone for the help - in case anyone was interested, the following
config calculated the percentages and placed them on the graph (Sort of
like MRTG did):

    $GraphCommand = $BinPath . " graph " . $WorkPath . $Machine . '-day.png
'.
     '--start -86400 ' .
     '--title="Interface traffic for ' . $Machine . '" ' .
     '--vertical-label "bits per second" ' .
     '--imgformat PNG ' .
     '--color CANVAS#DDDDDD ' .
     '--color BACK#EEEEEE ' .
     '--height 350 ' .
     '--width  600 ' .
     'DEF:inoctets=' . $DatabaseFile . ':input:AVERAGE ' .
     'CDEF:inbits=inoctets,8,* ' .
     'CDEF:inpercent=inoctets,' . $MaxBytes . ',/,100,* ' .
     'DEF:outoctets=' . $DatabaseFile . ':output:AVERAGE ' .
     'CDEF:outbits=outoctets,8,* ' .
     'CDEF:outpercent=outoctets,' . $MaxBytes . ',/,100,* ' .
     'COMMENT:"                                  Max
Average                      Last\n" ' .
     'AREA:inbits#FFCC00:"Inbound Traffic " ' .
     'GPRINT:inbits:MAX:"%10.4lf %sbps" ' .
     'GPRINT:inpercent:MAX:"(%04.2lf%%)" ' .
     'GPRINT:inbits:AVERAGE:"%10.4lf %sbps" ' .
     'GPRINT:inpercent:AVERAGE:"(%04.2lf%%)" ' .
     'GPRINT:inbits:LAST:"%10.4lf %sbps" ' .
     'GPRINT:inpercent:LAST:"(%04.2lf%%)\n" ' .
     'LINE1:outbits#CC66FF:"Outbound traffic" ' .
     'GPRINT:outbits:MAX:"%10.4lf %sbps" ' .
     'GPRINT:outpercent:MAX:"(%04.2lf%%)" ' .
     'GPRINT:outbits:AVERAGE:"%10.4lf %sbps" ' .
     'GPRINT:outpercent:AVERAGE:"(%04.2lf%%)" ' .
     'GPRINT:outbits:LAST:"%10.4lf %sbps" ' .
     'GPRINT:outpercent:LAST:"(%04.2lf%%)\n" ';

This is run as a perl script, so the varialbe names might be confusing, but you get the idea....

Thanks again,

-Chris



-----
Christopher S. Marlow
IBM
AIX Infrastructure / 24x7 Security
Burlington, VT
Phone: 802-769-3253
Tie line: 446-3253
e-mail: marlowc at us.ibm.com


--
Unsubscribe mailto:rrd-users-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-users-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-users
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi



More information about the rrd-users mailing list