LPAR2RRD Nagios plug-in
LPAR2RRD can be integrated with Nagios monitoring via standard nrpe plug-in.
How it works?
You have to configure LPAR2RRD alerting. Once LPAR2RRD issues an alarm then it is kept into separate directory which is being regularly checked via Nagios nrpe. When appears there a file with an alarm then it is picked up to Nagios and an alarm is raised in Nagios.
Nagios has to be configured to pick up alarms of particular servers and their pools or lpars. Each server and pool or lpar must have separated configuration in Nagios server to be able to distinguish between them and to be able to sort alarms and their related services in Nagios UI.
Installation
-
Configure standard LPAR2RRD alerting, here is description: alerting install
-
Enable Nagios support in lpar2rrd.cfg in etc/alert.cfg
NAGIOS=1
-
Install Nagios NRPE modul on LPAR2RRD servers. It must be compiled with option "--enable-command-args". Note this is not the default option!
You might download nrpe 2.13 from www.lpar2rrd.com AIX binnary compiled with this option
-
Change this in nrpe.cfg to allow argument passing:
dont_blame_nrpe=1
-
Let use LPAR2RRD script for picking up alerts via nrpe. Add to nrpe.cfg:
command[lpar2rrd]=/home/lpar2rrd/lpar2rrd/bin/check_lpar2rrd $ARG1$ $ARG2$ $ARG3
-
Restart nrpe and test whether it works:
$ /opt/nagios/bin/check_nrpe -H localhost -c lpar2rrd -a LPAR p710 nim
OK
No matter about 3 parameters at the end, place there whatever, it should return always "ok". When not then most probably nrpe does not have argument support enabled or is not compiled with that option.
-
Nagios server configuration example of 3 configured alerts:
# LPAR2RRD
define service { # LPAR named nim on server p710
use generic-service
host_name lpar2rrd-host
service_description lpar2rrd-nim-CPU-LPAR
check_command check_lpar2rrd!lpar2rrd!LPAR!p710!nim
}
define service { # CPU pool named demo on server p710
use generic-service
host_name lpar2rrd-host
service_description lpar2rrd-demo-CPU-POOL
check_command check_lpar2rrd!lpar2rrd!POOL!p710!demo
}
define service { # CPU pool on server p710
use generic-service
host_name lpar2rrd-host
service_description lpar2rrd-nim-pool-CPU
check_command check_lpar2rrd!lpar2rrd!POOL!p710!all_pools
}
define command{
command_name check_lpar2rrd
command_line /opt/nagios/bin/check_nrpe -H $HOSTADDRESS$ -c lpar2rrd -a $ARG2$ $ARG3$ $ARG4$
}
Note that naturally same alerts must be defined in LPAR2RRD alerting (alert.cfg)
-
Restart Nagios server
You can even find the same module on
Nagios Exchange