I'd like to add a new RRA to the RRD file. Can't figure out how to do it.
Here's some background information:
I'm using Cacti 0.8.7e with rrdtool verion 1.3.8-1.
I've setup my RRDs to use four custom RRAs instead of the default ones. The major difference is that there is no data point averaging being done.
Here is my RRA setup (5 minute polling interval):
RRA1: Daily
Consolidation: average
steps: 1
rows: 300
Timespan: 86400
RRA2: Weekly
Consolidation: average
steps: 1
rows: 2304
Timespan: 604800
RRA3: Monthly
Consolidation: average
steps: 1
rows: 9216
Timespan: 2592000
RRA4: Yearly
Consolidation: average
steps: 1
rows: 109440
Timespan: 31536000
The reason there is no averaging is because the powers from above do not want to loose any data point. They want to be able to zoom into any "peak" on the graph and be able to look at the real data as opposed to an average.
However now they want to be able to keep more than a year's worth. Hard drive space is not an issue so I've opted for a ten year RRA. I just don't know how to modify an existing RRD file to incorporate these changes. I've tried some scripts to export data and import back but it doesn't seem to work.
thanks in advance for your help
Guy
_______________________________________________
rrd-users mailing list
rrd-...@lists.oetiker.ch
https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users
Yesterday Bigras, Guy wrote:
two things ...
a) you missunderstood the RRA concept ... if you want to keep hires
data, you should just make the RRA1 very long ... but still have
some lower resolution RRAs (maybe of the same length) as they will
provide performance benefits when generating graphs over long
periodes of time.
b) there is rrdtool resize for resising RRAs ... although there
might be 'odd' side effects as the newly created space will be
empty ...
cheers
tobi
>
> _______________________________________________
> rrd-users mailing list
> rrd-...@lists.oetiker.ch
> https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users
>
>
--
Tobi Oetiker, OETIKER+PARTNER AG, Aarweg 15 CH-4600 Olten, Switzerland
http://it.oetiker.ch to...@oetiker.ch ++41 62 775 9902 / sb: -9900
> Hi there,
>
> I'd like to add a new RRA to the RRD file. Can't figure out how to do it.
and you don't need to.
> Here's some background information:
>
> I'm using Cacti 0.8.7e with rrdtool verion 1.3.8-1.
>
> I've setup my RRDs to use four custom RRAs instead of the default ones.
> The major difference is that there is no data point averaging being done.
If you think that you store data with no alteration whatsoever, be careful.
Only in very specific circumstances this will be true. You really need to
study normalization and consolidation. See further on.
> Here is my RRA setup (5 minute polling interval):
[partially cut away]
> RRA1: Daily> Consolidation: average> steps: 1
> RRA2: Weekly> Consolidation: average> steps: 1
> RRA3: Monthly> Consolidation: average> steps: 1
> RRA4: Yearly> Consolidation: average> steps: 1
> rows: 109440
> Timespan: 31536000
All your RRAs have consolidation function average and steps==1. That's
useless. RRAs 1,2 and 3 just contain parts of what RRA 4 contains.
> The reason there is no averaging is because the powers from above do not
> want to loose any data point. They want to be able to zoom into any
> "peak" on the graph and be able to look at the real data as opposed to an
> average.
That explains why you would have one large RRA with steps==1 step. But it
doesn't explain why you have the other 3 setup as you have. Study the
tutorials, visit my site http://www.vandenbogaerdt.nl/rrdtool/
> However now they want to be able to keep more than a year's worth. Hard
> drive space is not an issue so I've opted for a ten year RRA. I just
> don't know how to modify an existing RRD file to incorporate these
> changes. I've tried some scripts to export data and import back but it
> doesn't seem to work.
10 years = 7*365 days + 3*366 days (leap years) * 288 rows = 1052064 rows.
Increase the size of RRA 4. That RRA contains the largest amount of
information. Any rows you add do not magically contain information you
didn't have before, but as soon as they are there, you can start building
history.
You already have 109440 so grow the RRA by 942624 rows. And don't forget
that a new RRD is built, you need to check that RRA (to see if it really is
what you want) and then copy it over the old one. And don't forget to
backup the previous one first.
You can keep the other RRAs (useless, but not in your way) or you can setup
the RRD in a different way. Explaining how would be a bit too much right
now. You could also consider to hire someone to help you, tutor you, or
both.
Regards,
Alex
Unfortunately "they" want to keep or see graphs for each "fake" consolidation (ie:daily, weekly, etc...). My 1st attempt was one RRA with no consolation (steps=1) and a years worth of rows. However Cacti would only create or show one graph. One RRA = One Graph and as I said "they" wanted to see various graphs ... sigh. Therefore if I want to add another graph with a 5/10 year span I'd have to create another RRA. Is it possible ?
thanks again guys for your time.
Guy
> Wow. Thanks everyone for the fast replies.
>
> Unfortunately "they" want to keep or see graphs for each "fake"
> consolidation (ie:daily, weekly, etc...). My 1st attempt was one RRA with
> no consolation (steps=1) and a years worth of rows. However Cacti would
> only create or show one graph. One RRA = One Graph and as I said "they"
> wanted to see various graphs ... sigh. Therefore if I want to add another
> graph with a 5/10 year span I'd have to create another RRA. Is it
> possible ?
>
> thanks again guys for your time.
Is it possible to add an RRA? Sure. I think there's a script available,
somewhere, but I wouldn't know where. Google for it, or wait until you get
an answer from someone who knows.
If you cannot find it: create a new RRD with the properties you want to see,
dump the old RRD to xml, dump the new RRD to xml, copy the data over from
old.xml to new.xml (don't forget to also update that new RRA) and restore
the database from new.xml
Perhaps a viable alternative: Ask a cacti user group or such for help on how
to display different graphs from the same RRA source. Maybe it isn't
possible, I don't know, but then again maybe it is and you just don't know
how.
If you need to keep those RRAs, why not make use of one feature of RRDtool.
If you want an RRA to display, for instance, 400 days in an image where the
inner part (the graph part) is 400 pixels wide, setup that RRA so that each
CDP (Consolidated Data Point) is worth 86400 seconds. That way RRDtool does
not need to consolidate the data at graph time, saving time when watching
that data.
HTH