################################################################################
# Sample object config file for Nagios 
#
# Read the documentation for more information on this configuration file.  I've
# provided some comments here, but things may not be so clear without further
# explanation, so make sure to read the HTML documentation!
# 
# Last Modified: 12-15-2005
#
################################################################################


################################################################################
# COMMAND DEFINITIONS
#
# SYNTAX:
#
#	define command{
#               template      <templatename>
#		name          <objectname>
#               command_name  <commandname>
#               command_line  <commandline>
#               }
#
# WHERE:
#
# <templatename> = object name of another command definition that should be
#                  used as a template for this definition (optional)
# <objectname>   = object name of command definition, referenced by other
#                  command definitions that use it as a template (optional)
# <commandname>  = name of the command, as recognized/used by Nagios
# <commandline>  = command line
#
################################################################################

# 'check_http_heartbeat' command definition
define command{
       command_name	check_http_heartbeat
       command_line	$USER1$/check_http -H $HOSTADDRESS$ -u /heartbeat/http -s 1
       }

# 'check_https_cert' command definition
define command{
       command_name	check_https_cert
       command_line	$USER1$/check_https -H $HOSTADDRESS$ -S -C $ARG1$
       }

# 'check_https_cert' command definition
define command{
       command_name	check_https_cert_444
       command_line	$USER1$/check_https -H $HOSTADDRESS$ -p 444 -S -C $ARG1$
       }

# 'check_local_disk' command definition
define command{
        command_name    check_local_disk
        command_line    $USER1$/check_disk -w $ARG1$ -c $ARG2$ -p $ARG3$
        }


# 'check_local_load' command definition
define command{
        command_name    check_local_load
        command_line    $USER1$/check_load -w $ARG1$ -c $ARG2$
        }


# 'check_local_procs' command definition
define command{
        command_name    check_local_procs
        command_line    $USER1$/check_procs -w $ARG1$ -c $ARG2$
        }
#command_line    $USER1$/check_procs -w $ARG1$ -c $ARG2$ -s $ARG3$


# 'check_local_users' command definition
define command{
        command_name    check_local_users
        command_line    $USER1$/check_users -w $ARG1$ -c $ARG2$
        }

################################################################################
#
# SAMPLE HOST CHECK COMMANDS
#
################################################################################


# This command checks to see if a host is "alive" by pinging it
# The check must result in a 100% packet loss or 5 second (5000ms) round trip 
# average time to produce a critical error.
# Note: Only one ICMP echo packet is sent (determined by the '-p 1' argument)

# 'check-host-alive' command definition
#define command{
#        command_name    check-host-alive
#        command_line    $USER1$/check_ping -H $HOSTADDRESS$ -w 3000.0,80% -c 5000.0,100% -p 1
#        }

#define command{
#        command_name    check-host-alive
#        command_line    $USER1$/check_ping -H $HOSTADDRESS$ -w 99,99% -c 100,100% -p 1 
#        }

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

define command {
	command_name	check_remote_users
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_users -a $ARG1$ $ARG2$
}

define command {
	command_name	check_remote_load
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_load -a $ARG1$ $ARG2$
}

define command {
	command_name	check_remote_disk
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_disk -a $ARG1$ $ARG2$
}

define command {
	command_name	check_remote_disk_p
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_disk_p -a $ARG1$ $ARG2$ $ARG3$
}

define command {
	command_name	check_remote_procs
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_procs -a $ARG1$ $ARG2$
}

define command {
	command_name	check_remote_procs_C
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_procs_C -a $ARG1$ $ARG2$ $ARG3$
}

define command {
	command_name	check_remote_procs_P
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_procs_P -a $ARG1$ $ARG2$ $ARG3$
}

define command {
	command_name	check_remote_procs_m
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_procs_m -a $ARG1$ $ARG2$ $ARG3$
}

define command {
	command_name	check_remote_procs_s
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_procs_s -a $ARG1$ $ARG2$ $ARG3$
}

define command {
	command_name	check_remote_procs_u
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_procs_u -a $ARG1$ $ARG2$ $ARG3$
}

define command {
	command_name	check_remote_procs_z
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_procs_z -a $ARG1$ $ARG2$ $ARG3$
}

define command {
	command_name	check_remote_mysql
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_mysql -a $USER3$ $USER4$
}

define command {
	command_name	check_remote_mysql_slave
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_mysql_S -a $USER3$ $USER4$
}

define command {
	command_name	check_remote_afs
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_afs
}

define command {
	command_name	check_remote_cron_working
	command_line	$USER1$/check_nrpe -H $HOSTADDRESS$ -u -c check_cron_working
}

define command {
    command_name    check_scripts_ldap
    command_line    $USER1$/check_ldap -H $HOSTADDRESS$ -b dc=scripts,dc=mit,dc=edu
}

define command {
	command_name	check_svn
	command_line	$USER5$/check_svn -H $HOSTNAME$ -T
}

define command {
	command_name	check_dns_server
	command_line	/usr/lib/nagios/plugins/check_dns -H $ARG1$ -s '$HOSTADDRESS$'
}
