[rrd-users] Re: RRD Newbie Help

Alex van den Bogaerdt alex at ergens.op.het.net
Wed Dec 17 10:20:21 MET 2003

On Tue, Dec 16, 2003 at 04:56:44PM -0700, Sturgis, Grant wrote:
> Greetings all,
> I admit I am an RRD newbie, but I have read all the tutorials and manuals and have tried several times to get this right.  I think I need a little nudge in the right direction, and I hope someone here can help.  
> My goal is a spam / email graph.  I am getting the numbers everyday of how many emails are blocked by all the different methods we use to block spam, plus the legitimate email.  I have created a simplistic prototype:
> rrdtool create mail.rrd -b 1063677780 \
> --step 86400 \

This combination makes no sense.  RRDtool works with timestamps
that are a multiple of the step size.  Your step size is 86400
so the beginning of the database MUST be at n*86400.

> DS:tot_mail:ABSOLUTE:129600:U:U \
> DS:legit_mail:ABSOLUTE:129600:U:U \

A number of emails, divided by an amount of time.  You will have
to start counting from zero.

> RRA:AVERAGE:0.5:1:30 \
> RRA:AVERAGE:0.5:7:52

30 rows in the database, each one 86400 seconds.
52 rows in the database, each one 7*86400 seconds.

NOTE: this is NOT midnight to midnight.

> rrdtool update mail.rrd \
> -t tot_mail:legit_mail \
> 1063793700:2632:1749

1063793700 != n*86400

> rrdtool update mail.rrd \
> -t tot_mail:legit_mail \
> 1063880100:2949:1769

1063880100 != n*86400

> I do not want averages, I want real numbers.  I thought I was going to get real numbers because of the RRA:AVERAGE:0.5:1:30.  What should I be doing differently?  Am I on the right path at all?

RRDtool will ALWAYS normalize the input.  You think you need a
resolution of 86400 seconds, I think you need a resolution of
3600 seconds (when you want to update at _your_ midnight).
Perhaps you need a resolution of 15 minutes; I cannot tell if
the timestamps you provided are wrong or not.

You are dividing the number of emails per day by the number of seconds
per day.  This will give you an average, a number of emails per second.
This is OK (in fact, this is the preferred way).  To retrieve a number
of emails per day, you will need to multiply by 86400 again.

To sum it all up:

(perhaps you need to change 3600 into 300)

step size 3600
heartbeat can stay at 129600
first RRA contains 30 rows of (86400/3600=)24 steps each
second RRA contains 52 rows of 7*(86400/3600=)24 steps each
each time you update, make sure the time is n*3600

This message was produced without any <iframe tags

Unsubscribe mailto:rrd-users-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-users-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-users
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi

More information about the rrd-users mailing list