I have a big problem. I installed nrpe on the first server that i want to monitor and when i launch the command
check_nrpe -H xxx.xxx.xxx.xxx -c check_load it works (as root or nagios) but not in the interface and i received this error : (Return code of 127 is out of bounds - plugin may be missing)
Furthermore, since this problem, all my hosts check get the same error (33 servers). Before my servers got this error 1 on 2 host check … (That was already a problem).
/opt/nagios/libexec/check_nrpe -H xxx.xxx.xxx.xxx -c check_load
OK - load average: 0.27, 0.15, 0.11|load1=0.270;15.000;30.000;0; load5=0.150;10.000;25.000;0; load15=0.110;5.000;20.000;0;
On the Nagios Server :
my commands.cfg
…
…
define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$
}
my nagios.cfg has this entry so no problem.
cfg_file=/opt/nagios/etc/objects/services.cfg
My services.cfg :
define service{
use generic-service
hostgroup_name LINUX
service_description CPU Load
check_command check_nrpe!check_load
}
My resources.cfg :
Sets $USER1$ to be the path to the plugins
USER1$=/opt/nagios/libexec
Sets $USER2$ to be the path to event handlers
#$USER2$=/opt/nagios/libexec/eventhandlers
Store some usernames and passwords (hidden from the CGIs)
#$USER3$=someuser
#$USER4$=somepassword
Rights are good on and in libexec.
on the NRPE Server :
[root@ebitg11 nagios]# ll
total 16
drwxrwxr-x 2 nagios nagios 4096 Jan 26 12:02 bin
drwxrwxr-x 2 nagios nagios 4096 Jan 26 15:35 etc
drwxrwxr-x 2 nagios nagios 4096 Jan 26 10:49 libexec
drwxr-xr-x 3 root root 4096 Jan 26 10:49 share
[root@ebitg11 nagios]# ps -edf | grep nrpe
root 2770 19791 0 15:53 pts/1 00:00:00 grep nrpe
nagios 31451 1 0 15:36 ? 00:00:00 /opt/nagios/bin/nrpe -c /opt/nagios/etc/nrpe.cfg -d
[root@ebitg11 nagios]# netstat -at | grep nrpe
tcp 0 0 *:nrpe : LISTEN
[root@ebitg11 nagios]# grep allowed etc/nrpe.cfg
that are allowed to talk to the NRPE daemon.
allowed_hosts=xxx.xxx.xxx.xxx (address of the server)
Someone knows how to solve this problem ?