-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvigilo.cfg.in
464 lines (430 loc) · 14.5 KB
/
vigilo.cfg.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
############
# COMMANDS #
############
define command{
command_name host-notify-bus
command_line @NEHDIR@/nagios2vigilo.pl --event '$TIMET$' '$HOSTNAME$' '' '$HOSTSTATE$' '$HOSTOUTPUT$' '$HOSTSTATETYPE$'
}
define command{
command_name service-notify-bus
command_line @NEHDIR@/nagios2vigilo.pl --event '$TIMET$' '$HOSTNAME$' '$SERVICEDESC$' '$SERVICESTATE$' '$SERVICEOUTPUT$' '$SERVICESTATETYPE$'
}
define command{
command_name ochp-bus
command_line @NEHDIR@/nagios2vigilo.pl --state '$TIMET$' '$HOSTNAME$' '$HOSTADDRESS$' '' '$HOSTSTATEID$' '$HOSTSTATETYPE$' '$HOSTATTEMPT$' '$HOSTOUTPUT$'
}
define command{
command_name ocsp-bus
command_line @NEHDIR@/nagios2vigilo.pl --state '$TIMET$' '$HOSTNAME$' '$HOSTADDRESS$' '$SERVICEDESC$' '$SERVICESTATEID$' '$SERVICESTATETYPE$' '$SERVICEATTEMPT$' '$SERVICEOUTPUT$'
}
define command{
command_name vigilo-notify-host-by-email
command_line /usr/bin/printf "%b" "***** Vigilo *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n" | /bin/mail -s "[VIGILO] $NOTIFICATIONTYPE$ Host Alert: $HOSTNAME$ is $HOSTSTATE$" $CONTACTEMAIL$
}
define command{
command_name vigilo-notify-service-by-email
command_line /usr/bin/printf "%b" "***** Vigilo *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $LONGDATETIME$\n\nAdditional Info:\n\n$SERVICEOUTPUT$\n" | /bin/mail -s "[VIGILO] $NOTIFICATIONTYPE$ Service Alert: $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$" $CONTACTEMAIL$
}
define command{
command_name report_stale
command_line @PLUGINDIR@/check_dummy 2 "No heartbeat received"
}
define command{
command_name report_stale_data
command_line @PLUGINDIR@/check_dummy 3 "No data received for too long"
}
############
# CONTACTS #
############
define contact{
contact_name bus
alias Message Bus
service_notification_period 24x7
host_notification_period 24x7
service_notification_options w,u,c,r
host_notification_options u,d,r
service_notification_commands service-notify-bus
host_notification_commands host-notify-bus
email root@localhost
}
define contact{
contact_name last-chance-contact
alias Contact urgence Vigilo
service_notification_period 24x7
host_notification_period 24x7
service_notification_options w,u,c,r
host_notification_options u,d,r
service_notification_commands vigilo-notify-service-by-email
host_notification_commands vigilo-notify-host-by-email
email root@localhost
}
##################
# CONTACT GROUPS #
##################
define contactgroup{
contactgroup_name bots
alias Nagios Notification robots
members bus
}
################
# TIME PERIODS #
################
define timeperiod{
timeperiod_name 24x7
alias 24 Hours A Day, 7 Days A Week
sunday 00:00-24:00
monday 00:00-24:00
tuesday 00:00-24:00
wednesday 00:00-24:00
thursday 00:00-24:00
friday 00:00-24:00
saturday 00:00-24:00
}
define timeperiod{
timeperiod_name workhours
alias Standard Work Hours
monday 09:00-17:00
tuesday 09:00-17:00
wednesday 09:00-17:00
thursday 09:00-17:00
friday 09:00-17:00
}
define timeperiod{
timeperiod_name nonworkhours
alias Non-Work Hours
sunday 00:00-24:00
monday 00:00-09:00,17:00-24:00
tuesday 00:00-09:00,17:00-24:00
wednesday 00:00-09:00,17:00-24:00
thursday 00:00-09:00,17:00-24:00
friday 00:00-09:00,17:00-24:00
saturday 00:00-24:00
}
define timeperiod{
timeperiod_name at_00
alias at_00
sunday 00:00-00:05
monday 00:00-00:05
tuesday 00:00-00:05
wednesday 00:00-00:05
thursday 00:00-00:05
friday 00:00-00:05
saturday 00:00-00:05
}
define timeperiod{
timeperiod_name at_01
alias at_01
sunday 01:00-01:05
monday 01:00-01:05
tuesday 01:00-01:05
wednesday 01:00-01:05
thursday 01:00-01:05
friday 01:00-01:05
saturday 01:00-01:05
}
define timeperiod{
timeperiod_name at_02
alias at_02
sunday 02:00-02:05
monday 02:00-02:05
tuesday 02:00-02:05
wednesday 02:00-02:05
thursday 02:00-02:05
friday 02:00-02:05
saturday 02:00-02:05
}
define timeperiod{
timeperiod_name at_03
alias at_03
sunday 03:00-03:05
monday 03:00-03:05
tuesday 03:00-03:05
wednesday 03:00-03:05
thursday 03:00-03:05
friday 03:00-03:05
saturday 03:00-03:05
}
define timeperiod{
timeperiod_name at_04
alias at_04
sunday 04:00-04:05
monday 04:00-04:05
tuesday 04:00-04:05
wednesday 04:00-04:05
thursday 04:00-04:05
friday 04:00-04:05
saturday 04:00-04:05
}
define timeperiod{
timeperiod_name at_05
alias at_05
sunday 05:00-05:05
monday 05:00-05:05
tuesday 05:00-05:05
wednesday 05:00-05:05
thursday 05:00-05:05
friday 05:00-05:05
saturday 05:00-05:05
}
define timeperiod{
timeperiod_name at_06
alias at_06
sunday 06:00-06:05
monday 06:00-06:05
tuesday 06:00-06:05
wednesday 06:00-06:05
thursday 06:00-06:05
friday 06:00-06:05
saturday 06:00-06:05
}
define timeperiod{
timeperiod_name at_07
alias at_07
sunday 07:00-07:05
monday 07:00-07:05
tuesday 07:00-07:05
wednesday 07:00-07:05
thursday 07:00-07:05
friday 07:00-07:05
saturday 07:00-07:05
}
define timeperiod{
timeperiod_name at_08
alias at_08
sunday 08:00-08:05
monday 08:00-08:05
tuesday 08:00-08:05
wednesday 08:00-08:05
thursday 08:00-08:05
friday 08:00-08:05
saturday 08:00-08:05
}
define timeperiod{
timeperiod_name at_09
alias at_09
sunday 09:00-09:05
monday 09:00-09:05
tuesday 09:00-09:05
wednesday 09:00-09:05
thursday 09:00-09:05
friday 09:00-09:05
saturday 09:00-09:05
}
define timeperiod{
timeperiod_name at_10
alias at_10
sunday 10:00-10:05
monday 10:00-10:05
tuesday 10:00-10:05
wednesday 10:00-10:05
thursday 10:00-10:05
friday 10:00-10:05
saturday 10:00-10:05
}
define timeperiod{
timeperiod_name at_11
alias at_11
sunday 11:00-11:05
monday 11:00-11:05
tuesday 11:00-11:05
wednesday 11:00-11:05
thursday 11:00-11:05
friday 11:00-11:05
saturday 11:00-11:05
}
define timeperiod{
timeperiod_name at_12
alias at_12
sunday 12:00-12:05
monday 12:00-12:05
tuesday 12:00-12:05
wednesday 12:00-12:05
thursday 12:00-12:05
friday 12:00-12:05
saturday 12:00-12:05
}
define timeperiod{
timeperiod_name at_13
alias at_13
sunday 13:00-13:05
monday 13:00-13:05
tuesday 13:00-13:05
wednesday 13:00-13:05
thursday 13:00-13:05
friday 13:00-13:05
saturday 13:00-13:05
}
define timeperiod{
timeperiod_name at_14
alias at_14
sunday 14:00-14:05
monday 14:00-14:05
tuesday 14:00-14:05
wednesday 14:00-14:05
thursday 14:00-14:05
friday 14:00-14:05
saturday 14:00-14:05
}
define timeperiod{
timeperiod_name at_15
alias at_15
sunday 15:00-15:05
monday 15:00-15:05
tuesday 15:00-15:05
wednesday 15:00-15:05
thursday 15:00-15:05
friday 15:00-15:05
saturday 15:00-15:05
}
define timeperiod{
timeperiod_name at_16
alias at_16
sunday 16:00-16:05
monday 16:00-16:05
tuesday 16:00-16:05
wednesday 16:00-16:05
thursday 16:00-16:05
friday 16:00-16:05
saturday 16:00-16:05
}
define timeperiod{
timeperiod_name at_17
alias at_17
sunday 17:00-17:05
monday 17:00-17:05
tuesday 17:00-17:05
wednesday 17:00-17:05
thursday 17:00-17:05
friday 17:00-17:05
saturday 17:00-17:05
}
define timeperiod{
timeperiod_name at_18
alias at_18
sunday 18:00-18:05
monday 18:00-18:05
tuesday 18:00-18:05
wednesday 18:00-18:05
thursday 18:00-18:05
friday 18:00-18:05
saturday 18:00-18:05
}
define timeperiod{
timeperiod_name at_19
alias at_19
sunday 19:00-19:05
monday 19:00-19:05
tuesday 19:00-19:05
wednesday 19:00-19:05
thursday 19:00-19:05
friday 19:00-19:05
saturday 19:00-19:05
}
define timeperiod{
timeperiod_name at_20
alias at_20
sunday 20:00-20:05
monday 20:00-20:05
tuesday 20:00-20:05
wednesday 20:00-20:05
thursday 20:00-20:05
friday 20:00-20:05
saturday 20:00-20:05
}
define timeperiod{
timeperiod_name at_21
alias at_21
sunday 21:00-21:05
monday 21:00-21:05
tuesday 21:00-21:05
wednesday 21:00-21:05
thursday 21:00-21:05
friday 21:00-21:05
saturday 21:00-21:05
}
define timeperiod{
timeperiod_name at_22
alias at_22
sunday 22:00-22:05
monday 22:00-22:05
tuesday 22:00-22:05
wednesday 22:00-22:05
thursday 22:00-22:05
friday 22:00-22:05
saturday 22:00-22:05
}
define timeperiod{
timeperiod_name at_23
alias at_23
sunday 23:00-23:05
monday 23:00-23:05
tuesday 23:00-23:05
wednesday 23:00-23:05
thursday 23:00-23:05
friday 23:00-23:05
saturday 23:00-23:05
}
#############
# TEMPLATES #
#############
define host{
name generic-active-host
active_checks_enabled 1
passive_checks_enabled 1
obsess_over_host 0 ; Default is to NOT obsess over this host
notifications_enabled 1 ; Host notifications are enabled
event_handler_enabled 0 ; Host event handler is enabled
flap_detection_enabled 1 ; Flap detection is enabled
process_perf_data 0 ; Process performance data
retain_status_information 1 ; Retain status information across program restarts
retain_nonstatus_information 1 ; Retain non-status information across program restarts
max_check_attempts 3
notification_interval 30
notification_period 24x7
notification_options u,d,r,f
contact_groups bots
check_command check-host-alive
check_interval 5
retry_interval 1
register 0 ; DONT REGISTER THIS DEFINITION - ITS NOT A REAL HOST, JUST A TEMPLATE!
}
define host{
use generic-active-host
name generic-passive-host
passive_checks_enabled 1
active_checks_enabled 0
register 0
}
define service{
name generic-active-service ; The 'name' of this service template
active_checks_enabled 1 ; Active service checks are enabled
passive_checks_enabled 1 ; Passive service checks are accepted too
parallelize_check 1 ; Active service checks should be parallelized (disabling this can lead to major performance problems)
obsess_over_service 0 ; Default is to NOT obsess over this service
check_freshness 0 ; Default is to NOT check service 'freshness'
notifications_enabled 1 ; Service notifications are enabled
event_handler_enabled 1 ; Service event handler is enabled
flap_detection_enabled 1 ; Flap detection is enabled
process_perf_data 0 ; Process performance data
retain_status_information 1 ; Retain status information across program restarts
retain_nonstatus_information 1 ; Retain non-status information across program restarts
is_volatile 0
check_period 24x7
max_check_attempts 3
check_interval 5
retry_interval 1
contact_groups bots
notification_options w,u,c,r,f
notification_interval 30
notification_period 24x7
initial_state u ; Low level services are initially in the UNKNOWN state.
register 0 ; DONT REGISTER THIS DEFINITION - ITS NOT A REAL SERVICE, JUST A TEMPLATE!
}
define service {
name generic-passive-service
use generic-active-service
check_command return-ok
passive_checks_enabled 1 ; Passive service checks are enabled/accepted
active_checks_enabled 0 ; Active service checks are disabled
register 0
}