change the default check from ping to something else

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.

change the default check from ping to something else

Postby aristosv » Mon Apr 16, 2018 3:23 am

This is the host definition for one of the servers I want to monitor.

Code: Select all
define host {
   use linux-server
   host_name srv001
   address 192.168.15.53
   hostgroups hostgroup1
   }

define service {
   use generic-service
   host_name srv001
   service_description process
   check_command check_remote_process
   }


Under Current Status > Services, I can see that the "check_remote_process" check for this host working just fine.
But under Current Status > Hosts, the default check is ping, and this server is configured NOT to reply to pings.

How/where do I change the default check for this server to something else, besides ping? Is there an option to change this for all the servers using a universal setting, so I don't have to make a change on all the hosts definitions?

Thanks
aristosv
 
Posts: 9
Joined: Wed Apr 11, 2018 12:48 am

Re: change the default check from ping to something else

Postby scottwilkerson » Mon Apr 16, 2018 7:30 am

being there isn't a check_command specified it must be specified in the template
this is a template
Code: Select all
use linux-server


And that definition could contain other templates.
BUt to override it you can add the command right to the host
Code: Select all
check_command     your_other_check
User avatar
scottwilkerson
CTO
 
Posts: 8931
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises

Re: change the default check from ping to something else

Postby aristosv » Mon Apr 16, 2018 10:36 am

thanks, that did it.
aristosv
 
Posts: 9
Joined: Wed Apr 11, 2018 12:48 am

Re: change the default check from ping to something else

Postby scottwilkerson » Mon Apr 16, 2018 10:40 am

Great. Locking thread.
User avatar
scottwilkerson
CTO
 
Posts: 8931
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises


Return to Nagios Core

Who is online

Users browsing this forum: No registered users and 6 guests