Page 1 of 1

AIX 7.2 NRPE support

Posted: Wed Jan 16, 2019 4:07 pm
by lee.krause
Is there an AIX 7.2 nrpe agent?

Re: AIX 7.2 NRPE support

Posted: Wed Jan 16, 2019 4:53 pm
by cdienger
We do not have packages available for AIX 7.1 / 7.2 but I do have a web site that you can download them from.
The site is called http://www.perzl.org/aix/

The links below are direct links to the files you need to download to the AIX server.

ftp://www.oss4aix.org/latest/aix71/fpin ... .3.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/gawk ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/net- ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/net- ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/net- ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/open ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/open ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/pyth ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/libd ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/nagi ... .1.ppc.rpm
ftp://www.oss4aix.org/latest/aix71/nagi ... .1.ppc.rpm


Put them all in one folder and run the following to install all of the packages.
rpm -Uvh *.rpm
The /etc/nagios/nrpe.conf needs to be changed a bit to get it to work so edit that file.
This option will have to be set to 1 to allow the NRPE agent to accept arguments.
dont_blame_nrpe=1

Change this from
pid_file=/var/run/nagios-nrpe/nrpe.pid
to
pid_file=/var/run/nrpe/nrpe.pid

to match the pid file in the init script.

Save the changes and restart the NRPE service.


If you want to use arguments in the commands that you define in XI, you will also have to do the following changes in the /etc/nagios/nrpe.conf file.

Comment out the hard coded commands

Code: Select all

#command[check_users]=/opt/freeware/lib/nagios/plugins/check_users -w 5 -c 10
#command[check_load]=/opt/freeware/lib/nagios/plugins/check_load -r -w .15,.10,.05 -c .30,.25,.20
#command[check_hda1]=/opt/freeware/lib/nagios/plugins/check_disk -w 20% -c 10% -p /dev/hda1
#command[check_zombie_procs]=/opt/freeware/lib/nagios/plugins/check_procs -w 5 -c 10 -s Z
#command[check_total_procs]=/opt/freeware/lib/nagios/plugins/check_procs -w 150 -c 200

Uncomment these commands.

Code: Select all

command[check_users]=/opt/freeware/lib/nagios/plugins/check_users $ARG1$
command[check_load]=/opt/freeware/lib/nagios/plugins/check_load $ARG1$
command[check_disk]=/opt/freeware/lib/nagios/plugins/check_disk $ARG1$
command[check_swap]=/opt/freeware/lib/nagios/plugins/check_swap $ARG1$

### PROCESSES ###
command[check_all_procs]=/opt/freeware/lib/nagios/plugins/custom_check_procs
command[check_procs]=/opt/freeware/lib/nagios/plugins/check_procs $ARG1$

Change to the NRPE user by running this
sudo su - nrpe
Then to start the Agent, run this
/opt/freeware/sbin/nrpe -c /etc/nagios/nrpe.cfg -d


To test to see if the AIX server can be polled from the Nagios server, run the following command from the Nagios server (replace xxx.xxx.xxx.xxx with the IP Addrerss on the AIX server)
/usr/local/nagios/libexec/check_nrpe -H xxx.xxx.xxx.xxx

If it returns the version number then you should be able to run the NRPE commands from the XI server.

Re: AIX 7.2 NRPE support

Posted: Thu Jan 24, 2019 9:22 am
by lee.krause
When I attempted to follow the steps that were suggested, there were several prerequisites for the packages. I will figure out how to install yum first.

Re: AIX 7.2 NRPE support

Posted: Thu Jan 24, 2019 3:01 pm
by cdienger
Thanks for the update. Please keep us posted if there is something we can assist with.

Re: AIX 7.2 NRPE support

Posted: Mon Jan 28, 2019 12:55 pm
by lee.krause
I'm getting the following error:

CHECK_NRPE: Receive header underflow - only 0 bytes received (4 expected).

Re: AIX 7.2 NRPE support

Posted: Mon Jan 28, 2019 3:24 pm
by cdienger
Check the version of check_nrpe found on the Nagios server:

/usr/local/nagios/libexec/check_nrpe -V

If it's version 2.x, then you'll need to add the -2option to the commands:

/usr/local/nagios/libexec/check_nrpe -H xxx.xxx.xxx.xxx -2

Re: AIX 7.2 NRPE support

Posted: Thu Jan 31, 2019 8:51 am
by lee.krause
-bash-4.1$ /usr/local/nagios/bin/nagios -V

Nagios Core 4.4.3

Re: AIX 7.2 NRPE support

Posted: Thu Jan 31, 2019 2:45 pm
by cdienger
What is the output of:

/usr/local/nagios/libexec/check_nrpe -V

?

Also, mistake on my part, the -2 option wouldn't be available if the plugin is at version 2. You'd need to upgrade the plugin.