nagios check_apt

 

Return code of 127 is out of bounds – plugin may be missing

captura-de-ecra%cc%83-2016-10-19-as-15-28-05

On the check_command, I had to prepend check_nrpe! since we are using the nrpe client on the server to read and return us the desired value.

No output returned from plugin

no_output_returned_from_plugin

On the check_command, I had to append, with for example !1, since we need to pass $$ARG1$$

NRPE: Command ‘check_apt’ not defined

captura-de-ecra%cc%83-2016-10-19-as-17-13-52

Check you /etc/nagios/nrpe.cfg you need to set it up there.

 

Well, I got it working!

On nagios nrpe server my /etc/nagios/nrpe.cfg I add the following line

command[check_apt]=/usr/lib/nagios/plugins/check_apt

Restart nagios-nrpe

service nagios-nrpe-server restart

 

On nagios server my /etc/nagios/hosts/s4.domain.com.cfg this is what I have

define service {
   use                     generic-service
   host_name               s4.domain.com
   service_description     SYS: system updates
   check_command           check_nrpe!check_apt!1
}

Restart nagios server

service nagios restart

Hooray!

captura-de-ecra%cc%83-2016-10-20-as-07-30-19

 

Leave a Reply

Your email address will not be published. Required fields are marked *


*