Colour block on graph legend
Moderators: Developers, Moderators
Colour block on graph legend
Hi,
I have created a grapg template with a custom data query, that shows four different coloured lines on a graph. I have also created a legend showing min, ave and max values. The graph and legend work fine, but I cannot get the legend to show a little colour block t match the line. This is presnt in all the preconfigured graphs.
Any ideas???
I have created a grapg template with a custom data query, that shows four different coloured lines on a graph. I have also created a legend showing min, ave and max values. The graph and legend work fine, but I cannot get the legend to show a little colour block t match the line. This is presnt in all the preconfigured graphs.
Any ideas???
This is the out put of the debug, I have also attached svreenshots of the graph outputs. I have had to write the coulour in the legend to match the lines.
RRDTool Command:
/usr/local/rrdtool-1.0.49/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="STD_Channel_Utilization" \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="Utilization" \
DEF:a="/var/www/cacti-0.8.6h/rra/stdjhb_vmesh_carrier_1_705.rrd":Vmesh_Carrier_1:MAX \
DEF:b="/var/www/cacti-0.8.6h/rra/stdjhb_vmesh_carrier_2_706.rrd":Vmesh_Carrier_2:MAX \
DEF:c="/var/www/cacti-0.8.6h/rra/stdjhb_vmesh_carrier_3_707.rrd":Vmesh_Carrier_3:MAX \
DEF:d="/var/www/cacti-0.8.6h/rra/stdjhb_vmesh_carrier_4_708.rrd":Vmesh_Carrier_4:MAX \
LINE1:a#00FF00:"" \
LINE1:b#0000FF:"" \
LINE1:c#F5F800:"" \
LINE1:d#FF0000:"" \
GPRINTMAX:"(Green) Ch1-510Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
GPRINTMAX:"(Blue) Ch2-1600Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
GPRINT:c:MAX:"(Yellow) Ch3-1970Kbs Max\:%8.2lf %s" \
GPRINT:c:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:c:MIN:"Min\:%8.2lf %s\n" \
GPRINT:d:MAX:"(Red) Ch4-530Kbs Max\:%8.2lf %s" \
GPRINT:d:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:d:MIN:"Min\:%8.2lf %s\n"
RRDTool Says:
OK
RRDTool Command:
/usr/local/rrdtool-1.0.49/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="STD_Channel_Utilization" \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="Utilization" \
DEF:a="/var/www/cacti-0.8.6h/rra/stdjhb_vmesh_carrier_1_705.rrd":Vmesh_Carrier_1:MAX \
DEF:b="/var/www/cacti-0.8.6h/rra/stdjhb_vmesh_carrier_2_706.rrd":Vmesh_Carrier_2:MAX \
DEF:c="/var/www/cacti-0.8.6h/rra/stdjhb_vmesh_carrier_3_707.rrd":Vmesh_Carrier_3:MAX \
DEF:d="/var/www/cacti-0.8.6h/rra/stdjhb_vmesh_carrier_4_708.rrd":Vmesh_Carrier_4:MAX \
LINE1:a#00FF00:"" \
LINE1:b#0000FF:"" \
LINE1:c#F5F800:"" \
LINE1:d#FF0000:"" \
GPRINTMAX:"(Green) Ch1-510Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
GPRINTMAX:"(Blue) Ch2-1600Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
GPRINT:c:MAX:"(Yellow) Ch3-1970Kbs Max\:%8.2lf %s" \
GPRINT:c:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:c:MIN:"Min\:%8.2lf %s\n" \
GPRINT:d:MAX:"(Red) Ch4-530Kbs Max\:%8.2lf %s" \
GPRINT:d:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:d:MIN:"Min\:%8.2lf %s\n"
RRDTool Says:
OK
- Attachments
-
- graph.GIF (98.71 KiB) Viewed 2377 times
-
- graph2.GIF (88.43 KiB) Viewed 2377 times
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
Please change the sequence of the Graph Items to read
ReinhardLINE1:a#00FF00:"" \
GPRINTMAX:"(Green) Ch1-510Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
LINE1:b#0000FF:"" \
GPRINTMAX:"(Blue) Ch2-1600Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
LINE1:c#F5F800:"" \
GPRINT:c:MAX:"(Yellow) Ch3-1970Kbs Max\:%8.2lf %s" \
GPRINT:c:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:c:MIN:"Min\:%8.2lf %s\n" \
LINE1:d#FF0000:"" \
GPRINT:d:MAX:"(Red) Ch4-530Kbs Max\:%8.2lf %s" \
GPRINT:d:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:d:MIN:"Min\:%8.2lf %s\n"
Hi,
Here it is..
Thanks
LINE1:a#00FF00:"" \
GPRINTMAX:"(Green) Ch1-510Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
LINE1:b#0000FF:"" \
GPRINTMAX:"(Blue) Ch2-1600Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
LINE1:c#F5F800:"" \
GPRINT:c:MAX:"(Yellow) Ch3-1970Kbs Max\:%8.2lf %s" \
GPRINT:c:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:c:MIN:"Min\:%8.2lf %s\n" \
LINE1:d#FF0000:"" \
GPRINT:d:MAX:"(Red) Ch4-530Kbs Max\:%8.2lf %s" \
GPRINT:d:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:d:MIN:"Min\:%8.2lf %s\n"
Here it is..
Thanks
LINE1:a#00FF00:"" \
GPRINTMAX:"(Green) Ch1-510Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
LINE1:b#0000FF:"" \
GPRINTMAX:"(Blue) Ch2-1600Kbs Max\:%8.2lf %s" \
GPRINTAVERAGE:"Average\:%8.2lf %s" \
GPRINTMIN:"Min\:%8.2lf %s\n" \
LINE1:c#F5F800:"" \
GPRINT:c:MAX:"(Yellow) Ch3-1970Kbs Max\:%8.2lf %s" \
GPRINT:c:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:c:MIN:"Min\:%8.2lf %s\n" \
LINE1:d#FF0000:"" \
GPRINT:d:MAX:"(Red) Ch4-530Kbs Max\:%8.2lf %s" \
GPRINT:d:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:d:MIN:"Min\:%8.2lf %s\n"
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
But you haven't got any texts on the LINE1 graph items
Reinhard
Edit the Graph Template. Then, please select the first Graph Item showing a LINE1. Provide a "Text Format". Repeat this for all LINE1 itemsgandalf wrote:... I suppose you will have to provide some text for those Graph Items providing the lines. ...
Reinhard
Who is online
Users browsing this forum: No registered users and 2 guests