NRPE: Command 'check_ping' not defined

An open discussion forum for obtaining help with Nagios Core. Nagios Core users of all experience levels are welcome here. Subforum have been created for the discussion of Nagios Core and Nagios Plugin development.

NOTE: The SourceForge.net mailing lists have been deprecated in favor of this forum in order to expedite support and provide additional features not available on the old mailing list.

NRPE: Command 'check_ping' not defined

Postby hema12 » Fri May 11, 2018 1:25 am

I am very new to nagios.

Can some one please help me to fix this issue.
I want to check remote client status like disk check, Cpu usage,Memory,ping etc.

Code: Select all
NRPE: Command 'check_ping' not defined
hema12
 
Posts: 5
Joined: Wed May 09, 2018 8:29 am

Re: NRPE: Command 'check_ping' not defined

Postby npolovenko » Fri May 11, 2018 12:05 pm

Hello, @hema12. Where are you seeing this error? Can you provide a screenshot? What tutorial did you use to install the nrpe?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
npolovenko
Support Tech
 
Posts: 1701
Joined: Mon May 15, 2017 5:00 pm

Re: NRPE: Command 'check_ping' not defined

Postby hema12 » Sun May 13, 2018 11:28 am

@ npolovenko Thank you for your reply...

In my nagios server localhost.cfg

Code: Select all
define host {
        use                             linux-server
        host_name                  apache
        alias                           apache_test
        address                         Ip address
        max_check_attempts              5
        check_period                    24x7
        notification_interval           30
        notification_period             24x7
}

define service{
        use                             local-service         ; Name of service template to use
        host_name                       apache
        service_description             PING
        check_command                   check_ping!100.0,20%!500.0,60%
        }





In remote nrpe.cfg

tried

1: command[check_ping]=/usr/local/nagios/libexec/check_ping -H $ARG1$ -w $ARG2$ -c $ARG3$ -p 5

2: command[check_ping]=/usr/local/nagios/libexec/check_ping -H ipaddress -w 100.0,20% -c 500.0,60% this is working from remote terminal


Where am i missing, please help I am very new to nagios.
hema12
 
Posts: 5
Joined: Wed May 09, 2018 8:29 am

Re: NRPE: Command 'check_ping' not defined

Postby npolovenko » Mon May 14, 2018 4:46 pm

@hema12, Check ping doesn't require the nrpe to run. You need to make sure that you have the check_nrpe command defined on the nagios server.
So add the following command to /etc/usr/local/nagios/etc/commands.cfg

Code: Select all
define command {
       command_name                             check_ping
       command_line                             $USER1$/check_ping -H $HOSTADDRESS$ -w $ARG1$ -c $ARG2$ -p 5
}


And then restart the nagios process with:
Code: Select all
service nagios restart
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
npolovenko
Support Tech
 
Posts: 1701
Joined: Mon May 15, 2017 5:00 pm


Return to Nagios Core

Who is online

Users browsing this forum: No registered users and 34 guests