Page 1 of 1

(Return code of 255 is out of bounds) troubleshooting sequnc

Posted: Mon Nov 21, 2016 3:32 pm
by dlukinski
Hello NAGIOS Support

Please help with (Return code of 255 is out of bounds NRPE/Liunux client issues) troubleshooting sequence.
- Installed correctly
- iptables off
- xinet.d has XI IPs
- we can execute NRPE plugins locally

Can't seem to find what is wrong.

Thank you

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Mon Nov 21, 2016 4:54 pm
by mcapra
What OS is the remote machine using?

Which version of NRPE are you using?

Can you share the contents of the machine's /usr/local/nagios/etc/nrpe.cfg file?

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Mon Nov 21, 2016 5:03 pm
by rkennedy
In addition to what @mcapra mentioned, usually this is due to permissions of some sort.
we can execute NRPE plugins locally
Are you executing as the same user which NRPE is running as?

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Tue Nov 22, 2016 1:39 pm
by dlukinski
rkennedy wrote:In addition to what @mcapra mentioned, usually this is due to permissions of some sort.
we can execute NRPE plugins locally
Are you executing as the same user which NRPE is running as?
Hi

su nagios,
RedHat 6.4
2.15 (latest Linux agent from downloads)

nrpe.cfg attached

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Tue Nov 22, 2016 3:10 pm
by rkennedy
What command are you attempting to execute through NRPE? Please show us the full input / output, ran as the nagios user.

There aren't any custom commands defined, so that'll help us understand what's going on exactly.

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Tue Nov 22, 2016 3:27 pm
by dlukinski
rkennedy wrote:What command are you attempting to execute through NRPE? Please show us the full input / output, ran as the nagios user.

There aren't any custom commands defined, so that'll help us understand what's going on exactly.
Standard Wizard checks as attached.
IP is correct / iptables disabled.

There is 2nd node host (nfs02), which got NRPE installed same day and configured same way - it works.

We are really lost in what is going on

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Tue Nov 22, 2016 5:15 pm
by tgriep
Can you login to the remote server as root, run the following commands and post the output?

Code: Select all

netstat -an |grep 5666
netstat -a |grep nrpe
ps -ef --cols=300
cat /etc/xinetd.d/nrpe
ls -l /usr/local/nagios/libexec
Thanks

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Wed Nov 23, 2016 8:16 am
by dlukinski
tgriep wrote:Can you login to the remote server as root, run the following commands and post the output?

Code: Select all

netstat -an |grep 5666
netstat -a |grep nrpe
ps -ef --cols=300
cat /etc/xinetd.d/nrpe
ls -l /usr/local/nagios/libexec
Thanks
Hello

Output attached

Thank you

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Wed Nov 23, 2016 9:59 am
by tgriep
Thanks for the file. The output of the netstat commands are not showing that xinetd is starting the NRPE agent so that is causing the issue.
Login to the remote server and run the following to restart xinetd

Code: Select all

service xinetd restart
This should reload the config files and allow the NRPE agent to run.
run this to verify that is it running

Code: Select all

netstat -an |grep 5666
You should see the output that looks similar to this.

Code: Select all

tcp        0      0 :::5666                     :::*                        LISTEN 
If you don't see that then you will have to look in the log files to see why it is not started.
Usually the log file is /var/log/messages

Re: (Return code of 255 is out of bounds) troubleshooting se

Posted: Wed Nov 23, 2016 12:04 pm
by dlukinski
tgriep wrote:Thanks for the file. The output of the netstat commands are not showing that xinetd is starting the NRPE agent so that is causing the issue.
Login to the remote server and run the following to restart xinetd

Code: Select all

service xinetd restart
This should reload the config files and allow the NRPE agent to run.
run this to verify that is it running

Code: Select all

netstat -an |grep 5666
You should see the output that looks similar to this.

Code: Select all

tcp        0      0 :::5666                     :::*                        LISTEN 
If you don't see that then you will have to look in the log files to see why it is not started.
Usually the log file is /var/log/messages
This worked, thank you
Please close the thread