HP Insight Control for Linux 6.2 User Guide

“Running Nagios plug-ins manually” (page 239)
“Using the Nagios report generator analyze mode” (page 240)
“Messages reported by Nagios” (page 240)
A check_nrpe error occurs during management agents installation” (page 242)
“Nagios gather_all_data script reports check_nrpe errors ” (page 243)
“Troubleshooting Nagios problems” (page 243)
25.14.1 Determining the status of the Nagios service
Use the following command to determine if Nagios is running properly:
# /etc/init.d/nagios status
Nagios ok: located 1 process, status log updated 22 seconds ago
Gathering status for nrpe ... icelx<3-8>NRPE v2.0 - icelx<3-8>
Nagios nsca:
icelx7: 0 data packet(s) sent to host successfully.
icelx5: 0 data packet(s) sent to host successfully.
icelx6: 0 data packet(s) sent to host successfully.
25.14.2 Examining Nagios log files
Examine the following log files to obtain information on Nagios operation:
For errors: the /opt/hptc/nagios/var/nagios.log file
For system status: the /opt/hptc/nagios/var/status.log file
For Nagios errors: the /var/log/messages file
25.14.3 Running Nagios plug-ins manually
The Nagios plug-ins are located in the /opt/hptc/nagios/libexec directory. You can run
them from the command line if needed.
To run the Nagios check_sel plug-in from the command line, follow these steps:
1. Log in as the nagios user.
2. Change to the following directory:
$ cd /opt/hptc/nagios/libexec
3. Locate the Nagios plug-in you want to run, for example:
$ ls *_sel
4. Optionally, invoke the Nagios plug-in with the --help option:
$ ./check_sel --help
check_sel <--help> -H hostname <-t timeout>
--help
-H Host to check
--cache file Persistent cache to remember where we last read/processed
default /hptc_cluster/adm/logs/sel/cache/selcache-$nodename.db
--clear Clear the SEL log after reading
--clearifused n Clear the log only if it is past n% full
--ignoreunknownhosts
Ignore unknown hosts, default is to return critical
--last n<dhm> Only log entries from the last n days, hours, or minutes
--logfile file Log output to file,
default /hptc_cluster/adm/logs/sel/sel-{host}.log
--rules file File containing rule patterns, default /opt/hptc/nagios/etc/selRules
--cp cptype Console type string
5. Run the Nagios plug-in:
$ ./check_sel -H icelx7
No new entries in event log
$
25.14 Nagios Troubleshooting 239