[rrd-users] how to draw correct graph on server rrdfiles when some of them have zero/null values?

Jean-Yves Avenard jyavenard at gmail.com
Tue Jan 5 10:01:39 CET 2010


Hi

2010/1/5 George-lll <liusoaring at gmail.com>:

> but if some rrd files have zero/null value(indicate some servers got no
> traffic at that period), the charts combined curve drop to zero too.

Are they zero or undefined ?
They do not mean the same thing.

The reason you are seeting what you're describing is because
undefined + anything = undefined..

If the traffic was 0, you should have added 0 to the RRD via rrdtool
update ; According to your RRD definition, if you do not feed any data
for 2 hours, then entry will be undefined for that period.

>
> wondering there is a data validation before rrdtool starting up, so someone
> let me know hwo to avoid?

What you could do in your CDEF is something like this:
CDEF:x=val1,UN,0,val1,IF,val2,UN,0,val2,IF,+ etc..

This will replace all unknown values with 0.

Jean-Yves



More information about the rrd-users mailing list