I'm sure you're sick of all the 'broken graphs' threads, but please bear with me here
Brand new install, Ubuntu 9.04 Server. Cacti installed via apt-get.
Cacti 0.8.7b
RRDTool 1.3.1
From the moment Cacti was installed I've not had any graphs work in tree mode, they're always broken. However once I drill down to an individual graph, it works fine until I want to view between a specific time.
From what I can tell from this thread (which is bang on what my problem is) the graphs will only show when the graph_start and graph_end variables are absent from the image URL.
For example, /graph.php?action=properties&local_graph_id=1&rra_id=0&view_type=&graph_start=1245497796&graph_end=1245584196 will not work while /graph.php?action=properties&local_graph_id=1&rra_id=0&view_type= will.
The debug from the working URL above is...
Code: Select all
/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="Localhost - Memory Usage" \
--rigid \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="kilobytes" \
DEF:a="/var/lib/cacti/rra/localhost_mem_buffers_3.rrd":mem_buffers:AVERAGE \
DEF:b="/var/lib/cacti/rra/localhost_mem_buffers_3.rrd":mem_buffers:MAX \
DEF:c="/var/lib/cacti/rra/localhost_mem_swap_4.rrd":mem_swap:AVERAGE \
DEF:d="/var/lib/cacti/rra/localhost_mem_swap_4.rrd":mem_swap:MAX \
AREA:a#FF4105:"Free" \
GPRINT:a:LAST:"Current\:%8.2lf %s" \
GPRINT:a:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:b:MAX:"Maximum\:%8.2lf %s\n" \
STACK:c#FFC73B:"Swap" \
GPRINT:c:LAST:"Current\:%8.2lf %s" \
GPRINT:c:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:d:MAX:"Maximum\:%8.2lf %s"
Code: Select all
/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start=1245497796 \
--end=1245584196 \
--title="Localhost - Memory Usage" \
--rigid \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
COMMENT:"From 2009/06/20 21:36:36 To 2009/06/21 21:36:36\c" \
COMMENT:" \n" \
--vertical-label="kilobytes" \
DEF:a="/var/lib/cacti/rra/localhost_mem_buffers_3.rrd":mem_buffers:AVERAGE \
DEF:b="/var/lib/cacti/rra/localhost_mem_buffers_3.rrd":mem_buffers:MAX \
DEF:c="/var/lib/cacti/rra/localhost_mem_swap_4.rrd":mem_swap:AVERAGE \
DEF:d="/var/lib/cacti/rra/localhost_mem_swap_4.rrd":mem_swap:MAX \
AREA:a#FF4105:"Free" \
GPRINT:a:LAST:"Current\:%8.2lf %s" \
GPRINT:a:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:b:MAX:"Maximum\:%8.2lf %s\n" \
STACK:c#FFC73B:"Swap" \
GPRINT:c:LAST:"Current\:%8.2lf %s" \
GPRINT:c:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:d:MAX:"Maximum\:%8.2lf %s"
Regards,
Michael.