Recently my "Interface - Traffic" graph template has become incorrectly formatted, and no matter what I do to it I can't fix it. Maybe someone here can point me in the right direction.
I attach a few files, the first of which, graph.png, shows the problem. The "Outbound" legend item appears on the same line as the "Inbound" one, disregarding the order shown in the template. It also appears before the "Total In:" comment.
The second file, graph_template.png, shows the template.
The final information I can provide, is the rrdtool command. This clearly shows the error (the graph items are in the wrong order), but I don't know how to go about correcting it...
Code: Select all
/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="heb-cvs - Traffic - eth0" \
--rigid \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="bits per second" \
--slope-mode \
--font TITLE:12:/usr/share/fonts/bitstream-vera/VeraMono.ttf \
--font AXIS:7:/usr/share/fonts/bitstream-vera/VeraMono.ttf \
--font LEGEND:7:/usr/share/fonts/bitstream-vera/VeraMono.ttf \
--font UNIT:7:/usr/share/fonts/bitstream-vera/VeraMono.ttf \
DEF:a="/export/home/Admin/website/cgi-bin/cacti/rra/heb-cvs_traffic_in_2273.rrd":traffic_in:AVERAGE \
DEF:b="/export/home/Admin/website/cgi-bin/cacti/rra/heb-cvs_traffic_in_2273.rrd":traffic_in:LAST \
DEF:c="/export/home/Admin/website/cgi-bin/cacti/rra/heb-cvs_traffic_in_2273.rrd":traffic_in:MIN \
DEF:d="/export/home/Admin/website/cgi-bin/cacti/rra/heb-cvs_traffic_in_2273.rrd":traffic_in:MAX \
DEF:e="/export/home/Admin/website/cgi-bin/cacti/rra/heb-cvs_traffic_in_2273.rrd":traffic_out:AVERAGE \
DEF:f="/export/home/Admin/website/cgi-bin/cacti/rra/heb-cvs_traffic_in_2273.rrd":traffic_out:LAST \
DEF:g="/export/home/Admin/website/cgi-bin/cacti/rra/heb-cvs_traffic_in_2273.rrd":traffic_out:MIN \
DEF:h="/export/home/Admin/website/cgi-bin/cacti/rra/heb-cvs_traffic_in_2273.rrd":traffic_out:MAX \
CDEF:cdefa=a,8,* \
CDEF:cdefb=b,8,* \
CDEF:cdefd=d,8,* \
CDEF:cdefe=e,8,* \
CDEF:cdefg=f,8,* \
CDEF:cdefi=h,8,* \
AREA:cdefa#00CF00FF:"Inbound" \
GPRINT:cdefb:LAST:" Curr\:%8.2lf %s" \
GPRINT:cdefa:AVERAGE:"Avg\:%8.2lf %s" \
GPRINT:cdefd:MAX:"Max\:%8.2lf %s" \
LINE1:cdefe#002A97FF:"Outbound" \
COMMENT:"Total In\: 670.09 MB\n" \
GPRINT:cdefg:LAST:"Curr\:%8.2lf %s" \
GPRINT:cdefe:AVERAGE:"Avg\:%8.2lf %s" \
GPRINT:cdefi:MAX:"Max\:%8.2lf %s" \
COMMENT:"Total Out\: 11.3 GB"
John.