RRD and fetching

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

RRD and fetching

trygvelu
Hello,

I am setting up a script that does some analyzing on data over a
specified amount of time, in various RRD files. I've been using
RRDs::fetch to get to the data, however there are one or two things I'd
like to see..

o RRDs::fetch will only get values within a limited time range (with 300s
step). This forces me to parse RRDp output (which isn't so nice..)
instead, when I want to go further back in time.

o It would be nice to call a function that returns only the MAX or AVERAGE
(whichever is specified) _overall value_ for some specified time range (be
it -5min, -10h or -1m). Of course it would be nice to have this in RRDs..
The motivation for this would be that I won't have to sum or compare the
output lists, or even care about values that weren't specified in some
sampling periods. And doing sums/comparisons on a lower level would be
significantly faster.


Any thoughts, have I overlooked something obvious?
(Maybe these new functions/changes will be harder to implement now that
rrdtool has gone release(1.0.0), but I do have some hope that it can be
done.. =)

(Good work Tobi, I'll send you a cd soon :)
cheers,
--
Trygve Lunheim
NTNU ITEA/Nett

--
* To unsubscribe from the rrd-users mailing list, send a message with the
  subject: unsubscribe to [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: RRD and fetching

Tobias Oetiker
Today you sent me mail regarding [rrd-users] RRD and fetching:

*> Hello,
*>
*> I am setting up a script that does some analyzing on data over a
*> specified amount of time, in various RRD files. I've been using
*> RRDs::fetch to get to the data, however there are one or two things I'd
*> like to see..
*>
*> o RRDs::fetch will only get values within a limited time range (with 300s
*> step). This forces me to parse RRDp output (which isn't so nice..)
*> instead, when I want to go further back in time.
*>
*> o It would be nice to call a function that returns only the MAX or AVERAGE
*> (whichever is specified) _overall value_ for some specified time range (be
*> it -5min, -10h or -1m). Of course it would be nice to have this in RRDs..
*> The motivation for this would be that I won't have to sum or compare the
*> output lists, or even care about values that weren't specified in some
*> sampling periods. And doing sums/comparisons on a lower level would be
*> significantly faster.

I am not quite sure what you are trying todo, but cant you use PRINT in
rrdtool graph for your purpose ?

cheers
tobi
*>
*>
*> Any thoughts, have I overlooked something obvious?
*> (Maybe these new functions/changes will be harder to implement now that
*> rrdtool has gone release(1.0.0), but I do have some hope that it can be
*> done.. =)
*>
*> (Good work Tobi, I'll send you a cd soon :)
*> cheers,
*>

--
 ______    __   _
/_  __/_  / /  (_) Oetiker, Timelord & SysMgr @ EE-Dept ETH-Zurich
 / // _ \/ _ \/ / TEL: +41(0)1-6325286  FAX:...1517  ICQ: 10419518
/_/ \.__/_.__/_/ [hidden email] http://ee-staff.ethz.ch/~oetiker

--
* To unsubscribe from the rrd-users mailing list, send a message with the
  subject: unsubscribe to [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: RRD and fetching

Alex van den Bogaerdt
In reply to this post by trygvelu
> o It would be nice to call a function that returns only the MAX or AVERAGE
> (whichever is specified) _overall value_ for some specified time range (be
> it -5min, -10h or -1m). Of course it would be nice to have this in RRDs..
> The motivation for this would be that I won't have to sum or compare the
> output lists, or even care about values that weren't specified in some
> sampling periods. And doing sums/comparisons on a lower level would be
> significantly faster.
>

rrdtool graph /dev/zero \
    --start "any date/time you like" \
    --end "any other date/time thereafter" \
    DEF:val1=$RRD:$DS1:AVERAGE \
    DEF:val2=$RRD:$DS2:AVERAGE \
    PRINT:val1:MAX:"%6.2lf bps" \
    PRINT:val1:MIN:"%6.2lf bps" \
    PRINT:val1:AVERAGE:"%6.2lf bps" \
    PRINT:val2:MAX:"%6.2lf bps" \
    PRINT:val2:MIN:"%6.2lf bps" \
    PRINT:val2:AVERAGE:"%6.2lf bps"

modify to suit your needs

Regards,
Alex

--
* To unsubscribe from the rrd-users mailing list, send a message with the
  subject: unsubscribe to [hidden email]