[rrd-users] Re : Printing a single simple average value

Etienney Claire etienney_claire at yahoo.fr
Tue Jun 17 09:31:16 CEST 2008


I searched for this functionnality few weeks ago.
This is an extract from my perl script:

my ($averages,$xsize,$ysize) = RRDs::graph($rrdargs);
$CPU = $$averages[0];

I hope this will help you


----- Message d'origine ----
De : "Ruttenberg, Tanya" <Tanya.Ruttenberg at ssa.gov>
À : rrd-users at lists.oetiker.ch
Envoyé le : Lundi, 16 Juin 2008, 19h25mn 04s
Objet : [rrd-users] Printing a single simple average value

Printing a single simple average value 
Hi RRD Users, 
I have an rrdfile router1.rrd that collects utilization data every 15 minutes.  I want to print a single value which represents an AVERAGE rate over a 6 week period.
I have read documentation and played around with this for several days and I haven't been able to figure it out. 
The closest I came was this: 
rrdtool graph - -s "midnight-6w" -e "midnight" \ 
DEF:ds0=router1.rrd:ifInOctets:AVERAGE \ 
VDEF:ds1=ds0,AVERAGE \ 
At least this doesn't give me any errors, but it doesn't give me any output whatsoever. 
Ideally I want to put this into a perl script like: 
$average = RRDs::graph($rrdargs); 
What am I doing wrong? 

Tanya Ruttenberg 
SMC/OND Administrator for DNE 
SMC Email & Home Page: #SMC Admin http://smc.ba.ssa.gov 
OND Email & Home Page: #OND Admin http://ssahost.ba.ssa.gov/ONDwebinterface 

Envoyez avec Yahoo! Mail. Une boite mail plus intelligente http://mail.yahoo.fr
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.oetiker.ch/pipermail/rrd-users/attachments/20080617/51b9a920/attachment.html 

More information about the rrd-users mailing list