[rrd-users] Adding updates but fetch shows NaNs

Issaac B sirissaac at gmail.com
Tue Jan 23 02:01:11 CET 2018


I was hoping someone could help me understand how values are computed in
RRD.
I got a temp database (create below). I got a loop that adds an update ever
~2 minutes.

rrdtool info says the DS got known values for the last two
columns (ext_temperature, ext_humidity).
Yet when I do a graph/fetch, I'm getting NaNs for the last two columns.

Thanks,
===============

Create:
rrdtool create $HOME/.xdg/data/nest_thermostat.rrd \
--step '200' \
'DS:temperature:GAUGE:600:0:100' \
'DS:humidity:GAUGE:600:0:100' \
'DS:target:GAUGE:600:0:100' \
'DS:mode:GAUGE:600:0:10' \
'DS:state:GAUGE:600:0:10' \
'DS:fan:GAUGE:600:0:1' \
\
'DS:ext_temperature:GAUGE:1500:0:100' \
'DS:ext_humidity:GAUGE:1500:0:100' \
\
'RRA:AVERAGE:0.5:1:2016' \
'RRA:AVERAGE:0.5:1:4032' \
'RRA:AVERAGE:0.5:6:1440' \
'RRA:AVERAGE:0.5:6:4416' \
'RRA:AVERAGE:0.5:12:4392' \
'RRA:AVERAGE:0.5:24:4380' \
'RRA:AVERAGE:0.5:48:4380'

Update logs:
2018-01-22 16:54:40.787444: Updating RRD with N:67:50:65:2:0:0:U:U
2018-01-22 16:54:40.788156: Updating RRD with N:U:U:U:U:U:U:56.5:65
2018-01-22 16:56:11.899996: Updating RRD with N:67:50:65:2:0:0:U:U
2018-01-22 16:56:11.900661: Updating RRD with N:U:U:U:U:U:U:56.5:65

rrdtool info:
$  rrdtool info nest_thermostat.rrd  | grep ext
ds[ext_temperature].index = 6
ds[ext_temperature].type = "GAUGE"
ds[ext_temperature].minimal_heartbeat = 1500
ds[ext_temperature].min = 0.0000000000e+00
ds[ext_temperature].max = 1.0000000000e+02
ds[ext_temperature].last_ds = "56.5"
ds[ext_temperature].value = 3.6216500000e-02
ds[ext_temperature].unknown_sec = 62
ds[ext_humidity].index = 7
ds[ext_humidity].type = "GAUGE"
ds[ext_humidity].minimal_heartbeat = 1500
ds[ext_humidity].min = 0.0000000000e+00
ds[ext_humidity].max = 1.0000000000e+02
ds[ext_humidity].last_ds = "65"
ds[ext_humidity].value = 4.1665000000e-02
ds[ext_humidity].unknown_sec = 62

Fetch:
$  rrdtool fetch nest_thermostat.rrd AVERAGE | tail -n5
1516668600: 6.6830290005e+01 4.9873350750e+01 6.4835355975e+01
1.9949340300e+00 0.0000000000e+00 0.0000000000e+00 -nan -nan
1516668800: 6.6834396100e+01 4.9876415000e+01 6.4839339500e+01
1.9950566000e+00 0.0000000000e+00 0.0000000000e+00 -nan -nan
1516669000: 6.6999548755e+01 4.9999663250e+01 6.4999562225e+01
1.9999865300e+00 0.0000000000e+00 0.0000000000e+00 -nan -nan
1516669200: 6.6910302075e+01 4.9933061250e+01 6.4912979625e+01
1.9973224500e+00 0.0000000000e+00 0.0000000000e+00 -nan -nan
1516669400: -nan -nan -nan -nan -nan -nan -nan -nan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.oetiker.ch/pipermail/rrd-users/attachments/20180122/4d3ad56d/attachment.html>


More information about the rrd-users mailing list