Hey, everyone,
I successfully installed Cacti on a FreeBSD server and everything appears to function properly. However, when I attempt to generate a graph, a broken image reference appears in the HTML and the log file notes the following:
ERROR: opening '/usr/local/share/cacti/rra/localhost_load_1min_5.rrd': No such file or directory
My guess is that this is a permissions issue and it can not write to this directory.
The directory permissions are as follows:
2 drwxr-xr-x 2 cacti www 512 Nov 18 13:31 .
2 drwxr-xr-x 11 root wheel 1536 Nov 18 13:32 ..
0 -rw-r--r-- 1 cacti www 0 Nov 7 10:13 .placeholder
Do I need to grant the group www write rights?
Finally, I updated the /etc/libmap.conf to ensure that rrdtool had the correct libraries and appropriate mappings. I doubt that's related but thought I'd mention it just in case.
Thanks,
Chris
Graphs not Generating- Possible Permissions Issue?
Moderators: Developers, Moderators
Manual Execution
I manually executed the rrdtool command using the web output.
/usr/local/bin/rrdtool graph - \
? --imgformat=PNG \
? --start=1132330235 \
? --end=1132416635 \
? --title="Localhost - Memory Usage" \
? --rigid \
? --base=1000 \
? --height=120 \
? --width=500 \
? --alt-autoscale-max \
? --lower-limit=0 \
? COMMENT:"From 2005/11/18 10\:10\:35 To 2005/11/19 10\:10\:35\c" \
? COMMENT:" \n" \
? --vertical-label="kilobytes" \
? --slope-mode \
? DEF:a="/usr/local/share/cacti/rra/localhost_mem_buffers_3.rrd":mem_buffers:AVERAGE \
? DEF:b="/usr/local/share/cacti/rra/localhost_mem_swap_4.rrd":mem_swap:AVERAGE \
? AREA:a#FF4105:"Free" \
GPRINTLAST:"Current\:%8.2lf %s" \
? GPRINTLAST:"Current\:%8.2lf %s" \
? GPRINTAVERAGE:"Average\:%8.2lf %s" \
? GPRINTMAX:"Maximum\:%8.2lf %s\n" \
? AREA:b#FFC73B:"Swap":STACK \
GPRINTLAST:"Current\:%8.2lf %s" \
? GPRINTLAST:"Current\:%8.2lf %s" \
? GPRINTAVERAGE:"Average\:%8.2lf %s" \
? GPRINTMAX:"Maximum\:%8.2lf %s"
ERROR: opening '/usr/local/share/cacti/rra/localhost_mem_buffers_3.rrd': No such file or directory
At least my error messages are consistent. I've double checked my paths and the /usr/local/share/cacti/rra directory does exist. Any suggestions?
Thanks,
Chris
/usr/local/bin/rrdtool graph - \
? --imgformat=PNG \
? --start=1132330235 \
? --end=1132416635 \
? --title="Localhost - Memory Usage" \
? --rigid \
? --base=1000 \
? --height=120 \
? --width=500 \
? --alt-autoscale-max \
? --lower-limit=0 \
? COMMENT:"From 2005/11/18 10\:10\:35 To 2005/11/19 10\:10\:35\c" \
? COMMENT:" \n" \
? --vertical-label="kilobytes" \
? --slope-mode \
? DEF:a="/usr/local/share/cacti/rra/localhost_mem_buffers_3.rrd":mem_buffers:AVERAGE \
? DEF:b="/usr/local/share/cacti/rra/localhost_mem_swap_4.rrd":mem_swap:AVERAGE \
? AREA:a#FF4105:"Free" \
GPRINTLAST:"Current\:%8.2lf %s" \
? GPRINTLAST:"Current\:%8.2lf %s" \
? GPRINTAVERAGE:"Average\:%8.2lf %s" \
? GPRINTMAX:"Maximum\:%8.2lf %s\n" \
? AREA:b#FFC73B:"Swap":STACK \
GPRINTLAST:"Current\:%8.2lf %s" \
? GPRINTLAST:"Current\:%8.2lf %s" \
? GPRINTAVERAGE:"Average\:%8.2lf %s" \
? GPRINTMAX:"Maximum\:%8.2lf %s"
ERROR: opening '/usr/local/share/cacti/rra/localhost_mem_buffers_3.rrd': No such file or directory
At least my error messages are consistent. I've double checked my paths and the /usr/local/share/cacti/rra directory does exist. Any suggestions?
Thanks,
Chris
Success!
I love it when I solve my own problems. After multiple modifications to the /etc/libmap.conf file in FreeBSD, I noticed that the cron job indicated ambiguous output. So I modified the cron job to be:
php /usr/local/share/cacti/poller.php > /dev/null && 2>&1
instead of
php /usr/local/share/cacti/poller.php > /dev/null 2>&1
This resolved the problem and the graphs appeared. Thanks to everyone for their views!
php /usr/local/share/cacti/poller.php > /dev/null && 2>&1
instead of
php /usr/local/share/cacti/poller.php > /dev/null 2>&1
This resolved the problem and the graphs appeared. Thanks to everyone for their views!
Who is online
Users browsing this forum: No registered users and 7 guests