[rrd-users] rrdtool update

[Digital^Dude] ® millennium.bug at gmail.com
Fri Jun 1 13:16:00 CEST 2012


Great. We have a database that cannot be edited :) Thank you RRD!

On Fri, Jun 1, 2012 at 3:47 PM, Simon Hobson <linux at thehobsons.co.uk> wrote:

> >I need to update an rrd at a specific time
> >stamp. Whatever timestamp I give is rejected
> >with:
> >ERROR: file.rrd: illegal attempt to update using
> >time 1338480000 when last update time is
> >1338546901 (minimum one second step)
>
>
> [Digital^Dude] ® wrote:
> >I want to update these two values:
> >
> >1338480000: -3.0293609367e+06
> >1338480300: -2.0135146667e+04
> >
> >to ZERO.
>
>
> Top posting fixed ...
>
> Simple, you cannot do this.
> You can **NEVER** go back in time with RRD. Once
> you apply an update at any time, then you can
> never submit an update for an earlier time.
> When you do an update, several things happens :
>
> 1) RRD will to the necessary calculations to work
> out the rate from the previous update to this one.
>
> 2) If the new time is such that one or more steps
> or consolidated periods are now complete, then
> these will have data entered for them.
>
> 3) Any data (such as previous update values) not
> now needed to do the same calculations next time
> are discarded. The last update values are kept as
> they will (in most cases) be needed to do the
> same calculations at the next update.
>
>
> There are only two ways to go back and submit new data :
>
> 1) Delete your database, create a new one, and
> re-enter all data. This means keeping all your
> data somewhere outside of RRD so you can change
> values and resubmit them - in chronological order.
>
> 2) You can dump the RRD to an XML file and edit
> the values before reading the XML into a new RRD
> file.
>
> In theory it would be possible to directly edit
> the RRD file, but there are no tools for that.
> You could also just dump the data with "rrd
> fetch" - but then you'd need to do some work to
> select which data to use, potentially do some
> interpolation, and then stuff it back into a new
> RRD with a series of updates. Potentially a lot
> of work, and again, no tools for it.
>
> --
> Simon Hobson
>
> Visit http://www.magpiesnestpublishing.co.uk/ for books by acclaimed
> author Gladys Hobson. Novels - poetry - short stories - ideal as
> Christmas stocking fillers. Some available as e-books.
>
> _______________________________________________
> rrd-users mailing list
> rrd-users at lists.oetiker.ch
> https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.oetiker.ch/pipermail/rrd-users/attachments/20120601/9a363cdd/attachment.htm 


More information about the rrd-users mailing list