[rrd-developers] Cricket/RRDtool doesn't like restarting devices

Bert Driehuis driehuis at playbeing.org
Tue Jan 11 23:58:47 MET 2000


I've had an unrelated cause for spikes that render the charts of the
history of my Squid server useless. RRDtool (at least in the way it is
called by Cricket, but I believe this to be generally true) cannot cope
with a restart of an SNMP agent. COUNTER objects wind up with huge
values in this scenario:

Time	Value	PDP Value
t	200	0
t+1	250	50
t+2	300	50
 [ agent restarts, counter goes to zero ]
t+3	5	4.2e9

This can easily be demonstrated by monitoring the value of
system.sysUpTime.0 for a while (it will show a value of about 100), then
restarting your snmpd. Squid will expose this behavior more easily than
a router, as network gear tends to be rarely rebooted (well, Squid
shouldn't die either, but my test server does every once in a while,
usually due to pilot error on my side :-)

It could be an artifact of something else I've done wrong, but I think
the code in rrd_update.c to deal with overflow is asking for trouble
anyway. I've attached a diff that replaces that check with an assignment
of NaN, and unless people object, ask Tobi to include it in the next

Overflows are fairly rare, in my experience. If dealing with them is
important, code needs to be added to Cricket to check to see if
system.sysUpTime.0 has decreased since the previous sample, and in that
case mark the sample with a tag to indicate that it is a valid sample,
but should not be used for a comparison with the previous value. This
would be pretty complicated to do right.

Am I overlooking the obvious?


					-- Bert
Bert Driehuis -- driehuis at playbeing.org -- +31-20-3116119
The grand leap of the whale up the Fall of Niagara is esteemed, by all
who have seen it, as one of the finest spectacles in nature.
                -- Benjamin Franklin.

-- Attached file removed by Listar and put at URL below --
-- Type: text/plain
-- Size: 1k (1083 bytes)
-- URL : http://www.ee.ethz.ch/~slist/pantomime/t

Unsubscribe mailto:rrd-developers-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-developers-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-developers

More information about the rrd-developers mailing list