[rrd-users] Re: newbie to rrdtool ...need help
Alex van den Bogaerdt
alex at ergens.op.het.net
Thu May 27 22:39:29 MEST 2004
On Thu, May 27, 2004 at 02:47:45PM +0000, Arnar Thorarinsson wrote:
> Hello
[snip - counting flights through airspace]
[snip - DS type ABSOLUTE]
> Enter some data:
> /usr/bin/rrdtool update /tmp/traffic.rrd 1083373200:8:8:0
> /usr/bin/rrdtool update /tmp/traffic.rrd 1083376800:4:3:1
four flights in the last (1083376800-1083373200) 3600 seconds.
> /usr/bin/rrdtool update /tmp/traffic.rrd 1083380400:14:14:0
fourteen flights in the last (1083380400-1083376800=) 3600 seconds
[and so on]
Sounds reasonable.
> and create the graph:
> /usr/bin/rrdtool graph /tmp/traffic.gif \
> --start 1083369600 \
> --end 1083452400 \
> --title="FDPS Traffic" \
> --vertical-label="Flights per hour" \
> -h 400 \
> -w 800 \
> --step 3600 \
> --no-minor \
> DEF:mytraffic1=traffic.rrd:Total:AVERAGE \
> DEF:mytraffic2=traffic.rrd:East:AVERAGE \
> DEF:mytraffic3=traffic.rrd:West:AVERAGE \
> AREA:mytraffic1#708090:"Total" \
> LINE3:mytraffic2#FF0000:"East" \
> LINE3:mytraffic3#0000FF:"West"
This will graph flights per second. RRDtool keeps <something> per second.
If you want <per hour>, you need to multiply your rates by 3600.
> Ok this work fine but the problem is that the X-scale of off both its
> value and the unit.
You probably ment to say Y-axis, right? Try the following modifications:
1: between your last DEF and AREA, insert the following:
CDEF:traffic1=mytraffic1,3600,*
CDEF:traffic2=mytraffic2,3600,*
CDEF:traffic3=mytraffic3,3600,*
2: Loose the "my" from AREA and both LINE3s
HTH
Alex
--
I ask you to respect any "Reply-To" and "Mail-Follow-Up" headers. If
you reply to me off-list, you'd better tell me you're doing so. If
you don't, and if I reply to the list, that's your problem, not mine.
--
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