[rrd-users] COMPUTE DS & altering existing rrd file
linux at thehobsons.co.uk
Wed Sep 28 16:51:57 CEST 2016
> Can I confirm I have this right ...
> If I want to have a DS showing if the measured value was above some threshold (in this case, network traffic above say 80%) I can use a compute DS like :
> So if the "in" value is greater than the threshold value (nnnn here) then pc80 will be 1, and this will get consolidated so that later I'll be able to see (for example) a consolidated value that might show (say) 0.2 meaning that the "in" value was above the threshold for 20% of the time during that consolidated period.
> And I can add this with rrdtune with
> rrdtool tune somefile.rrd DS:pc80:COMPUTE:in,nnnn,GT
I assume it's right since there's been no corrections. Also, I assume this is done after computing the value for each PDP - so if I have a step of 300 (5 mins) it'll compute the rate for each 5 min step before applying the RPN expression to calculate the computed value ?
> What about if (or rather, when) I need to change the thresholds later ? Specifically I'm thinking that if we currently have (say) 100Mbps service, and we upgrade it to (say) 200Mbps, I'll need to change the threshold (and thus the computation for new data) without affecting historical data. I don't see an option for rrdtune to do this.
> Lastly, in what version does rrdtune get to add a DS ? I have 1.4.7 (Debian Wheezy) and the man page doesn't mention adding or deleting DSs.
And a quick test shows that "rrdtool tune test.rrd DS:InPC:COMPUTE:In,100000000,/" just shows current values for the DSs without doing anything - the same as just "rrdtool tune test.rrd". Later versions of rrd in the Debian archives have dependencies not met on Wheezy - unless someone felt like packaging it up for backports.
More information about the rrd-users