[rrd-users] values being averaged.

Richard.W.Brown at nokia.com Richard.W.Brown at nokia.com
Thu Jan 17 14:27:05 CET 2008

I've been playing around with RRDtool as it looks like a tool that can
in the long run save me a lot of time. My current requirement is to
collect data related to a cluster of Linux machines.

I have seen another post  in January 2008 with what sounds like the same
problem and the solution does not answer the problem. --width sets the
width of the canvas of the graphic that is output and has nothing to do
with the data that is displayed, well that is, according to man
rrdgraph. :-) 

The problem is that the value displayed on the graphs for number of
clients (as in Client server) shows 0.6 of a client! Well, since we all
know client connections can only be integer values this is obviously
RRDp::cmd   "create cluster_clients.rrd".
            "start 1200483121 --step 300 ",
            "DS:clients:GAUGE:600:U:U ".
            "RRA:LAST:0.75:1:288";         # every 5 minutes, for one

$rrd_cmd = "graph client_graph.png ".
           "--start -$graph_step ".
           "--title $graph_title ".
           "--lazy -h $h -w $w --units-exponent 0 ".
           "DEF:dclients=cluster_clients.rrd:LAST ".
           "LINE1:dclients#0000FF:Clients ";
RRDp::cmd $rrd_cmd;

So, I'm creating the rrd as a GAUGE so it should store the real number
not the rate between it and the last value. With a step of 5 minutes and
heartbeat of 10 minutes. In the RRA I am storing the LAST value again
this should preserve the real value. I keep these real values for one
days worth of data.
The graphs are drawn with the string produces as above. Where:
$graph_step holds the value of seconds to be taken off the time NOW and
is calculated at run time, as are the height and width of the graphs


More information about the rrd-users mailing list