Thanks for your links tgriep, they are very useful.
Using verify_pnp_config.pl I got a lot of red [CRIT] messages, fixed them almost all, ended up with this one only: [CRIT] Directory /usr/local/pnp4nagios/etc/config.php does not exist.
But I can see that directory and file exist.
Please see my output of verify_pnp_config.pl and ls commands:
***
[root@my-host-name snmp]# perl /root/verify_pnp_config --mode=bulk+npcd --config=/usr/local/nagios/etc/nagios.cfg --pnpcfg=/usr/local/pnp4nagios/etc/config.php
Code: Select all
[INFO] ========== Starting Environment Checks ============
[INFO] My version is: verify_pnp_config-0.6.25-R.40
[INFO] Start Options: /root/verify_pnp_config --mode=bulk+npcd --config=/usr/local/nagios/etc/nagios.cfg --pnpcfg=/usr/local/pnp4nagios/etc/config.php
[INFO] Reading /usr/local/nagios/etc/nagios.cfg
[OK ] Running product is 'nagios'
[OK ] object_cache_file is defined
[OK ] object_cache_file=/usr/local/nagios/var/objects.cache
[INFO] Reading /usr/local/nagios/var/objects.cache
[OK ] resource_file is defined
[OK ] resource_file=/usr/local/nagios/etc/resource.cfg
[INFO] Reading /usr/local/nagios/etc/resource.cfg
[CRIT] Directory /usr/local/pnp4nagios/etc/config.php does not exist
[root@my-host-name snmp]# ls -l /usr/local/pnp4nagios/etc/
total 160
Code: Select all
-rw-r--r-- 1 nagios nagios 29383 Vel 19 2013 background.pdf
drwxr-xr-x 2 nagios nagios 4096 Vel 19 2013 check_commands
drwxr-xr-x 2 nagios nagios 4096 Vel 19 2013 config.d
-rw-r--r-- 1 nagios nagios 9606 Vel 19 2013 config_local.php
-rw-r--r-- 1 nagios nagios 9606 Vel 19 2013 config.php
-rw-r--r-- 1 nagios nagios 9606 Vel 19 2013 config.php.0.6.19
-rw-r--r-- 1 nagios nagios 1358 Vel 19 2013 misccommands.cfg-sample
-rw-r--r-- 1 nagios nagios 1692 Vel 19 2013 nagios.cfg-sample
-rw-r--r-- 1 nagios nagios 4162 Vel 19 2013 npcd.cfg
drwxr-xr-x 2 nagios nagios 4096 Vel 19 2013 pages
-rw-r--r-- 1 nagios nagios 112 Vel 19 2013 pnp4nagios_release
-rw-r--r-- 1 nagios nagios 2520 Vel 19 2013 process_perfdata.cfg
-rw-r--r-- 1 nagios nagios 651 Vel 19 2013 rra.cfg-sample
Also I removed .rrd and .xml files for one interface at one switch (host) and there were no new .rrd and .xml files for that interface (If_GigabitEthernet1_0_9).
Clicking on graph icon for that interface (If_GigabitEthernet1_0_9) in nagios web interface I receive this:
***
PNP4Nagios Version 0.6.19
Please check the documentation for information about the following error.
XML file "/usr/local/pnp4nagios/var/perfdata/***host-name-of-the-switch***/If_GigabitEthernet1_0_9.xml" not found. Read FAQ online
file [line]:
application/models/data.php [312]:
back
***
According to "Performance data will be stored in Round Robin Databases using RRDtool." from
https://docs.pnp4nagios.org/pnp-0.6/about RRDtool is responsible for file creation on file system.
Does RRDtool create both .rrd and .xml files?
From this command below please see that I have rrdtool, php, and perl installed:
***
[root@my-host-name ~]# rpm -qa | egrep 'perl|rrdtool|php'
Code: Select all
perl-Convert-ASN1-0.22-1.el5.rf
perl-Archive-Tar-1.39.1-1.el5_5.2
perl-version-0.7203-1.el5
perl-MIME-Lite-3.028-1.el5.rf
perl-IO-Socket-INET6-2.57-2.el5.rf
perl-Date-Calc-5.4-1.2.2.1
perl-Mozilla-LDAP-1.5.2-4.el5
perl-Gearman-1.09-1.el5
perl-libwww-perl-5.805-1.1.1
perl-IP-Country-2.27-1.el5.rf
perl-Test-Pod-1.45-1.el5.rf
perl-Exception-Class-1.29-1.el5.rf
perl-Carp-Clan-5.3-1.2.1
perl-Encode-Detect-1.01-1.el5.rf
perl-XML-NamespaceSupport-1.11-1.el5.rf
perl-String-CRC32-1.4-2.fc6
perl-Razor-Agent-2.85-1.el5.rf
php-ldap-5.1.6-39.el5_8
perl-Crypt-OpenSSL-RSA-0.28-1.el5.rf
perl-Sort-Naturally-1.02-1.2.el5.rf
perl-IO-Compress-2.030-2.el5.rf
perl-HTML-Tagset-3.20-1.el5.rf
perl-XML-Twig-3.26-1.fc6
perl-Bit-Vector-6.4-2.2.2.1
perl-Crypt-DES-2.05-3.2.el5.rf
php-gd-5.1.6-39.el5_8
rrdtool-1.2.27-4.el5
perl-5.8.8-43.el5_11
perl-Compress-Raw-Bzip2-2.052-1.el5.rf
subversion-perl-1.6.11-10.el5_8
perl-Digest-HMAC-1.01-15
perl-DBI-1.615-1.el5.rf
perl-Crypt-OpenSSL-Bignum-0.04-7.el5
perl-Email-Date-Format-1.002-4.el5
perl-URI-1.35-3
perl-BSD-Resource-1.2903-1.el5.rf
perl-XML-Grove-0.46alpha-29.1.1
perl-Geography-Countries-2009041301-1.el5.rf
perl-Crypt-OpenSSL-Random-0.04-7.el5
perl-rrdtool-1.4.7-1.el5.rf
perl-Devel-StackTrace-1.2600-2.el5.rf
php-cli-5.1.6-39.el5_8
perl-Net-Telnet-3.03-5
mod_perl-2.0.4-6.el5
perl-IO-Zlib-1.10-1.el5.rf
perl-Test-Manifest-1.23-1.el5.rf
perl-Data-Dumper-2.125-1.el5.rf
perl-MailTools-2.09-1.el5.rf
net-snmp-perl-5.3.2.2-20.el5
perl-Net-SSLeay-1.36-1.el5.rf
perl-Crypt-PasswdMD5-1.3-2.el5
perl-XML-SAX-0.96-1.el5.rf
perl-Pod-Simple-3.16-1.el5.rf
newt-perl-1.08-9.2.2
perl-Config-General-2.44-1.el5.rf
perl-IO-Socket-SSL-1.34-1.el5.rf
perl-NetAddr-IP-4.044-1.el5.rf
rrdtool-1.4.7-1.el5.rf
perl-Compress-Raw-Zlib-2.052-1.el5.rf
perl-YAML-0.72-1.el5.rf
php-5.1.6-39.el5_8
perl-Socket6-0.23-1.el5.rf
perl-Net-Ident-1.23-1.el5.rf
perl-libxml-perl-0.08-1.2.1
perl-Mail-DKIM-0.39-1.el5.rf
perl-Git-1.7.11.3-1.el5.rf
perl-Class-Data-Inheritable-0.08-1.el5.rf
perl-Pod-Escapes-1.04-5.el5
perl-Archive-Zip-1.16-1.2.1
perl-Crypt-SSLeay-0.51-11.el5
php-common-5.1.6-39.el5_8
perl-Net-SNMP-5.2.0-1.2.el5.rf
perl-5.8.8-43.el5_11
perl-XML-Dumper-0.81-2.fc6
perl-XML-Parser-2.34-6.1.2.2.1
perl-Error-0.17010-1.el5
perl-Net-IP-1.25-2.fc6
perl-HTML-Parser-3.68-1.el5.rf
perl-Net-DNS-0.66-1.el5.rf
perl-Date-Manip-5.56-1.el5.rf
perl-Digest-SHA-5.71-1.el5.rf
perl-LDAP-0.33-4.el5_8
perl-Mail-SPF-2.007-1.el5
perl-Digest-SHA1-2.13-1.el5.rf
perl-XML-LibXML-1.69-3.el5.rf
perl-TimeDate-1.16-5.el5
perl-Crypt-Rijndael-1.09-1.el5.rf
Sorry for a long post.