]> granicus.if.org Git - icinga2/blob - doc/7-icinga-template-library.md
05a5204787680140ef7e5fe579a08c2629427a53
[icinga2] / doc / 7-icinga-template-library.md
1 # <a id="icinga-template-library"></a> Icinga Template Library
2
3 The Icinga Template Library (ITL) implements standard templates and object
4 definitions for commonly used services.
5
6 By default the ITL is included in the `icinga2.conf` configuration file:
7
8     include <itl>
9
10 ## <a id="itl-generic-templates"></a> Generic Templates
11
12 These templates are imported by the provided example configuration.
13
14 ### <a id="itl-plugin-check-command"></a> plugin-check-command
15
16 Command template for check plugins executed by Icinga 2.
17
18 The `plugin-check-command` command does not support any vars.
19
20 ### <a id="itl-plugin-notification-command"></a> plugin-notification-command
21
22 Command template for notification scripts executed by Icinga 2.
23
24 The `plugin-notification-command` command does not support any vars.
25
26 ### <a id="itl-plugin-event-command"></a> plugin-event-command
27
28 Command template for event handler scripts executed by Icinga 2.
29
30 The `plugin-event-command` command does not support any vars.
31
32 ## <a id="itl-check-commands"></a> Check Commands
33
34 These check commands are embedded into Icinga 2 and do not require any external
35 plugin scripts.
36
37 ### <a id="itl-icinga"></a> icinga
38
39 Check command for the built-in `icinga` check. This check returns performance
40 data for the current Icinga instance.
41
42 The `icinga` check command does not support any vars.
43
44 ### <a id="itl-icinga-cluster"></a> cluster
45
46 Check command for the built-in `cluster` check. This check returns performance
47 data for the current Icinga instance and connected endpoints.
48
49 The `cluster` check command does not support any vars.
50
51 ### <a id="itl-icinga-cluster-zone"></a> cluster-zone
52
53 Check command for the built-in `cluster-zone` check.
54
55 Cluster Attributes:
56
57 Name         | Description
58 -------------|---------------
59 cluster_zone | **Optional.** The zone name. Defaults to "$host.name$".
60
61 # <a id="plugin-check-commands"></a> Plugin Check Commands
62
63 The Plugin Check Commands provides example configuration for plugin check commands
64 provided by the Monitoring Plugins project.
65
66 By default the Plugin Check Commands are included in the `icinga2.conf` configuration
67 file:
68
69     include <plugins>
70
71 The plugin check commands assume that there's a global constant named `PluginDir`
72 which contains the path of the plugins from the Monitoring Plugins project.
73
74 ### <a id="plugin-check-command-apt"></a> apt
75
76 Check command for the `check_apt` plugin.
77
78 The `apt` check command does not support any vars.
79
80
81 ### <a id="plugin-check-command-by-ssh"></a> by_ssh
82
83 Check command object for the `check_by_ssh` plugin.
84
85 Custom Attributes:
86
87 Name            | Description
88 ----------------|--------------
89 by_ssh_address  | **Optional.** The host's address. Defaults to "$address$".
90 by_ssh_port     | **Optional.** The SSH port. Defaults to 22.
91 by_ssh_command  | **Optional.** The command that should be executed.
92 by_ssh_logname  | **Optional.** The SSH username.
93 by_ssh_identity | **Optional.** The SSH identity.
94 by_ssh_quiet    | **Optional.** Whether to suppress SSH warnings. Defaults to false.
95 by_ssh_warn     | **Optional.** The warning threshold.
96 by_ssh_crit     | **Optional.** The critical threshold.
97 by_ssh_timeout  | **Optional.** The timeout in seconds.
98
99
100 ### <a id="plugin-check-command-dhcp"></a> dhcp
101
102 Check command object for the `check_dhcp` plugin.
103
104 Custom Attributes:
105
106 Name            | Description
107 ----------------|--------------
108 dhcp_serverip   | **Optional.** The IP address of the DHCP server which we should get a response from.
109 dhcp_requestedip| **Optional.** The IP address which we should be offered by a DHCP server.
110 dhcp_timeout    | **Optional.** The timeout in seconds.
111 dhcp_interface  | **Optional.** The interface to use.
112 dhcp_mac        | **Optional.** The MAC address to use in the DHCP request.
113 dhcp_unicast    | **Optional.** Whether to use unicast requests. Defaults to false.
114
115
116 ### <a id="plugin-check-command-dig"></a> dig
117
118 Check command object for the `check_dig` plugin.
119
120 Custom Attributes:
121
122 Name                 | Description
123 ---------------------|--------------
124 dig_server           | **Optional.** The DNS server to query. Defaults to "127.0.0.1".
125 dig_lookup           | **Optional.** The address that should be looked up.
126
127
128 ### <a id="plugin-check-command-disk"></a> disk
129
130 Check command object for the `check_disk` plugin.
131
132 Custom Attributes:
133
134 Name                    | Description
135 ------------------------|------------------------
136 disk_wfree              | **Optional.** The free space warning threshold in %. Defaults to 20.
137 disk_cfree              | **Optional.** The free space critical threshold in %. Defaults to 10.
138 disk_inode_wfree        | **Optional.** The free inode warning threshold.
139 disk_inode_cfree        | **Optional.** The free inode critical threshold.
140 disk_partition          | **Optional.** The partition. **Deprecated in 2.3.**
141 disk_partition_excluded | **Optional.** The excluded partition. **Deprecated in 2.3.**
142 disk_partitions         | **Optional.** The partition(s). Multiple partitions must be defined as array.
143 disk_partitions_excluded | **Optional.** The excluded partition(s). Multiple partitions must be defined as array.
144 disk_clear               | **Optional.** Clear thresholds.
145 disk_exact_match       | **Optional.** For paths or partitions specified with -p, only check for exact paths.
146 disk_errors_only       | **Optional.** Display only devices/mountpoints with errors. May be true or false.
147 disk_group             | **Optional.** Group paths. Thresholds apply to (free-)space of all partitions together
148 disk_kilobytes         | **Optional.** Same as --units kB. May be true or false.
149 disk_local             | **Optional.** Only check local filesystems. May be true or false.
150 disk_stat_remote_fs    | **Optional.** Only check local filesystems against thresholds. Yet call stat on remote filesystems to test if they are accessible (e.g. to detect Stale NFS Handles). Myy be true or false
151 disk_mountpoint        | **Optional.** Display the mountpoint instead of the partition. May be true or false.
152 disk_megabytes         | **Optional.** Same as --units MB. May be true or false.
153 disk_all               | **Optional.** Explicitly select all paths. This is equivalent to -R '.*'. May be true or false.
154 disk_eregi_path        | **Optional.** Case insensitive regular expression for path/partition (may be repeated).
155 disk_ereg_path         | **Optional.** Regular expression for path or partition (may be repeated).
156 disk_ignore_eregi_path | **Optional.** Regular expression to ignore selected path/partition (case insensitive) (may be repeated).
157 disk_ignore_ereg_path  | **Optional.** Regular expression to ignore selected path or partition (may be repeated).
158 disk_timeout           | **Optional.** Seconds before connection times out (default: 10).
159 disk_units             | **Optional.** Choose bytes, kB, MB, GB, TB (default: MB).
160 disk_exclude_type      | **Optional.** Ignore all filesystems of indicated type (may be repeated).
161
162
163 ### <a id="plugin-check-command-dns"></a> dns
164
165 Check command object for the `check_dns` plugin.
166
167 Custom Attributes:
168
169 Name                 | Description
170 ---------------------|--------------
171 dns_lookup           | **Optional.** The hostname or IP to query the DNS for. Defaults to $host_name$.
172 dns_server           | **Optional.** The DNS server to query. Defaults to the server configured in the OS.
173 dns_expected_answer  | **Optional.** The answer to look for. A hostname must end with a dot. **Deprecated in 2.3.**
174 dns_expected_answers | **Optional.** The answer(s) to look for. A hostname must end with a dot. Multiple answers must be defined as array.
175 dns_authoritative    | **Optional.** Expect the server to send an authoritative answer.
176
177
178 ### <a id="plugin-check-command-dummy"></a> dummy
179
180 Check command object for the `check_dummy` plugin.
181
182 Custom Attributes:
183
184 Name            | Description
185 ----------------|--------------
186 dummy_state     | **Optional.** The state. Can be one of 0 (ok), 1 (warning), 2 (critical) and 3 (unknown). Defaults to 0.
187 dummy_text      | **Optional.** Plugin output. Defaults to "Check was successful.".
188
189
190 ### <a id="plugin-check-command-fping4"></a> fping4
191
192 Check command object for the `check_fping` plugin.
193
194 Custom Attributes:
195
196 Name            | Description
197 ----------------|--------------
198 fping_address   | **Optional.** The host's IPv4 address. Defaults to "$address$".
199 fping_wrta      | **Optional.** The RTA warning threshold in milliseconds. Defaults to 100.
200 fping_wpl       | **Optional.** The packet loss warning threshold in %. Defaults to 5.
201 fping_crta      | **Optional.** The RTA critical threshold in milliseconds. Defaults to 200.
202 fping_cpl       | **Optional.** The packet loss critical threshold in %. Defaults to 15.
203 fping_number    | **Optional.** The number of packets to send. Defaults to 5.
204 fping_interval  | **Optional.** The interval between packets in milli-seconds. Defaults to 500.
205 fping_bytes     | **Optional.** The size of ICMP packet.
206 fping_target_timeout | **Optional.** The target timeout in milli-seconds.
207 fping_source_ip | **Optional.** The name or ip address of the source ip.
208 fping_source_interface | **Optional.** The source interface name.
209
210
211 ### <a id="plugin-check-command-fping6"></a> fping6
212
213 Check command object for the `check_fping` plugin.
214
215 Custom Attributes:
216
217 Name            | Description
218 ----------------|--------------
219 fping_address   | **Optional.** The host's IPv6 address. Defaults to "$address6$".
220 fping_wrta      | **Optional.** The RTA warning threshold in milliseconds. Defaults to 100.
221 fping_wpl       | **Optional.** The packet loss warning threshold in %. Defaults to 5.
222 fping_crta      | **Optional.** The RTA critical threshold in milliseconds. Defaults to 200.
223 fping_cpl       | **Optional.** The packet loss critical threshold in %. Defaults to 15.
224 fping_number    | **Optional.** The number of packets to send. Defaults to 5.
225 fping_interval  | **Optional.** The interval between packets in milli-seconds. Defaults to 500.
226 fping_bytes     | **Optional.** The size of ICMP packet.
227 fping_target_timeout | **Optional.** The target timeout in milli-seconds.
228 fping_source_ip | **Optional.** The name or ip address of the source ip.
229 fping_source_interface | **Optional.** The source interface name.
230
231
232 ### <a id="plugin-check-command-ftp"></a> ftp
233
234 Check command object for the `check_ftp` plugin.
235
236 Custom Attributes:
237
238 Name               | Description
239 -------------------|--------------
240 ftp_address        | **Optional.** The host's address. Defaults to "$address$".
241
242
243 ### <a id="plugin-check-command-hostalive"></a> hostalive
244
245 Check command object for the `check_ping` plugin with host check default values.
246
247 Custom Attributes:
248
249 Name            | Description
250 ----------------|--------------
251 ping_address    | **Optional.** The host's IPv4 address. Defaults to "$address$".
252 ping_wrta       | **Optional.** The RTA warning threshold in milliseconds. Defaults to 3000.
253 ping_wpl        | **Optional.** The packet loss warning threshold in %. Defaults to 80.
254 ping_crta       | **Optional.** The RTA critical threshold in milliseconds. Defaults to 5000.
255 ping_cpl        | **Optional.** The packet loss critical threshold in %. Defaults to 100.
256 ping_packets    | **Optional.** The number of packets to send. Defaults to 5.
257 ping_timeout    | **Optional.** The plugin timeout in seconds. Defaults to 0 (no timeout).
258
259
260 ### <a id="plugin-check-command-hpjd"></a> hpjd
261
262 Check command object for the `check_hpjd` plugin.
263
264 Custom Attributes:
265
266 Name            | Description
267 ----------------|--------------
268 hpjd_address    | **Optional.** The host's address. Defaults to "$address$".
269 hpjd_port       | **Optional.** The host's SNMP port. Defaults to 161.
270 hpjd_community  | **Optional.** The SNMP community. Defaults  to "public".
271
272
273 ### <a id="plugin-check-command-http"></a> http
274
275 Check command object for the `check_http` plugin.
276
277 Custom Attributes:
278
279 Name                     | Description
280 -------------------------|--------------
281 http_address             | **Optional.** The host's address. Defaults to "$address".
282 http_vhost               | **Optional.** The virtual host that should be sent in the "Host" header.
283 http_uri                 | **Optional.** The request URI.
284 http_port                | **Optional.** The TCP port. Defaults to 80 when not using SSL, 443 otherwise.
285 http_ssl                 | **Optional.** Whether to use SSL. Defaults to false.
286 http_sni                 | **Optional.** Whether to use SNI. Defaults to false.
287 http_auth_pair           | **Optional.** Add 'username:password' authorization pair.
288 http_proxy_auth_pair     | **Optional.** Add 'username:password' authorization pair for proxy.
289 http_ignore_body         | **Optional.** Don't download the body, just the headers.
290 http_linespan            | **Optional.** Allow regex to span newline.
291 http_expect_body_regex   | **Optional.** A regular expression which the body must match against. Incompatible with http_ignore_body.
292 http_expect_body_eregi   | **Optional.** A case-insensitive expression which the body must match against. Incompatible with http_ignore_body.
293 http_invertregex         | **Optional.** Changes behaviour of http_expect_body_regex and http_expect_body_eregi to return CRITICAL if found, OK if not.
294 http_warn_time           | **Optional.** The warning threshold.
295 http_critical_time       | **Optional.** The critical threshold.
296 http_expect              | **Optional.** Comma-delimited list of strings, at least one of them is expected in the first (status) line of the server response. Default: HTTP/1.
297 http_certificate         | **Optional.** Minimum number of days a certificate has to be valid. Port defaults to 443.
298 http_clientcert          | **Optional.** Name of file contains the client certificate (PEM format).
299 http_privatekey          | **Optional.** Name of file contains the private key (PEM format).
300 http_headerstring        | **Optional.** String to expect in the response headers.
301 http_string              | **Optional.** String to expect in the content.
302 http_post                | **Optional.** URL encoded http POST data.
303 http_method              | **Optional.** Set http method (for example: HEAD, OPTIONS, TRACE, PUT, DELETE).
304 http_maxage              | **Optional.** Warn if document is more than seconds old.
305 http_contenttype         | **Optional.** Specify Content-Type header when POSTing.
306 http_useragent           | **Optional.** String to be sent in http header as User Agent.
307 http_header              | **Optional.** Any other tags to be sent in http header.
308 http_extendedperfdata    | **Optional.** Print additional perfdata. Defaults to "false".
309 http_onredirect          | **Optional.** How to handle redirect pages. Possible values: "ok" (default), "warning", "critical", "follow", "sticky" (like follow but stick to address), "stickyport" (like sticky but also to port)
310 http_pagesize            | **Optional.** Minimum page size required:Maximum page size required.
311 http_timeout             | **Optional.** Seconds before connection times out.
312
313
314 ### <a id="plugin-check-command-icmp"></a> icmp
315
316 Check command object for the `check_icmp` plugin.
317
318 Custom Attributes:
319
320 Name            | Description
321 ----------------|--------------
322 icmp_address    | **Optional.** The host's address. This can either be a single address or an array of addresses. Defaults to "$address$".
323 icmp_wrta       | **Optional.** The RTA warning threshold in milliseconds. Defaults to 100.
324 icmp_wpl        | **Optional.** The packet loss warning threshold in %. Defaults to 5.
325 icmp_crta       | **Optional.** The RTA critical threshold in milliseconds. Defaults to 200.
326 icmp_cpl        | **Optional.** The packet loss critical threshold in %. Defaults to 15.
327 icmp_source     | **Optional.** The source IP address to send packets from.
328 icmp_packets    | **Optional.** The number of packets to send. Defaults to 5.
329 icmp_packet_interval | **Optional** The maximum packet interval. Defaults to 80 (milliseconds).
330 icmp_target_interval | **Optional.** The maximum target interval.
331 icmp_hosts_alive | **Optional.** The number of hosts which have to be alive for the check to succeed.
332 icmp_data_bytes | **Optional.** Payload size for each ICMP request. Defaults to 8.
333 icmp_timeout    | **Optional.** The plugin timeout in seconds. Defaults to 10 (seconds).
334
335
336 ### <a id="plugin-check-command-imap"></a> imap
337
338 Check command object for the `check_imap` plugin.
339
340 Custom Attributes:
341
342 Name            | Description
343 ----------------|--------------
344 imap_address    | **Optional.** The host's address. Defaults to "$address$".
345 imap_port       | **Optional.** The port that should be checked. Defaults to 143.
346
347
348 ### <a id="plugin-check-command-load"></a> load
349
350 Check command object for the `check_load` plugin.
351
352 Custom Attributes:
353
354 Name            | Description
355 ----------------|--------------
356 load_wload1     | **Optional.** The 1-minute warning threshold. Defaults to 5.
357 load_wload5     | **Optional.** The 5-minute warning threshold. Defaults to 4.
358 load_wload15    | **Optional.** The 15-minute warning threshold. Defaults to 3.
359 load_cload1     | **Optional.** The 1-minute critical threshold. Defaults to 10.
360 load_cload5     | **Optional.** The 5-minute critical threshold. Defaults to 6.
361 load_cload15    | **Optional.** The 15-minute critical threshold. Defaults to 4.
362
363
364 ### <a id="plugin-check-command-nrpe"></a> nrpe
365
366 Check command object for the `check_nrpe` plugin.
367
368 Custom Attributes:
369
370 Name            | Description
371 ----------------|--------------
372 nrpe_address    | **Optional.** The host's address. Defaults to "$address$".
373 nrpe_port       | **Optional.** The NRPE port. Defaults to 5668.
374 nrpe_command    | **Optional.** The command that should be executed.
375 nrpe_no_ssl     | **Optional.** Whether to disable SSL or not. Defaults to `false`.
376 nrpe_timeout_unknown | **Optional.** Whether to set timeouts to unknown instead of critical state. Defaults to `false`.
377 nrpe_timeout    | **Optional.** The timeout in seconds.
378 nrpe_arguments  | **Optional.** Arguments that should be passed to the command. Multiple arguments must be defined as array.
379
380
381 ### <a id="plugin-check-command-nscp"></a> nscp
382
383 Check command object for the `check_nt` plugin.
384
385 Custom Attributes:
386
387 Name            | Description
388 ----------------|--------------
389 nscp_address    | **Optional.** The host's address. Defaults to "$address$".
390 nscp_port       | **Optional.** The NSClient++ port. Defaults to 12489.
391 nscp_password   | **Optional.** The NSClient++ password.
392 nscp_variable   | **Required.** The variable that should be checked.
393 nscp_params     | **Optional.** Parameters for the query. Multiple parameters must be defined as array.
394 nscp_warn       | **Optional.** The warning threshold.
395 nscp_crit       | **Optional.** The critical threshold.
396 nscp_timeout    | **Optional.** The query timeout in seconds.
397
398
399 ### <a id="plugin-check-command-ntp-time"></a> ntp_time
400
401 Check command object for the `check_ntp_time` plugin.
402
403 Custom Attributes:
404
405 Name            | Description
406 ----------------|--------------
407 ntp_address     | **Optional.** The host's address. Defaults to "$address$".
408
409
410 ### <a id="plugin-check-command-passive"></a> passive
411
412 Specialised check command object for passive checks executing the `check_dummy` plugin with appropriate default values.
413
414 Custom Attributes:
415
416 Name            | Description
417 ----------------|--------------
418 dummy_state     | **Optional.** The state. Can be one of 0 (ok), 1 (warning), 2 (critical) and 3 (unknown). Defaults to 3.
419 dummy_text      | **Optional.** Plugin output. Defaults to "No Passive Check Result Received.".
420
421
422 ### <a id="plugin-check-command-ping4"></a> ping4
423
424 Check command object for the `check_ping` plugin.
425
426 Custom Attributes:
427
428 Name            | Description
429 ----------------|--------------
430 ping_address    | **Optional.** The host's IPv4 address. Defaults to "$address$".
431 ping_wrta       | **Optional.** The RTA warning threshold in milliseconds. Defaults to 100.
432 ping_wpl        | **Optional.** The packet loss warning threshold in %. Defaults to 5.
433 ping_crta       | **Optional.** The RTA critical threshold in milliseconds. Defaults to 200.
434 ping_cpl        | **Optional.** The packet loss critical threshold in %. Defaults to 15.
435 ping_packets    | **Optional.** The number of packets to send. Defaults to 5.
436 ping_timeout    | **Optional.** The plugin timeout in seconds. Defaults to 0 (no timeout).
437
438 ### <a id="plugin-check-command-ping6"></a> ping6
439
440 Check command object for the `check_ping` plugin.
441
442 Custom Attributes:
443
444 Name            | Description
445 ----------------|--------------
446 ping_address    | **Optional.** The host's IPv6 address. Defaults to "$address6$".
447 ping_wrta       | **Optional.** The RTA warning threshold in milliseconds. Defaults to 100.
448 ping_wpl        | **Optional.** The packet loss warning threshold in %. Defaults to 5.
449 ping_crta       | **Optional.** The RTA critical threshold in milliseconds. Defaults to 200.
450 ping_cpl        | **Optional.** The packet loss critical threshold in %. Defaults to 15.
451 ping_packets    | **Optional.** The number of packets to send. Defaults to 5.
452 ping_timeout    | **Optional.** The plugin timeout in seconds. Defaults to 0 (no timeout).
453
454
455 ### <a id="plugin-check-command-pop"></a> pop
456
457 Check command object for the `check_pop` plugin.
458
459 Custom Attributes:
460
461 Name            | Description
462 ----------------|--------------
463 pop_address     | **Optional.** The host's address. Defaults to "$address$".
464 pop_port        | **Optional.** The port that should be checked. Defaults to 110.
465
466
467 ### <a id="plugin-check-command-processes"></a> procs
468
469 Check command object for the `check_procs` plugin.
470
471 Custom Attributes:
472
473 Name                 | Description
474 ---------------------|--------------
475 procs_warning        | **Optional.** The process count warning threshold. Defaults to 250.
476 procs_critical       | **Optional.** The process count critical threshold. Defaults to 400.
477 procs_metric         | **Optional.** Check thresholds against metric.
478 procs_timeout        | **Optional.** Seconds before plugin times out.
479 procs_traditional    | **Optional.** Filter own process the traditional way by PID instead of /proc/pid/exe. Defaults to "false".
480 procs_state          | **Optional.** Only scan for processes that have one or more of the status flags you specify.
481 procs_ppid           | **Optional.** Only scan for children of the parent process ID indicated.
482 procs_vsz            | **Optional.** Only scan for processes with VSZ higher than indicated.
483 procs_rss            | **Optional.** Only scan for processes with RSS higher than indicated.
484 procs_pcpu           | **Optional.** Only scan for processes with PCPU higher than indicated.
485 procs_user           | **Optional.** Only scan for processes with user name or ID indicated.
486 procs_argument       | **Optional.** Only scan for processes with args that contain STRING.
487 procs_argument_regex | **Optional.** Only scan for processes with args that contain the regex STRING.
488 procs_command        | **Optional.** Only scan for exact matches of COMMAND (without path).
489 procs_nokthreads     | **Optional.** Only scan for non kernel threads. Defaults to "false".
490
491
492 ### <a id="plugin-check-command-running-kernel"></a> running_kernel
493
494 Check command object for the `check_running_kernel` plugin
495 provided by the `nagios-plugins-contrib` package on Debian.
496
497 The `running_kernel` check command does not support any vars.
498
499
500 ### <a id="plugin-check-command-simap"></a> simap
501
502 Check command object for the `check_simap` plugin.
503
504 Custom Attributes:
505
506 Name            | Description
507 ----------------|--------------
508 simap_address   | **Optional.** The host's address. Defaults to "$address$".
509 simap_port      | **Optional.** The host's port.
510
511
512 ### <a id="plugin-check-command-smtp"></a> smtp
513
514 Check command object for the `check_smtp` plugin.
515
516 Custom Attributes:
517
518 Name                 | Description
519 ---------------------|--------------
520 smtp_address         | **Optional.** The host's address. Defaults to "$address$".
521 smtp_port            | **Optional.** The port that should be checked. Defaults to 25.
522 smtp_mail_from       | **Optional.** Test a MAIL FROM command with the given email address.
523
524
525 ### <a id="plugin-check-command-snmp"></a> snmp
526
527 Check command object for the `check_snmp` plugin.
528
529 Custom Attributes:
530
531 Name                | Description
532 --------------------|--------------
533 snmp_address        | **Optional.** The host's address. Defaults to "$address$".
534 snmp_oid            | **Required.** The SNMP OID.
535 snmp_community      | **Optional.** The SNMP community. Defaults to "public".
536 snmp_warn           | **Optional.** The warning threshold.
537 snmp_crit           | **Optional.** The critical threshold.
538 snmp_string         | **Optional.** Return OK state if the string matches exactly with the output value
539 snmp_ereg           | **Optional.** Return OK state if extended regular expression REGEX matches with the output value
540 snmp_eregi          | **Optional.** Return OK state if case-insensitive extended REGEX matches with the output value
541 snmp_label          | **Optional.** Prefix label for output value
542 snmp_invert_search  | **Optional.** Invert search result and return CRITICAL state if found
543 snmp_units          | **Optional.** Units label(s) for output value (e.g., 'sec.').
544 snmp_timeout        | **Optional.** The command timeout in seconds. Defaults to 10 seconds.
545
546 ### <a id="plugin-check-command-snmpv3"></a> snmpv3
547
548 Check command object for the `check_snmp` plugin, using SNMPv3 authentication and encryption options.
549
550 Custom Attributes:
551
552 Name              | Description
553 ------------------|--------------
554 snmpv3_address    | **Optional.** The host's address. Defaults to "$address$".
555 snmpv3_user       | **Required.** The username to log in with.
556 snmpv3_auth_alg   | **Optional.** The authentication algorithm. Defaults to SHA.
557 snmpv3_auth_key   | **Required.** The authentication key.
558 snmpv3_priv_alg   | **Optional.** The encryption algorithm. Defaults to AES.
559 snmpv3_priv_key   | **Required.** The encryption key.
560 snmpv3_oid        | **Required.** The SNMP OID.
561 snmpv3_warn       | **Optional.** The warning threshold.
562 snmpv3_crit       | **Optional.** The critical threshold.
563 snmpv3_label      | **Optional.** Prefix label for output value.
564
565 ### <a id="plugin-check-command-snmp-uptime"></a> snmp-uptime
566
567 Check command object for the `check_snmp` plugin.
568
569 Custom Attributes:
570
571 Name            | Description
572 ----------------|--------------
573 snmp_address    | **Optional.** The host's address. Defaults to "$address$".
574 snmp_oid        | **Optional.** The SNMP OID. Defaults to "1.3.6.1.2.1.1.3.0".
575 snmp_community  | **Optional.** The SNMP community. Defaults to "public".
576
577
578 ### <a id="plugin-check-command-spop"></a> spop
579
580 Check command object for the `check_spop` plugin.
581
582 Custom Attributes:
583
584 Name            | Description
585 ----------------|--------------
586 spop_address    | **Optional.** The host's address. Defaults to "$address$".
587 spop_port       | **Optional.** The host's port.
588
589
590 ### <a id="plugin-check-command-ssh"></a> ssh
591
592 Check command object for the `check_ssh` plugin.
593
594 Custom Attributes:
595
596 Name            | Description
597 ----------------|--------------
598 ssh_address     | **Optional.** The host's address. Defaults to "$address$".
599 ssh_port        | **Optional.** The port that should be checked. Defaults to 22.
600 ssh_timeout     | **Optional.** Seconds before connection times out. Defaults to 10.
601
602
603 ### <a id="plugin-check-command-ssl"></a> ssl
604
605 Check command object for the `check_tcp` plugin, using ssl-related options.
606
607 Custom Attributes:
608
609 Name                          | Description
610 ------------------------------|--------------
611 ssl_address                   | **Optional.** The host's address. Defaults to "$address$".
612 ssl_port                      | **Required.** The port that should be checked.
613 ssl_timeout                   | **Optional.** Timeout in seconds for the connect and handshake. The plugin default is 10 seconds.
614 ssl_cert_valid_days_warn      | **Optional.** Warning threshold for days before the certificate will expire. When used, ssl_cert_valid_days_critical must also be set.
615 ssl_cert_valid_days_critical  | **Optional.** Critical threshold for days before the certificate will expire. When used, ssl_cert_valid_days_warn must also be set.
616
617
618 ### <a id="plugin-check-command-ssmtp"></a> ssmtp
619
620 Check command object for the `check_ssmtp` plugin.
621
622 Custom Attributes:
623
624 Name            | Description
625 ----------------|--------------
626 ssmtp_address   | **Required.** The host's address. Defaults to "$address$".
627 ssmtp_port      | **Optional.** The port that should be checked. Defaults to 465.
628
629
630 ### <a id="plugin-check-command-swap"></a> swap
631
632 Check command object for the `check_swap` plugin.
633
634 Custom Attributes:
635
636 Name            | Description
637 ----------------|--------------
638 swap_wfree      | **Optional.** The free swap space warning threshold in %. Defaults to 50.
639 swap_cfree      | **Optional.** The free swap space critical threshold in %. Defaults to 25.
640
641
642 ### <a id="plugin-check-command-tcp"></a> tcp
643
644 Check command object for the `check_tcp` plugin.
645
646 Custom Attributes:
647
648 Name            | Description
649 ----------------|--------------
650 tcp_address     | **Optional.** The host's address. Defaults to "$address$".
651 tcp_port        | **Required.** The port that should be checked.
652
653
654 ### <a id="plugin-check-command-udp"></a> udp
655
656 Check command object for the `check_udp` plugin.
657
658 Custom Attributes:
659
660 Name            | Description
661 ----------------|--------------
662 udp_address     | **Optional.** The host's address. Defaults to "$address$".
663 udp_port        | **Required.** The port that should be checked.
664
665
666 ### <a id="plugin-check-command-ups"></a> ups
667
668 Check command object for the `check_ups` plugin.
669
670 Custom Attributes:
671
672 Name            | Description
673 ----------------|--------------
674 ups_address     | **Optional.** The host's address. Defaults to "$address$".
675 ups_name        | **Optional.** The UPS name. Defaults to `ups`.
676
677
678 ### <a id="plugin-check-command-users"></a> users
679
680 Check command object for the `check_users` plugin.
681
682 Custom Attributes:
683
684 Name            | Description
685 ----------------|--------------
686 users_wgreater  | **Optional.** The user count warning threshold. Defaults to 20.
687 users_cgreater  | **Optional.** The user count critical threshold. Defaults to 50.
688
689
690 # <a id="snmp-manubulon-plugin-check-commands"></a> SNMP Manubulon Plugin Check Commands
691
692 The `SNMP Manubulon Plugin Check Commands` provide example configuration for plugin check
693 commands provided by the [SNMP Manubulon project](http://nagios.manubulon.com/index_snmp.html).
694
695 The SNMP manubulon plugin check commands assume that the global constant named `ManubulonPluginDir`
696 is set to the path where the Manubublon SNMP plugins are installed.
697
698 You can enable these plugin check commands by adding the following the include directive in your
699 configuration [icinga2.conf](5-configuring-icinga-2.md#icinga2-conf) file:
700
701     include <manubulon>
702
703 ## Checks by Host Type
704
705 **N/A**      : Not available for this type.
706
707 **SNMP**     : Available for simple SNMP query.
708
709 **??**       : Untested.
710
711 **Specific** : Script name for platform specific checks.
712
713
714   Host type               | Interface  | storage  | load/cpu  | mem | process  | env | specific
715   ------------------------|------------|----------|-----------|-----|----------|-----|-------------------------
716   Linux                   |   Yes      |   Yes    |   Yes     | Yes |   Yes    | No  |
717   Windows                 |   Yes      |   Yes    |   Yes     | Yes |   Yes    | No  | check_snmp_win.pl
718   Cisco router/switch     |   Yes      |   N/A    |   Yes     | Yes |   N/A    | Yes |
719   HP router/switch        |   Yes      |   N/A    |   Yes     | Yes |   N/A    | No  |
720   Bluecoat proxy          |   Yes      |   SNMP   |   Yes     | SNMP|   No     | Yes |
721   CheckPoint on SPLAT     |   Yes      |   Yes    |   Yes     | Yes |   Yes    | No  | check_snmp_cpfw.pl
722   CheckPoint on Nokia IP  |   Yes      |   Yes    |   Yes     | No  |   ??     | No  | check_snmp_vrrp.pl
723   Boostedge               |   Yes      |   Yes    |   Yes     | Yes |   ??     | No  | check_snmp_boostedge.pl
724   AS400                   |   Yes      |   Yes    |   Yes     | Yes |   No     | No  |
725   NetsecureOne Netbox     |   Yes      |   Yes    |   Yes     | ??  |   Yes    | No  |
726   Radware Linkproof       |   Yes      |   N/A    |   SNMP    | SNMP|   No     | No  | check_snmp_linkproof_nhr <br> check_snmp_vrrp.pl
727   IronPort                |   Yes      |   SNMP   |   SNMP    | SNMP|   No     | Yes |
728   Cisco CSS               |   Yes      |   ??     |   Yes     | Yes |   No     | ??  | check_snmp_css.pl
729
730
731 ### <a id="plugin-check-command-snmp-load"></a> snmp-load
732
733 Check command object for the [check_snmp_load.pl](http://nagios.manubulon.com/snmp_load.html) plugin.
734
735 Custom Attributes:
736
737
738 Name                    | Description
739 ------------------------|--------------
740 snmp_address            | **Optional.** The host's address. Defaults to "$address$".
741 snmp_nocrypt            | **Optional.** Define SNMP encryption. If set **snmp_v3** needs to be set. Defaults to "false".
742 snmp_community          | **Optional.** The SNMP community. Defaults to "public".
743 snmp_port               | **Optional.** The SNMP port connection.
744 snmp_v2                 | **Optional.** SNMP version to 2c. Defaults to "false".
745 snmp_v3                 | **Optional.** SNMP version to 3. Defaults to "false".
746 snmp_login              | **Optional.** SNMP version 3 username. Defaults to "snmpuser".
747 snmp_password           | **Required.** SNMP version 3 password. No value defined as default.
748 snmp_v3_use_privpass    | **Optional.** Define to use SNMP version 3 priv password. Defaults to "false".
749 snmp_authprotocol       | **Optional.** SNMP version 3 authentication protocol. Defaults to "md5,des".
750 snmp_privpass           | **Required.** SNMP version 3 priv password. No value defined as default.
751 snmp_warn               | **Optional.** The warning threshold. Change the `snmp_load_type` var to "netsl" for using 3 values.
752 snmp_crit               | **Optional.** The critical threshold. Change the `snmp_load_type` var to "netsl" for using 3 values.
753 snmp_load_type          | **Optional.** Load type. Defaults to "stand". Check all available types in the [snmp load](http://nagios.manubulon.com/snmp_load.html) documentation.
754 snmp_perf               | **Optional.** Enable perfdata values. Defaults to "true".
755 snmp_timeout            | **Optional.** The command timeout in seconds. Defaults to 5 seconds.
756
757 ### <a id="plugin-check-command-snmp-memory"></a> snmp-memory
758
759 Check command object for the [check_snmp_mem.pl](http://nagios.manubulon.com/snmp_mem.html) plugin.
760
761 Custom Attributes:
762
763 Name                    | Description
764 ------------------------|--------------
765 snmp_address            | **Optional.** The host's address. Defaults to "$address$".
766 snmp_nocrypt            | **Optional.** Define SNMP encryption. If set **snmp_v3** needs to be set. Defaults to "false".
767 snmp_community          | **Optional.** The SNMP community. Defaults to "public".
768 snmp_port               | **Optional.** The SNMP port connection.
769 snmp_v2                 | **Optional.** SNMP version to 2c. Defaults to "false".
770 snmp_v3                 | **Optional.** SNMP version to 3. Defaults to "false".
771 snmp_login              | **Optional.** SNMP version 3 username. Defaults to "snmpuser".
772 snmp_password           | **Required.** SNMP version 3 password. No value defined as default.
773 snmp_v3_use_privpass    | **Optional.** Define to use SNMP version 3 priv password. Defaults to "false".
774 snmp_authprotocol       | **Optional.** SNMP version 3 authentication protocol. Defaults to "md5,des".
775 snmp_privpass           | **Required.** SNMP version 3 priv password. No value defined as default.
776 snmp_warn               | **Optional.** The warning threshold.
777 snmp_crit               | **Optional.** The critical threshold.
778 snmp_perf               | **Optional.** Enable perfdata values. Defaults to "true".
779 snmp_timeout            | **Optional.** The command timeout in seconds. Defaults to 5 seconds.
780
781 ### <a id="plugin-check-command-snmp-storage"></a> snmp-storage
782
783 Check command object for the [check_snmp_storage.pl](http://nagios.manubulon.com/snmp_storage.html) plugin.
784
785 Custom Attributes:
786
787 Name                    | Description
788 ------------------------|--------------
789 snmp_address            | **Optional.** The host's address. Defaults to "$address$".
790 snmp_nocrypt            | **Optional.** Define SNMP encryption. If set **snmp_v3** needs to be set. Defaults to "false".
791 snmp_community          | **Optional.** The SNMP community. Defaults to "public".
792 snmp_port               | **Optional.** The SNMP port connection.
793 snmp_v2                 | **Optional.** SNMP version to 2c. Defaults to "false".
794 snmp_v3                 | **Optional.** SNMP version to 3. Defaults to "false".
795 snmp_login              | **Optional.** SNMP version 3 username. Defaults to "snmpuser".
796 snmp_password           | **Required.** SNMP version 3 password. No value defined as default.
797 snmp_v3_use_privpass    | **Optional.** Define to use SNMP version 3 priv password. Defaults to "false".
798 snmp_authprotocol       | **Optional.** SNMP version 3 authentication protocol. Defaults to "md5,des".
799 snmp_privpass           | **Required.** SNMP version 3 priv password. No value defined as default.
800 snmp_warn               | **Optional.** The warning threshold.
801 snmp_crit               | **Optional.** The critical threshold.
802 snmp_storage_name       | **Optional.** Storage name. Default to regex "^/$$". More options available in the [snmp storage](http://nagios.manubulon.com/snmp_storage.html) documentation.
803 snmp_perf               | **Optional.** Enable perfdata values. Defaults to "true".
804 snmp_timeout            | **Optional.** The command timeout in seconds. Defaults to 5 seconds.
805
806 ### <a id="plugin-check-command-snmp-interface"></a> snmp-interface
807
808 Check command object for the [check_snmp_int.pl](http://nagios.manubulon.com/snmp_int.html) plugin.
809
810 Custom Attributes:
811
812 Name                        | Description
813 ----------------------------|--------------
814 snmp_address                | **Optional.** The host's address. Defaults to "$address$".
815 snmp_nocrypt                | **Optional.** Define SNMP encryption. If set **snmp_v3** needs to be set. Defaults to "false".
816 snmp_community              | **Optional.** The SNMP community. Defaults to "public".
817 snmp_port                   | **Optional.** The SNMP port connection.
818 snmp_v2                     | **Optional.** SNMP version to 2c. Defaults to "false".
819 snmp_v3                     | **Optional.** SNMP version to 3. Defaults to "false".
820 snmp_login                  | **Optional.** SNMP version 3 username. Defaults to "snmpuser".
821 snmp_password               | **Required.** SNMP version 3 password. No value defined as default.
822 snmp_v3_use_privpass        | **Optional.** Define to use SNMP version 3 priv password. Defaults to "false".
823 snmp_authprotocol           | **Optional.** SNMP version 3 authentication protocol. Defaults to "md5,des".
824 snmp_privpass               | **Required.** SNMP version 3 priv password. No value defined as default.
825 snmp_warn                   | **Optional.** The warning threshold.
826 snmp_crit                   | **Optional.** The critical threshold.
827 snmp_interface              | **Optional.** Network interface name. Default to regex "eth0".
828 snmp_interface_perf         | **Optional.** Check the input/ouput bandwidth of the interface. Defaults to "true".
829 snmp_interface_label        | **Optional.** Add label before speed in output: in=, out=, errors-out=, etc...
830 snmp_interface_bits_bytes   | **Optional.** Output performance data in bits/s or Bytes/s. **Depends** on snmp_interface_kbits set to "true". Defaults to "true".
831 snmp_interface_percent      | **Optional.** Output performance data in % of max speed. Defaults to "false".
832 snmp_interface_kbits        | **Optional.** Make the warning and critical levels in KBits/s. Defaults to "true".
833 snmp_interface_megabytes    | **Optional.** Make the warning and critical levels in Mbps or MBps. **Depends** on snmp_interface_kbits set to "true". Defaults to "true".
834 snmp_interface_64bit        | **Optional.** Use 64 bits counters instead of the standard counters when checking bandwidth & performance data for interface >= 1Gbps. Defaults to "false".
835 snmp_interface_errors       | **Optional.** Add error & discard to Perfparse output. Defaults to "true".
836 snmp_interface_noregexp     | **Optional.** Do not use regexp to match interface name in description OID. Defaults to "false".
837 snmp_interface_delta        | **Optional.** Delta time of perfcheck. Defaults to "300" (5 min).
838 snmp_warncrit_percent       | **Optional.** Make the warning and critical levels in % of reported interface speed. If set **snmp_interface_megabytes** needs to be set to "false". Defaults to "false".
839 snmp_perf                   | **Optional.** Enable perfdata values. Defaults to "true".
840 snmp_timeout                | **Optional.** The command timeout in seconds. Defaults to 5 seconds.
841
842 ### <a id="plugin-check-command-snmp-process"></a> snmp-process
843
844 Check command object for the [check_snmp_process.pl](http://nagios.manubulon.com/snmp_process.html) plugin.
845
846 Custom Attributes:
847
848 Name                    | Description
849 ------------------------|--------------
850 snmp_address            | **Optional.** The host's address. Defaults to "$address$".
851 snmp_nocrypt            | **Optional.** Define SNMP encryption. If set **snmp_v3** needs to be set. Defaults to "false".
852 snmp_community          | **Optional.** The SNMP community. Defaults to "public".
853 snmp_port               | **Optional.** The SNMP port connection.
854 snmp_v2                 | **Optional.** SNMP version to 2c. Defaults to "false".
855 snmp_v3                 | **Optional.** SNMP version to 3. Defaults to "false".
856 snmp_login              | **Optional.** SNMP version 3 username. Defaults to "snmpuser".
857 snmp_password           | **Required.** SNMP version 3 password. No value defined as default.
858 snmp_v3_use_privpass    | **Optional.** Define to use SNMP version 3 priv password. Defaults to "false".
859 snmp_authprotocol       | **Optional.** SNMP version 3 authentication protocol. Defaults to "md5,des".
860 snmp_privpass           | **Required.** SNMP version 3 priv password. No value defined as default..
861 snmp_warn               | **Optional.** The warning threshold.
862 snmp_crit               | **Optional.** The critical threshold.
863 snmp_process_name       | **Optional.** Name of the process (regexp). No trailing slash!. Defaults to ".*".
864 snmp_perf               | **Optional.** Enable perfdata values. Defaults to "true".
865 snmp_timeout            | **Optional.** The command timeout in seconds. Defaults to 5 seconds.