Sudden NRDS Error for new devices

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
derekb
Posts: 177
Joined: Wed Jun 10, 2015 1:54 pm

Sudden NRDS Error for new devices

Post by derekb »

Hi there,
I've been using NRDS quite a bit to setup remote agents to perform basic checks (check_ping etc) and report back to XI server. I tried to spin up a new Linux device following my normal process, and I've run into some issues.

In the NRDS Config in XI, I've set the following commands:

Code: Select all

command[__HOST__]=/usr/lib/nagios/plugins/check_ping -H localhost -w 200.0,40% -c 400.0,80% -p 1
command[ping ip phone]=/usr/lib/nagios/plugins/check_ping -H 192.168.1.189 -w 200.0,40% -c 400.0,80% -p 1
Plugin_Dir /usr/local/nagios/libexec
Send_Nrdp /usr/local/nrdp/clients/send_nrdp.sh
Tmpdir /usr/local/nrdp/clients/tmp
Update_Config Yes
Update_Plugins Yes

I installed the NRDS config via the install instructions in XI. This works no problem. I manually run the cron entry as follows:

Code: Select all

/usr/local/nrdp/clients/nrds/nrds.pl -H 'Derek Test'
Results in the following output:

Code: Select all

Can't exec "/usr/lib/nagios/plugins/check_ping/check_ping": No such file or directory at /usr/local/nrdp/clients/nrds/nrds.pl line 91, <CONFIG> line 18.
Can't exec "/usr/lib/nagios/plugins/check_ping/check_ping": No such file or directory at /usr/local/nrdp/clients/nrds/nrds.pl line 91, <CONFIG> line 18.
Sent 2 checks to http://nagios.mydomain.com/nrdp/
I've compared the NRDS Config commands to some working devices that I have setup, and the directory paths etc are the same. What am I missing here? I swear I've had this before.

Edit:
I have check_ping in /usr/local/nagios/libexec, but that doesn't work either...

Code: Select all

root@raspberrypi:/usr/local/nrdp/clients/nrds# /usr/local/nagios/libexec/check_ping -H 192.168.1.189 -w 200.0,40% -c 400.0,80% -p 1
bash: /usr/local/nagios/libexec/check_ping: cannot execute binary file: Exec format error
Edit2:
Found this in the Nagios KB, showing "this is a failed execution", but no help to resolve :(
https://support.nagios.com/kb/article.php?id=500
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Sudden NRDS Error for new devices

Post by Box293 »

derekb wrote:I have check_ping in /usr/local/nagios/libexec, but that doesn't work either...

Code: Select all

root@raspberrypi:/usr/local/nrdp/clients/nrds# /usr/local/nagios/libexec/check_ping -H 192.168.1.189 -w 200.0,40% -c 400.0,80% -p 1
bash: /usr/local/nagios/libexec/check_ping: cannot execute binary file: Exec format error
Is this new client a Raspberry Pi?

The pre-compiled binaries that exist on the Nagios XI server that are pulled down will not work on a Pi.
derekb wrote:Results in the following output:

Code: Select all

Can't exec "/usr/lib/nagios/plugins/check_ping/check_ping": No such file or directory at /usr/local/nrdp/clients/nrds/nrds.pl line 91, <CONFIG> line 18.
Can't exec "/usr/lib/nagios/plugins/check_ping/check_ping": No such file or directory at /usr/local/nrdp/clients/nrds/nrds.pl line 91, <CONFIG> line 18.
Sent 2 checks to http://nagios.mydomain.com/nrdp/
Does /usr/lib/nagios/plugins/check_ping/check_ping exist?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
derekb
Posts: 177
Joined: Wed Jun 10, 2015 1:54 pm

Re: Sudden NRDS Error for new devices

Post by derekb »

It's a new Pi. All of my devices running NRDS are Pi's, which is why I'm a bit shocked that this isn't working.

/usr/lib/nagios/plugins/check_ping/check_ping does NOT exist, which again, has never been an issues -- I haven't had to manually copy plugins over to the Pi when rolling out new devices. I did have a problem a while back where plugins were not copying over to the device and it turned out to be an NRDS/NRDP bug.

Where do you suggest I go from here, sir?
derekb
Posts: 177
Joined: Wed Jun 10, 2015 1:54 pm

Re: Sudden NRDS Error for new devices

Post by derekb »

Sorry for double-post. I totally forgot, with a new Pi I usually run a script I made that installs NRPE and nagios-plugins before I get around to installing NRDS.

apt-get install nagios-plugins seems to have fixed me up :]
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Sudden NRDS Error for new devices

Post by Box293 »

Sweet, sounds like you've got it sorted. Is it OK to lock this one?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
derekb
Posts: 177
Joined: Wed Jun 10, 2015 1:54 pm

Re: Sudden NRDS Error for new devices

Post by derekb »

Box293 wrote:Sweet, sounds like you've got it sorted. Is it OK to lock this one?
yup!
Locked