Linux.com

Home Linux Community Forums Software Installation nagiosgraph 1.4.3 help...

nagiosgraph 1.4.3 help...

Link to this post 15 Nov 10

hi, i've recently downloaded and installed nagiosgraph 1.4.3 on my linux box. after the installation i noticed the ff:

1. perfdata.log gets deleted after manually running insert.pl
2. rrd files doesn't get updated
3. there is an error in the nagiosgraph.log saying that perfdata.log is empty (but i've checked it before running insert.pl and it contains data)

also, i cannot see graphs. whenever i enter http://server/nagios/cgi-bin/show.cgi, chrome says that the link is broken.... can you give me some tip on how to make my nagiosgraph work? here are my config files:

nagios is installed on /etc/nagios3 (nagios v3)
nagiosgraph is on /etc/nagiosgraph (nagios v1.4.3)

*nagiosgraph.conf


perflog = /var/nagios/perfdata.log
rrddir = /var/nagios/rrd
logfile = /var/log/nagiosgraph.log
mapfile = /etc/nagiosgraph/map
nagiosgraphcgiurl = /nagiosgraph/cgi-bin
javascript = /nagiosgraph/nagiosgraph.js
stylesheet = /nagiosgraph/nagiosgraph.css
heartbeat = 600

*nagios.cfg


process_performance_data = 1
#service_perfdata_command = process-service-perfdata
service_perfdata_file = /var/nagios/perfdata.log
service_perfdata_file_template = $LASTSERVICECHECK$||$HOSTNAME$||$SERVICEDESC$||$SERVICEOUTPUT$||$SERVICEPERFDATA$
service_perfdata_file_mode = a
service_perfdata_file_processing_interval = 30
service_perfdata_file_processing_command = process-service-perfdata

* insert.pl


my $configfile = '/etc/nagiosgraph/nagiosgraph.conf'

* show.cgi


my $configfile = '/etc/nagiosgraph/nagiosgraph.conf'

* commands.cfg


# 'process-service-perfdata' command definition
define command{
command_name process-service-perfdata
command_line /usr/bin/perl /usr/local/nagios/libexec/insert.pl
}

* extinfo.cfg


define hostextinfo{
hostgroup_name debian-servers
notes Debian GNU/Linux servers
notes_url /nagiosgraph/show.cgi host=$HOSTNAME$&service=$SERVICEDESC$
icon_image graph.gif
icon_image_alt show graph
}

log file:

* nagiosgraph.log


Fri Nov 12 18:56:54 2010 insert.pl debug insert.pl processing started
Fri Nov 12 18:56:54 2010 insert.pl debug getrules(/etc/nagiosgraph/map)
Fri Nov 12 18:56:54 2010 insert.pl debug readperfdata: /var/nagios/perfdata.log
Fri Nov 12 18:56:54 2010 insert.pl info readperfdata: empty perflog /var/nagios/perfdata.log
Fri Nov 12 18:56:54 2010 insert.pl debug insert.pl processing complete
Fri Nov 12 18:57:24 2010 insert.pl debug insert.pl processing started
Fri Nov 12 18:57:24 2010 insert.pl debug getrules(/etc/nagiosgraph/map)
Fri Nov 12 18:57:24 2010 insert.pl debug readperfdata: /var/nagios/perfdata.log
Fri Nov 12 18:57:24 2010 insert.pl info readperfdata: empty perflog /var/nagios/perfdata.log
Fri Nov 12 18:57:24 2010 insert.pl debug insert.pl processing complete

/var/nagios/rrd, /var/log/nagiosgraph.log and /var/nagios/perfdata.log have proper permissions..


* script file: (apache2.conf)


ScriptAlias /cgi-bin/nagios3 /usr/lib/cgi-bin/nagios3
ScriptAlias /nagios3/cgi-bin /usr/lib/cgi-bin/nagios3
ScriptAlias /nagiosgraph/cgi-bin /usr/lib/cgi-bin/nagiosgraph


Alias /nagios3/stylesheets /etc/nagios3/stylesheets
Alias /nagiosgraph/nagiosgraph.css /etc/nagios3/stylesheets
Alias /nagios3 /usr/share/nagios3/htdocs

<DirectoryMatch (/usr/share/nagios3/htdocs|/usr/lib/cgi-bin/nagios3)>
Options FollowSymLinks
DirectoryIndex index.html

AllowOverride AuthConfig
Order Allow,Deny
Allow From All

AuthName "Nagios Access"
AuthType Basic
AuthUserFile /etc/nagios3/htpasswd.users
require valid-user
</DirectoryMatch>

# nagiosgraph
<Directory "usr/lib/cgi-bin/nagiosgraph">
Options ExecCGI
AllowOverride None
Order Allow,Deny
Allow from All
</Directory>


any help would be appreciated. thanks!

Who we are ?

The Linux Foundation is a non-profit consortium dedicated to the growth of Linux.

More About the foundation...

Frequent Questions

Join / Linux Training / Board