LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (http://www.linuxquestions.org/questions/linux-server-73/)
-   -   multipe nrpe commands in nagios (http://www.linuxquestions.org/questions/linux-server-73/multipe-nrpe-commands-in-nagios-4175437738/)

divyashree 11-18-2012 09:17 PM

multipe nrpe commands in nagios
 
I have configured nrpe in 2 linux hosts. One is configured with SSL Handshake enabled and another is with SSL disabled.

Now in my server commands.cfg is configured like this which by default use SSL handshake, but for which ssl is disable one extra agument is requied (-n) with check_nrpe command i.e.

Code:

command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -n -c $ARG1$
Code:

define command{
        command_name check_nrpe
        command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$
        }

How will I add both types of nrpe commands in commands.cfg for different hosts.
I added both in different lines and it throws error;
Code:

CHECK_NRPE: Error receiving data from daemon.

divyashree 11-18-2012 10:26 PM

In command line manually running nrpe commands for both remote hosts is working fine from nagios server.

divyashree 11-18-2012 11:09 PM

Yes, I did it using on-demand macros in commands.cfg.


All times are GMT -5. The time now is 01:24 AM.