[rrd-users] Problems with COUNTER data sources

Alexander Koeppe format_c at online.de
Thu May 24 19:54:49 CEST 2007


Hello List,

I searched the web for my problem but could find something that helped.
So here is my problem:

I've created several Graphs and databases. But all Databases that have
COUNTER Datasources react strange sometimes. The script below emulates
the data polling process and writes every 60 Seconds values into the
database. I multiply them with 60 because I want to display the Mails
processed per minute. So the value steps are based on 60.

But I expected some different values: i.e.
1180027440: 0.0000000000e+00 5.5041617224e-01 1.1008323445e+00
0.0000000000e+00 0.0000000000e+00
should be
1180027440: 0.0000000000e+00 1.0000000000e+00 2.0000000000e+00
0.0000000000e+00 0.0000000000e+00

and so on.

Can someone tell me what I'm doing wrong?

Below you find the polling emulation script and the output of rrdfetch.



$ cat test.sh
rrdtool create ../db/mail.rrd --step 60 DS:total:COUNTER:120:0:U
DS:spam:COUNTER:120:0:U DS:relay:COUNTER:120:0:U
DS:error:COUNTER:120:0:U DS:queue:GAUGE:120:0:U RRA:AVERAGE:0.5:1:2160
sleep 60
rrdtool update ../db/mail.rrd N:16920:420:420:0:0
sleep 60
rrdtool update ../db/mail.rrd N:16920:420:420:0:0
sleep 60
rrdtool update ../db/mail.rrd N:16920:480:540:0:0
sleep 60
rrdtool update ../db/mail.rrd N:16980:480:540:0:0
sleep 60
rrdtool fetch ../db/mail.rrd AVERAGE | tail -n 15
$bash test.sh
1180026780: nan nan nan nan nan
1180026840: nan nan nan nan nan
1180026900: nan nan nan nan nan
1180026960: nan nan nan nan nan
1180027020: nan nan nan nan nan
1180027080: nan nan nan nan nan
1180027140: nan nan nan nan nan
1180027200: nan nan nan nan nan
1180027260: nan nan nan nan nan
1180027320: nan nan nan nan 0.0000000000e+00
1180027380: 0.0000000000e+00 0.0000000000e+00 0.0000000000e+00
0.0000000000e+00 0.0000000000e+00
1180027440: 0.0000000000e+00 5.5041617224e-01 1.1008323445e+00
0.0000000000e+00 0.0000000000e+00
1180027500: 5.5024873405e-01 4.4958382776e-01 8.9916765553e-01
0.0000000000e+00 0.0000000000e+00
1180027560: nan nan nan nan nan
1180027620: nan nan nan nan nan
$



More information about the rrd-users mailing list