monitoring a 32bit linux host

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
MichielvM
Posts: 160
Joined: Thu Oct 24, 2013 3:48 am

monitoring a 32bit linux host

Post by MichielvM »

hi all,

I've run into an issue I'm not sure whether or not it should be posted here. But since most of my work up to this point was done on the command line, it rules out Xi IMHO.
The issue is this:

A customer requested 3 new linux servers to be monitored, 2 of them running 64 bit Centos 6.5 and 1 running 32 bit RHEL5. The application on it can not handle 64bit architecture in case anyone asks.
I managed to to get the first 2 running using NRPE.

We could not find any well documented 32bit version of NRPE, so we decided to use SSH (also because one of my colleagues had walked that road before)
To make a long story short: We almost have it working, exchanged rsa keys between nagios and host, copied the plugins to /usr/local/nagios/libexec etc. etc.. But I seem to need a 32bit version of the scripts/plugins.

Code: Select all

[root@nagios01 ~]# /usr/local/nagios/libexec/check_by_ssh -H <ipaddress> -C "/usr/local/nagios/libexec/check_load -w 5,5,5 -c 10,10,10"
output:

Code: Select all

Remote command execution failed: bash: /usr/local/nagios/libexec/check_load: cannot execute binary file
According to google resources that means that I'm trying to run 64 bit scripts on a 32 bit OS.
I'm sure that's correct, but I can't find any....

Thanks in advance.
Michiel
User avatar
eloyd
Cool Title Here
Posts: 2190
Joined: Thu Sep 27, 2012 9:14 am
Location: Rochester, NY
Contact:

Re: monitoring a 32bit linux host

Post by eloyd »

You need to compile the plugins on the 32-bit remote host.
Last edited by eloyd on Wed Jul 02, 2014 6:45 am, edited 1 time in total.
Image
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoyd
I'm a Nagios Fanatic! • Join our public Nagios Discord Server!
MichielvM
Posts: 160
Joined: Thu Oct 24, 2013 3:48 am

Re: monitoring a 32bit linux host

Post by MichielvM »

OK, thanks.
Is there any good documentation on how to do that?
I hail from Microsoft surroundings. Have been scratching the linux surface for some years, but only just began to dive deeper..
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: monitoring a 32bit linux host

Post by Box293 »

Here are some instructions for installing NRPE (document is aimed at Nagios XI users but should also work fine for core).
http://assets.nagios.com/downloads/nagi ... _Agent.pdf
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
MichielvM
Posts: 160
Joined: Thu Oct 24, 2013 3:48 am

Re: monitoring a 32bit linux host

Post by MichielvM »

We managed to get it working using snmp.

We we're a bit surprised that things are pretty standard as long as you're using 64bit OS, but not for 32bit.
Is there a reason for that?
I know that 32bit has been passed over by 64. But nagios has been around for a few years.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: monitoring a 32bit linux host

Post by scottwilkerson »

The plugins work on either but need to be compiled on the machine you are using, not transferred between architectures.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
User avatar
eloyd
Cool Title Here
Posts: 2190
Joined: Thu Sep 27, 2012 9:14 am
Location: Rochester, NY
Contact:

Re: monitoring a 32bit linux host

Post by eloyd »

This is the same reason your Windows machine has a "Program Files" and a "Program Files(x86)" directory. Different libraries need to be linked to the final executable based on what length registers (32 versus 64 bit) are used in the code. This is not a Nagios issue, it is a system architecture issue that basically has no solution.

The same problem existed when 8-bit computers became 16 and 16-bit computers became 32.
Image
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoyd
I'm a Nagios Fanatic! • Join our public Nagios Discord Server!
Locked