[rrd-users] Re: I need help to calculate % of max bandwidth !!!

Alex van den Bogaerdt alex at slot.hollandcasino.nl
Wed Apr 17 11:34:04 MEST 2002


Iain Buchanan wrote:

> DEF:trend=data.rrd:bitsin:AVE
> CDEF:pctrend=57600,trend,/,100,*
> LINE1:pctrend
> GPRINT:pctrend:AVE:%.2f

You can skip the LINE1 here, unless you use it for other purposes.

Drawing an invisible line is, AFAIK, only useful together with STACK.

Another thing:
> (this is the percent, assuming your max bandwidth is a 56k modem)

1) 56k is 56k, not 57.6k
2) the percentage is   trend/max * 100  , not   max/trend * 100

So: CDEF:pctrend=trend,56000,/,100,*

It can be changed into: CDEF:pctrend=trend,560,/
This is because   x/y *100  == x/(y/100) 

cheers,
-- 
   __________________________________________________________________
 / alex at slot.hollandcasino.nl                  alex at ergens.op.het.net \
| work                                                         private |
| My employer is capable of speaking therefore I speak only for myself |
+----------------------------------------------------------------------+
| Technical questions sent directly to me will be nuked. Use the list. | 
+----------------------------------------------------------------------+
| http://faq.mrtg.org/                                                 |
| http://rrdtool.eu.org  --> tutorial                                  |
+----------------------------------------------------------------------+

--
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