[rrd-users] Simple DEF Arithmetic

Chris Mason chris at netnix.org
Tue Aug 6 15:27:58 CEST 2013


Hi,

I am trying to create a combined graph with data from two data sources and
I am seeing some unexpected results. I have removed everything from my
graph and produced a simple script which recreates the problem:

DEF:A='a.rrd':DS1:MAX
DEF:B='b.rrd':DS1:MAX

CDEF:AB=A,B,ADDNAN

PRINT:A:MAX:'A\: %.3lf %S'
PRINT:B:MAX:'B\: %.3lf %S'
PRINT:AB:MAX:'Total\: %.3lf %S'

If I graph this with "--start -1m" I get the following:

A: 749.807 M
B: 1744.822 M
Total: 2325.624 M

and with "--start -1y":

A: 749.807 M
B: 1744.822 M
Total: 2430.266 M

When I attempt to display data with "--start -1y" this is where the problem
occurs. As you can see the MAX value for A and B hasn't changed, but my
total has?

When I convert these values into bps then the difference is 837mbps which
isn't a small amount.

Am I doing something wrong or is this expected?

Thanks,
Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.oetiker.ch/pipermail/rrd-users/attachments/20130806/4caeb4d0/attachment.htm 


More information about the rrd-users mailing list