[rrd-users] Units for the Y-axis labels?

Alex van den Bogaerdt alex at ergens.op.het.net
Fri Sep 7 23:04:49 CEST 2007

On Fri, Sep 07, 2007 at 07:11:02PM +0200, Paul Boven wrote:
> Hi everyone,
> When looking at RRDtool created graphs, e.g. in Cacti, there's always a
> bit of confusion - are these Gb/s or GB/s? I would like to propose an
> option to 'rrdtool graph' of specifying a unit string for the y-axis
> labels. Such a string would then be printed on the axis directly after
> the multiplier character (m,k,M,G etc). This would enable the y-axis
> label to show things like 'Gb/s' or 'kWh' or even degree Centigrade.
> The is a 'vertical label' option in rrdtool, but in my opinion, the
> proposal above makes it much easier to see 'at a glance' what a graph is
> showing.

What you are suggesting here seems quite redundant to me. You would
be displaying:

1.0GB ______
0.8GB ______
0.5GB ______
0.2GB ______
0.0GB ______

(where ____ is the grid line)

Why do I need to be reminded 5 times about "B", where one time
would suffice?  Is it really worth the graph space?

And what about using title?

"Throughput of device xyz in Bytes per second"

is much clearer I think.

> My suggestion: add an option '--unit <string>' that gets printed both on
>  the y-axis labels, and also on any GRPINT calculated results (e.g.
> current/avg/max throughput).

GPRINT:somevar:"%6.2lf%sBps" will already show "10.12GBps". And I can
leave it out if I so desire.

What about the outcome of a CDEF, where I modify e.g. "B" in "b" by
multiplying by 8?  " 10.12GBps  80.96Gbps " would be impossible.

_if_ something is added to rrdtool, I would suggest that it is not
a combination of these two suggestions.  And therefore I would also
suggest another name, or even enhance --y-grid:

--y-units Bps

--y-axis 1000000:10:Bps

> If such an enhancement to RRDtool would be of interest, I will also
> volunteer to write it.

It probably wouldn't be much effort.  You may even want to do it
as an excercise for yourself, and keep it around as a local patch.

my 2c
Alex van den Bogaerdt

More information about the rrd-users mailing list