[rrd-users] Zero length var-string is converted to 0 instead of NaN
rrd-users at ficos.de
Wed Oct 15 19:22:58 CEST 2008
> I'm using a small sh script to fill my rrd database.
> for better understanding I echoed out the values before they were stored.
> looks like this
> DEBUG stringlength: 4,3,0,0,4,3,2,2,2,2,9,8
> You can see there are 2 values "missing". that's correct because they are not
> available for all data-source clients.
> unfortunately rrdtool update won't convert these values to NaN instead it
> stores 0.000000+0. The Problem is, sometimes these values are really 0
> therefore setting min to 1 while creating the database won't help much.
> Is it a bug or a feature?
> For now I'm checking the length of the variables I'm going to store and set
> 0-length ones manually to "NAN"
> my new NAN values are accepted by rrdtool update and stored as NaN in the
> I don't think this is the professional way, or is it?
> thanks in advance for any help or suggestions
the rrdupdate manpage clearly says:
"... The remaining elements of the argument are DS updates. The order of this
list is the same as the order the data sources were defined in the RRA.
If there is no data for a certain data-source, the letter U (e.g., N:0.1:U:1)
can be specified."
More information about the rrd-users