1 ###############################################################################
4 # MINIMALISTIC OBJECT CONFIG FILE (Template-Based Object File Format)
6 # Last Modified: 05-30-2006
9 # NOTE: This config file is intended to be used to test a Nagios installation
10 # that has been compiled with support for the template-based object
11 # configuration files.
13 # This config file is intended to servce as an *extremely* simple
14 # example of how you can create your object configuration file(s).
15 # If you're interested in more complex object configuration files for
16 # Nagios, look in the sample-config/template-object/ subdirectory of
19 ###############################################################################
23 ###############################################################################
24 ###############################################################################
28 ###############################################################################
29 ###############################################################################
31 # This defines a timeperiod where all times are valid for checks,
32 # notifications, etc. The classic "24x7" support nightmare. :-)
36 alias 24 Hours A Day, 7 Days A Week
47 ################################################################################
49 # SERVICE CHECK COMMANDS
51 ################################################################################
53 # 'check_udp' command definition
55 command_name check_udp
56 command_line $USER1$/check_udp -H $HOSTADDRESS$ -p $ARG1$
60 command_name check_ssh
61 command_line $USER1$/check_ssh $HOSTADDRESS$
65 command_name check_ssh_root
66 command_line $USER1$/check_by_ssh -H $HOSTADDRESS$ -l root -i /etc/nagios/root_ssh_key.rsa -C date
70 command_name check_ssh_pl_conf
71 command_line $USER1$/check_by_ssh -H $HOSTADDRESS$ -l root -i /etc/nagios/root_ssh_key.rsa -C "server pl_conf status 2>/dev/null"
75 command_name check_planetlab
76 command_line $USER1$/check_planetlab.py -t 3 $HOSTADDRESS$
79 ################################################################################
83 ################################################################################
85 # This command checks to see if a host is "alive" by pinging it
86 # The check must result in a 100% packet loss or 5 second (5000ms) round trip
87 # average time to produce a critical error.
88 # Note: Only one ICMP echo packet is sent (determined by the '-p 1' argument)
90 # 'check-host-alive' command definition
92 command_name check-host-alive
93 command_line $USER1$/check_ping -H $HOSTADDRESS$ -w 3000.0,40% -c 5000.0,80% -p 1
96 ###############################################################################
97 ###############################################################################
101 ###############################################################################
102 ###############################################################################
104 # Generic host definition template - This is NOT a real host, just a template!
107 name generic-host ; The name of this host template
108 notifications_enabled 1 ; Host notifications are enabled
109 event_handler_enabled 1 ; Host event handler is enabled
110 flap_detection_enabled 1 ; Flap detection is enabled
111 failure_prediction_enabled 1 ; Failure prediction is enabled
112 process_perf_data 1 ; Process performance data
113 retain_status_information 1 ; Retain status information across program restarts
114 retain_nonstatus_information 1 ; Retain non-status information across program restarts
115 check_command check-host-alive
116 max_check_attempts 10
118 notification_interval 1440
119 notification_period 24x7
120 notification_options d,r
121 register 0 ; DONT REGISTER THIS DEFINITION - ITS NOT A REAL HOST, JUST A TEMPLATE!
124 # actual hosts to be defined by python in planetlab.cfg
126 ###############################################################################
127 ###############################################################################
131 ###############################################################################
132 ###############################################################################
134 # Generic service definition template - This is NOT a real service, just a template!
137 name generic-service ; The 'name' of this service template
138 active_checks_enabled 1 ; Active service checks are enabled
139 passive_checks_enabled 1 ; Passive service checks are enabled/accepted
140 parallelize_check 1 ; Active service checks should be parallelized (disabling this can lead to major performance problems)
141 obsess_over_service 1 ; We should obsess over this service (if necessary)
142 check_freshness 0 ; Default is to NOT check service 'freshness'
143 notifications_enabled 1 ; Service notifications are enabled
144 event_handler_enabled 1 ; Service event handler is enabled
145 flap_detection_enabled 1 ; Flap detection is enabled
146 failure_prediction_enabled 1 ; Failure prediction is enabled
147 process_perf_data 1 ; Process performance data
148 retain_status_information 1 ; Retain status information across program restarts
149 retain_nonstatus_information 1 ; Retain non-status information across program restarts
150 register 0 ; DONT REGISTER THIS DEFINITION - ITS NOT A REAL SERVICE, JUST A TEMPLATE!
154 normal_check_interval 240 ; every 2 hours is OK
155 retry_check_interval 5
157 notification_options c,r
158 notification_interval 1440
159 notification_period 24x7
164 # warning is set to 2 seconds, 40% packet loss
165 # critical is set to 5 seconds, 80% packet loss
166 ### We DONT register this service because it's basically what nagios reverts to
167 # if the others services turn out to be not responding
171 service_description ping
172 # check_command check_ping!100.0,20%!500.0,60%
173 check_command check_ping!2000.0,40%!5000.0,80%
181 service_description ssh server
182 check_command check_ssh
188 name generic-ssh-root
189 service_description ssh root
190 check_command check_ssh_root
196 name generic-ssh-pl_conf
197 service_description pl_conf vserver
198 check_command check_ssh_pl_conf
204 name generic-planetlab
205 service_description comon
206 check_command check_planetlab
210 # actual services to be defined by python in planetlab.cfg