Trouble Creating a Graph Legend

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Trouble Creating a Graph Legend

Stephen R Guglielmo
Hi all,

I have been setting up a rrd to record and graph some data. I am
having some trouble creating the labels/legend at the bottom of the

I have a PNG image attached which shows my graph output. As you can
see, it doesn't look very nice. My rrd graph command is below.

Any advice or tips on how to create nicer looking "columns" in the
text below the graph would be appreciated. I've been playing with
various TEXTALIGN and COMMENT entries but have been unable to make it
look nicer. I'm not sure what I'm missing.

Thank you!

/usr/bin/rrdtool graph test.png \
--title 'app1 Sites, 1 Month' \
--vertical-label 'Number of Sites' \
--width '800' \
--height '300' \
--start end-1m \
DEF:SitesLast=/home/steve/rrd/sites-np.rrd:Sites:LAST \
DEF:DelSitesLast=/home/steve/rrd/sites-np.rrd:DeletedSites:LAST \
DEF:OutSitesLast=/home/steve/rrd/sites-np.rrd:OutdatedSites:LAST \
VDEF:SitesMin=SitesLast,MINIMUM \
VDEF:SitesMax=SitesLast,MAXIMUM \
VDEF:SitesAvg=SitesLast,AVERAGE \
VDEF:DelMin=DelSitesLast,MINIMUM \
VDEF:DelMax=DelSitesLast,MAXIMUM \
VDEF:DelAvg=DelSitesLast,AVERAGE \
VDEF:OutMin=OutSitesLast,MINIMUM \
VDEF:OutMax=OutSitesLast,MAXIMUM \
VDEF:OutAvg=OutSitesLast,AVERAGE \
LINE2:SitesLast#00FF00:'Total Sites' \
LINE2:DelSitesLast#FF0000:'Sites Marked Deleted' \
LINE2:OutSitesLast#FFA500:'Outdated Sites (>=2 years)' \
"COMMENT: \n" \
"COMMENT: \n" \
"COMMENT: \n" \
GPRINT:SitesMin:"Sites Min\: %.0lf" \
GPRINT:DelMin:"Deleted Min\: %.0lf" \
GPRINT:OutMin:"Outdated Min\: %.0lf" \
TEXTALIGN:center \
GPRINT:SitesMax:"Sites Max\: %.0lf" \
GPRINT:DelMax:"Deleted Max\: %.0lf" \
GPRINT:OutMax:"Outdated Max\: %.0lf" \
GPRINT:SitesAvg:"Sites Avg\: %.1lf" \
GPRINT:DelAvg:"Deleted Avg\: %.1lf" \
GPRINT:OutAvg:"Outdated Avg\: %.1lf"

rrd-users mailing list
[hidden email]

test.png (36K) Download Attachment