[rrd-users] setting last_update
Alex van den Bogaerdt
alex at ergens.op.het.net
Thu Feb 15 15:06:07 CET 2007
On Thu, Feb 15, 2007 at 08:11:06AM -0500, Dan Langille wrote:
> My short term goal is to reset last_update in an rrd file. Long
> term, I'd like to find the cause of the very large value contained
> therein.
>
> The problem occurs on a system running FreeBSD 6.2 with an amd64
> kernel.
Hmmm... 64-bit. You may very well have found a bug. Not necessarily
in RRDtool, perhaps a library or so.
> I encountered these errors yesterday:
>
> rrd_update:illegal attempt to update using time 1171508010 when last
> update time is 94450340160
>
> The first date looks OK. The second does not.
Indeed.
> Looking at the rrd file:
>
> # rrdtool info cpu0.rrd | head
> filename = "cpu0.rrd"
> rrd_version = "0003"
> step = 5
> last_update = 944503401600
>
>
> Notice the date, that's a bit odd:
>
> # date -r 944503401600
> Wed Feb 14 00:00:00 PST 31900
Using GNU date:
$ date -u -d 19700101\ 00:00\ 94450340160\ seconds
Mon Oct 7 07:14:08 UTC 1968
I'm not saying that this is more correct, I'm just noticing a difference.
[snip: good on i386]
> Failing a solution, does anyone know how to reset the last_update
> field in an rrd file?
you could try a dump-restore cycle. But I would pay much attention
to the rest of the file as well.
$ rrdtool dump my.rrd|head -7
<!-- Round Robin Database Dump -->
<rrd>
<version> 0003 </version>
<step> 60 </step> <!-- Seconds -->
<lastupdate> 1171548181 </lastupdate> <!-- 2007-02-15 15:03:01 CET -->
<ds>
HTH
--
Alex van den Bogaerdt
http://www.vandenbogaerdt.nl/rrdtool/
More information about the rrd-users
mailing list