1 /******************************************************************************
3 * Copyright (C) 2012-2018 Icinga Development Team (https://www.icinga.com/) *
5 * This program is free software; you can redistribute it and/or *
6 * modify it under the terms of the GNU General Public License *
7 * as published by the Free Software Foundation; either version 2 *
8 * of the License, or (at your option) any later version. *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program; if not, write to the Free Software Foundation *
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. *
18 ******************************************************************************/
20 template CheckCommand "ipv4-or-ipv6" {
21 vars.check_address = {{
22 var addr_v4 = macro("$address$")
23 var addr_v6 = macro("$address6$")
25 if (addr_v4 && !macro("$check_ipv6$") || macro("$check_ipv4$")) {
32 vars.check_ipv4 = false
33 vars.check_ipv6 = false
36 template CheckCommand "ping-common" {
37 command = [ PluginDir + "/check_ping" ]
41 value = "$ping_address$"
42 description = "host to ping"
45 value = "$ping_wrta$,$ping_wpl$%"
46 description = "warning threshold pair"
49 value = "$ping_crta$,$ping_cpl$%"
50 description = "critical threshold pair"
53 value = "$ping_packets$"
54 description = "number of ICMP ECHO packets to send (Default: 5)"
57 value = "$ping_timeout$"
58 description = "Seconds before connection times out (default: 10)"
68 object CheckCommand "ping" {
72 vars.ping_address = "$check_address$"
75 object CheckCommand "ping4" {
80 vars.ping_address = "$address$"
83 object CheckCommand "ping6" {
88 vars.ping_address = "$address6$"
91 template CheckCommand "hostalive-common" {
92 vars.ping_wrta = 3000.0
95 vars.ping_crta = 5000.0
99 object CheckCommand "hostalive" {
101 import "hostalive-common"
104 object CheckCommand "hostalive4" {
106 import "hostalive-common"
109 object CheckCommand "hostalive6" {
111 import "hostalive-common"
114 template CheckCommand "fping-common" {
116 PluginDir + "/check_fping",
122 value = "$fping_wrta$,$fping_wpl$%"
123 description = "warning threshold pair"
126 value = "$fping_crta$,$fping_cpl$%"
127 description = "critical threshold pair"
130 value = "$fping_number$"
131 description = "number of ICMP packets to send (default: 1)"
134 value = "$fping_interval$"
135 description = "Interval (ms) between sending packets (default: fping's default for -p)"
138 value = "$fping_bytes$"
139 description = "size of ICMP packet (default: 56)"
142 value = "$fping_target_timeout$"
143 description = "Target timeout (ms) (default: fping's default for -t)"
146 value = "$fping_source_ip$"
147 description = "name or IP Address of sourceip"
150 value = "$fping_source_interface$"
151 description = "source interface name"
155 vars.fping_wrta = 100
157 vars.fping_crta = 200
159 vars.fping_number = 5
160 vars.fping_interval = 500
163 object CheckCommand "fping4" {
164 import "fping-common"
168 vars.fping_address = "$address$"
171 object CheckCommand "fping6" {
172 import "fping-common"
176 vars.fping_address = "$address6$"
179 object CheckCommand "tcp" {
180 import "ipv4-or-ipv6"
182 command = [ PluginDir + "/check_tcp" ]
186 value = "$tcp_address$"
187 description = "Host name, IP Address, or unix socket (must be an absolute path)."
191 description = "The TCP port number."
194 value = "$tcp_expect$"
195 description = "String to expect in server response (may be repeated)."
199 description = "All expect strings need to occur in server response. Defaults to false."
204 set_if = "$tcp_escape_send$"
205 description = "Enable usage of \n, \r, \t or \\ in send string."
210 description = "String to send to the server."
215 set_if = "$tcp_escape_quit$"
216 description = "Enable usage of \n, \r, \t or \\ in quit string."
221 description = "String to send server to initiate a clean close of the connection."
224 value = "$tcp_refuse$"
225 description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
228 value = "$tcp_mismatch$"
229 description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
232 set_if = "$tcp_jail$"
233 description = "Hide output from TCP socket."
236 value = "$tcp_maxbytes$"
237 description = "Close connection once more than this number of bytes are received."
240 value = "$tcp_delay$"
241 description = "Seconds to wait between sending string and polling for response."
244 value = "$tcp_certificate$"
245 description = "Minimum number of days a certificate has to be valid. 1st value is number of days for warning, 2nd is critical (if not specified: 0) - seperated by comma."
249 description = "Use SSL for the connection."
252 value = "$tcp_wtime$"
253 description = "Response time to result in warning status (seconds)."
256 value = "$tcp_ctime$"
257 description = "Response time to result in critical status (seconds)."
260 value = "$tcp_timeout$"
261 description = "Seconds before connection times out. Defaults to 10."
264 set_if = "$tcp_ipv4$"
265 description = "Use IPv4 connection"
268 set_if = "$tcp_ipv6$"
269 description = "Use IPv6 connection"
273 vars.tcp_address = "$check_address$"
275 vars.tcp_refuse = "crit"
276 vars.tcp_mismatch = "warn"
277 vars.tcp_timeout = 10
278 vars.check_ipv4 = "$tcp_ipv4$"
279 vars.check_ipv6 = "$tcp_ipv6$"
282 object CheckCommand "ssl" {
283 import "ipv4-or-ipv6"
285 command = [ PluginDir + "/check_tcp" ]
289 value = "$ssl_address$"
290 description = "Host address"
294 description ="TCP port (default: 443)"
297 description = "Use SSL for the connection"
300 value = "$ssl_timeout$"
301 description = "Seconds before connection times out (default: 10)"
304 var days_warn = macro("$ssl_cert_valid_days_warn$")
305 var days_critical = macro("$ssl_cert_valid_days_critical$")
308 return days_warn + "," + days_critical
316 description = "Enable SSL/TLS hostname extension support (SNI)"
320 vars.ssl_address = "$check_address$"
322 vars.ssl_cert_valid_days_warn = false
323 vars.ssl_cert_valid_days_critical = false
327 object CheckCommand "udp" {
328 import "ipv4-or-ipv6"
331 PluginDir + "/check_udp",
332 "-H", "$udp_address$",
340 description = "String to send to the server"
343 value = "$udp_expect$"
345 description = " String to expect in server response"
349 description = "String to send server to initiate a clean close of the connection"
352 set_if = "$udp_ipv4$"
353 description = "Use IPv4 connection"
356 set_if = "$udp_ipv6$"
357 description = "Use IPv6 connection"
361 vars.udp_address = "$check_address$"
362 vars.check_ipv4 = "$udp_ipv4$"
363 vars.check_ipv6 = "$udp_ipv6$"
366 object CheckCommand "http" {
367 import "ipv4-or-ipv6"
369 command = [ PluginDir + "/check_http" ]
373 value = "$http_vhost$"
374 description = "Host name argument for servers using host headers (virtual host)"
377 value = "$http_address$"
378 description = "IP address or name (use numeric address if possible to bypass DNS lookup)"
382 description = "URL to GET or POST (default: /)"
385 value = "$http_port$"
386 description = "Port number (default: 80)"
389 set_if = "$http_ssl$"
390 description = "Connect via SSL"
393 set_if = "$http_ssl_force_tlsv1$"
394 description = "Connect via SSL version TLSv1"
397 set_if = "$http_ssl_force_tlsv1_1$"
398 description = "Connect via SSL version TLSv1.1"
401 set_if = "$http_ssl_force_tlsv1_2$"
402 description = "Connect via SSL version TLSv1.2"
405 set_if = "$http_ssl_force_sslv2$"
406 description = "Connect via SSL version SSLv2"
409 set_if = "$http_ssl_force_sslv3$"
410 description = "Connect via SSL version SSLv3"
413 set_if = "$http_ssl_force_tlsv1_or_higher$"
414 description = "Connect via SSL version TLSv1 and newer"
417 set_if = "$http_ssl_force_tlsv1_1_or_higher$"
418 description = "Connect via SSL version TLSv1.1 and newer"
421 set_if = "$http_ssl_force_tlsv1_2_or_higher$"
422 description = "Connect via SSL version TLSv1.2 and newer"
425 set_if = "$http_ssl_force_sslv2_or_higher$"
426 description = "Connect via SSL version SSLv2 and newer"
429 set_if = "$http_ssl_force_sslv3_or_higher$"
430 description = "Connect via SSL version SSLv3 and newer"
433 set_if = "$http_sni$"
434 description = "Enable SSL/TLS hostname extension support (SNI)"
437 value = "$http_certificate$"
438 description = "Minimum number of days a certificate has to be valid. This parameter explicitely sets the port to 443 and ignores the URL if passed."
441 value = "$http_clientcert$"
442 description = "Name of file contains the client certificate (PEM format)"
445 value = "$http_privatekey$"
446 description = "Name of file contains the private key (PEM format)"
449 value = "$http_auth_pair$"
450 description = "Username:password on sites with basic authentication"
453 set_if = "$http_ignore_body$"
454 description = "Don't wait for document body: stop reading after headers"
457 value = "$http_warn_time$"
458 description = "Response time to result in warning status (seconds)"
461 value = "$http_critical_time$"
462 description = "Response time to result in critical status (seconds)"
465 value = "$http_expect$"
466 description = "Comma-delimited list of strings, at least one of them is expected in the first (status) line of the server response (default: HTTP/1.)"
469 value = "$http_headerstring$"
470 description = "String to expect in the response headers"
473 value = "$http_string$"
474 description = "String to expect in the content"
477 value = "$http_post$"
478 description = "URL encoded http POST data"
481 value = "$http_method$"
482 description = "Set http method (for example: HEAD, OPTIONS, TRACE, PUT, DELETE)"
485 value = "$http_maxage$"
486 description = "Warn if document is more than seconds old"
489 value = "$http_contenttype$"
490 description = "Specify Content-Type header when POSTing"
493 set_if = "$http_linespan$"
494 description = "Allow regex to span newline"
498 value = "$http_expect_body_regex$"
499 description = "Search page for regex"
503 value = "$http_expect_body_eregi$"
504 description = "Search page for case-insensitive regex"
508 set_if = "$http_invertregex$"
509 description = "Return CRITICAL if found, OK if not"
512 value = "$http_proxy_auth_pair$"
513 description = "Username:password on proxy-servers with basic authentication"
516 value = "$http_useragent$"
517 description = "String to be sent in http header as User Agent"
520 value = "$http_header$"
521 description = "Any other tags to be sent in http header"
524 set_if = "$http_extendedperfdata$"
525 description = "Print additional perfdata"
528 value = "$http_onredirect$"
529 description = "How to handle redirect pages"
532 value = "$http_pagesize$"
533 description = "Minim page size required:Maximum page size required"
536 value = "$http_timeout$"
537 description = "Seconds before connection times out"
540 set_if = "$http_ipv4$"
541 description = "Use IPv4 connection"
544 set_if = "$http_ipv6$"
545 description = "Use IPv6 connection"
548 set_if = "$http_link$"
549 description = "Wrap output in HTML link"
552 set_if = "$http_verbose$"
553 description = "Show details for command-line debugging"
557 vars.http_address = "$check_address$"
558 vars.http_ssl = false
559 vars.http_sni = false
560 vars.http_linespan = false
561 vars.http_invertregex = false
562 vars.check_ipv4 = "$http_ipv4$"
563 vars.check_ipv6 = "$http_ipv6$"
564 vars.http_link = false
565 vars.http_verbose = false
568 object CheckCommand "ftp" {
569 import "ipv4-or-ipv6"
571 command = [ PluginDir + "/check_ftp" ]
575 value = "$ftp_address$"
576 description = "The host's address. Defaults to $address$ or $address6$ if the address attribute is not set."
580 description = "The FTP port number. Defaults to none"
583 value = "$ftp_expect$"
584 description = "String to expect in server response (may be repeated)."
588 description = "All expect strings need to occur in server response. Default is any."
593 set_if = "$ftp_escape_send$"
594 description = "Enable usage of \n, \r, \t or \\ in send string. Default is nothing."
599 description = "String to send to the server."
604 set_if = "$ftp_escape_quit$"
605 description = "Can use \n, \r, \t or \\ in quit string. Default is \r\n added to end of quit."
610 description = "String to send server to initiate a clean close of the connection."
613 value = "$ftp_refuse$"
614 description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
617 value = "$ftp_mismatch$"
618 description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
621 set_if = "$ftp_jail$"
622 description = "Hide output from TCP socket."
625 value = "$ftp_maxbytes$"
626 description = "Close connection once more than this number of bytes are received."
629 value = "$ftp_delay$"
630 description = "Seconds to wait between sending string and polling for response."
633 value = "$ftp_certificate$"
634 description = "Minimum number of days a certificate has to be valid. 1st value is number of days for warning, 2nd is critical (if not specified: 0) - seperated by comma."
638 description = "Use SSL for the connection."
641 value = "$ftp_wtime$"
642 description = "Response time to result in warning status (seconds)."
645 value = "$ftp_ctime$"
646 description = "Response time to result in critical status (seconds)."
649 value = "$ftp_timeout$"
650 description = "Seconds before connection times out. Defaults to 10."
653 set_if = "$ftp_ipv4$"
654 description = "Use IPv4 connection"
657 set_if = "$ftp_ipv6$"
658 description = "Use IPv6 connection"
662 vars.ftp_address = "$check_address$"
664 vars.ftp_refuse = "crit"
665 vars.ftp_mismatch = "warn"
666 vars.ftp_timeout = 10
667 vars.check_ipv4 = "$ftp_ipv4$"
668 vars.check_ipv6 = "$ftp_ipv6$"
671 object CheckCommand "smtp" {
672 import "ipv4-or-ipv6"
674 command = [ PluginDir + "/check_smtp" ]
678 value = "$smtp_address$"
679 description = "Host name, IP Address, or unix socket (must be an absolute path)"
682 value = "$smtp_port$"
683 description = "Port number (default: 25)"
686 value = "$smtp_mail_from$"
687 description = "FROM-address to include in MAIL command, required by Exchange 2000"
690 value = "$smtp_expect$"
691 description = "String to expect in first line of server response (default: '220')"
694 value = "$smtp_command$"
695 description = "SMTP command"
698 value = "$smtp_response$"
699 description = "Expected response to command (may be used repeatedly)"
702 value = "$smtp_helo_fqdn$"
703 description = "FQDN used for HELO"
706 value = "$smtp_certificate_age$"
707 description = "Minimum number of days a certificate has to be valid"
710 set_if = "$smtp_starttls$"
711 description = "Use STARTTLS for the connection."
714 value = "$smtp_authtype$"
715 description = "SMTP AUTH type to check (default none, only LOGIN supported)"
718 value = "$smtp_authuser$"
719 description = "SMTP AUTH username"
722 value = "$smtp_authpass$"
723 description = "SMTP AUTH password"
726 value = "$smtp_ignore_quit$"
727 description = "Ignore failure when sending QUIT command to server"
730 value = "$smtp_warning$"
731 description = "Response time to result in warning status (seconds)"
734 value = "$smtp_critical$"
735 description = "Response time to result in critical status (seconds)"
738 value = "$smtp_timeout$"
739 description = "Seconds before connection times out (default: 10)"
742 set_if = "$smtp_ipv4$"
743 description = "Use IPv4 connection"
746 set_if = "$smtp_ipv6$"
747 description = "Use IPv6 connection"
751 vars.smtp_address = "$check_address$"
752 vars.check_ipv4 = "$smtp_ipv4$"
753 vars.check_ipv6 = "$smtp_ipv6$"
756 object CheckCommand "ssmtp" {
757 import "ipv4-or-ipv6"
759 command = [ PluginDir + "/check_ssmtp" ]
763 value = "$ssmtp_address$"
764 description = "Host name, IP Address, or unix socket (must be an absolute path)"
767 value = "$ssmtp_port$"
768 description = "Port number (default: none)"
771 value = "$ssmtp_escape$"
772 description = "Can use \n, \r, \t or \\ in send or quit string. Must come before send or quit option. Default: nothing added to send, \r\n added to end of quit"
775 value = "$ssmtp_send$"
776 description = "String to send to the server"
779 value = "$ssmtp_expect$"
780 description = "String to expect in server response (may be repeated)"
783 set_if = "$ssmtp_all$"
784 description = "All expect strings need to occur in server response. Default is any."
787 value = "$ssmtp_quit$"
788 description = "String to send server to initiate a clean close of the connection"
791 value = "$ssmtp_refuse$"
792 description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
795 value = "$ssmtp_mismatch$"
796 description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
799 set_if = "$ssmtp_jail$"
800 description = "Hide output from TCP socket."
803 value = "$ssmtp_maxbytes$"
804 description = "Close connection once more than this number of bytes are received"
807 value = "$ssmtp_delay$"
808 description = "Seconds to wait between sending string and polling for response"
811 value = "$ssmtp_certificate_age$"
812 description = "Minimum number of days a certificate has to be valid"
815 set_if = "$ssmtp_ssl$"
816 description = "Use SSL for the connection."
819 value = "$ssmtp_warning$"
820 description = "Response time to result in warning status (seconds)"
823 value = "$ssmtp_critical$"
824 description = "Response time to result in critical status (seconds)"
827 value = "$ssmtp_timeout$"
828 description = "Seconds before connection times out (default: 10)"
831 set_if = "$ssmtp_ipv4$"
832 description = "Use IPv4 connection"
835 set_if = "$ssmtp_ipv6$"
836 description = "Use IPv6 connection"
840 vars.ssmtp_address = "$check_address$"
841 vars.check_ipv4 = "$ssmtp_ipv4$"
842 vars.check_ipv6 = "$ssmtp_ipv6$"
845 object CheckCommand "imap" {
846 import "ipv4-or-ipv6"
848 command = [ PluginDir + "/check_imap" ]
852 value = "$imap_address$"
853 description = "Host name, IP Address, or unix socket (must be an absolute path)"
856 value = "$imap_port$"
857 description = "Port number (default: none)"
860 value = "$imap_escape$"
861 description = "Can use \n, \r, \t or \\ in send or quit string. Must come before send or quit option. Default: nothing added to send, \r\n added to end of quit"
864 value = "$imap_send$"
865 description = "String to send to the server"
868 value = "$imap_expect$"
869 description = "String to expect in server response (may be repeated)"
872 set_if = "$imap_all$"
873 description = "All expect strings need to occur in server response. Default is any."
876 value = "$imap_quit$"
877 description = "String to send server to initiate a clean close of the connection"
880 value = "$imap_refuse$"
881 description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
884 value = "$imap_mismatch$"
885 description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
888 set_if = "$imap_jail$"
889 description = "Hide output from TCP socket."
892 value = "$imap_maxbytes$"
893 description = "Close connection once more than this number of bytes are received"
896 value = "$imap_delay$"
897 description = "Seconds to wait between sending string and polling for response"
900 value = "$imap_certificate_age$"
901 description = "Minimum number of days a certificate has to be valid"
904 set_if = "$imap_ssl$"
905 description = "Use SSL for the connection."
908 value = "$imap_warning$"
909 description = "Response time to result in warning status (seconds)"
912 value = "$imap_critical$"
913 description = "Response time to result in critical status (seconds)"
916 value = "$imap_timeout$"
917 description = "Seconds before connection times out (default: 10)"
920 set_if = "$imap_ipv4$"
921 description = "Use IPv4 connection"
924 set_if = "$imap_ipv6$"
925 description = "Use IPv6 connection"
929 vars.imap_address = "$check_address$"
930 vars.check_ipv4 = "$imap_ipv4$"
931 vars.check_ipv6 = "$imap_ipv6$"
934 object CheckCommand "simap" {
935 import "ipv4-or-ipv6"
937 command = [ PluginDir + "/check_simap" ]
941 value = "$simap_address$"
942 description = "Host name, IP Address, or unix socket (must be an absolute path)"
945 value = "$simap_port$"
946 description = "Port number (default: none)"
949 value = "$simap_escape$"
950 description = "Can use \n, \r, \t or \\ in send or quit string. Must come before send or quit option. Default: nothing added to send, \r\n added to end of quit"
953 value = "$simap_send$"
954 description = "String to send to the server"
957 value = "$simap_expect$"
958 description = "String to expect in server response (may be repeated)"
961 set_if = "$simap_all$"
962 description = "All expect strings need to occur in server response. Default is any."
965 value = "$simap_quit$"
966 description = "String to send server to initiate a clean close of the connection"
969 value = "$simap_refuse$"
970 description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
973 value = "$simap_mismatch$"
974 description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
977 set_if = "$simap_jail$"
978 description = "Hide output from TCP socket."
981 value = "$simap_maxbytes$"
982 description = "Close connection once more than this number of bytes are received"
985 value = "$simap_delay$"
986 description = "Seconds to wait between sending string and polling for response"
989 value = "$simap_certificate_age$"
990 description = "Minimum number of days a certificate has to be valid"
993 set_if = "$simap_ssl$"
994 description = "Use SSL for the connection."
997 value = "$simap_warning$"
998 description = "Response time to result in warning status (seconds)"
1001 value = "$simap_critical$"
1002 description = "Response time to result in critical status (seconds)"
1005 value = "$simap_timeout$"
1006 description = "Seconds before connection times out (default: 10)"
1009 set_if = "$simap_ipv4$"
1010 description = "Use IPv4 connection"
1013 set_if = "$simap_ipv6$"
1014 description = "Use IPv6 connection"
1018 vars.simap_address = "$check_address$"
1019 vars.check_ipv4 = "$simap_ipv4$"
1020 vars.check_ipv6 = "$simap_ipv6$"
1023 object CheckCommand "pop" {
1024 import "ipv4-or-ipv6"
1026 command = [ PluginDir + "/check_pop" ]
1030 value = "$pop_address$"
1031 description = "Host name, IP Address, or unix socket (must be an absolute path)"
1034 value = "$pop_port$"
1035 description = "Port number (default: none)"
1038 value = "$pop_escape$"
1039 description = "Can use \n, \r, \t or \\ in send or quit string. Must come before send or quit option. Default: nothing added to send, \r\n added to end of quit"
1042 value = "$pop_send$"
1043 description = "String to send to the server"
1046 value = "$pop_expect$"
1047 description = "String to expect in server response (may be repeated)"
1050 set_if = "$pop_all$"
1051 description = "All expect strings need to occur in server response. Default is any."
1054 value = "$pop_quit$"
1055 description = "String to send server to initiate a clean close of the connection"
1058 value = "$pop_refuse$"
1059 description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
1062 value = "$pop_mismatch$"
1063 description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
1066 set_if = "$pop_jail$"
1067 description = "Hide output from TCP socket."
1070 value = "$pop_maxbytes$"
1071 description = "Close connection once more than this number of bytes are received"
1074 value = "$pop_delay$"
1075 description = "Seconds to wait between sending string and polling for response"
1078 value = "$pop_certificate_age$"
1079 description = "Minimum number of days a certificate has to be valid"
1082 set_if = "$pop_ssl$"
1083 description = "Use SSL for the connection."
1086 value = "$pop_warning$"
1087 description = "Response time to result in warning status (seconds)"
1090 value = "$pop_critical$"
1091 description = "Response time to result in critical status (seconds)"
1094 value = "$pop_timeout$"
1095 description = "Seconds before connection times out (default: 10)"
1098 set_if = "$pop_ipv4$"
1099 description = "Use IPv4 connection"
1102 set_if = "$pop_ipv6$"
1103 description = "Use IPv6 connection"
1107 vars.pop_address = "$check_address$"
1108 vars.check_ipv4 = "$pop_ipv4$"
1109 vars.check_ipv6 = "$pop_ipv6$"
1112 object CheckCommand "spop" {
1113 import "ipv4-or-ipv6"
1115 command = [ PluginDir + "/check_spop" ]
1119 value = "$spop_address$"
1120 description = "Host name, IP Address, or unix socket (must be an absolute path)"
1123 value = "$spop_port$"
1124 description = "Port number (default: none)"
1127 value = "$spop_escape$"
1128 description = "Can use \n, \r, \t or \\ in send or quit string. Must come before send or quit option. Default: nothing added to send, \r\n added to end of quit"
1131 value = "$spop_send$"
1132 description = "String to send to the server"
1135 value = "$spop_expect$"
1136 description = "String to expect in server response (may be repeated)"
1139 set_if = "$spop_all$"
1140 description = "All expect strings need to occur in server response. Default is any."
1143 value = "$spop_quit$"
1144 description = "String to send server to initiate a clean close of the connection"
1147 value = "$spop_refuse$"
1148 description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
1151 value = "$spop_mismatch$"
1152 description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
1155 set_if = "$spop_jail$"
1156 description = "Hide output from TCP socket."
1159 value = "$spop_maxbytes$"
1160 description = "Close connection once more than this number of bytes are received"
1163 value = "$spop_delay$"
1164 description = "Seconds to wait between sending string and polling for response"
1167 value = "$spop_certificate_age$"
1168 description = "Minimum number of days a certificate has to be valid"
1171 set_if = "$spop_ssl$"
1172 description = "Use SSL for the connection."
1175 value = "$spop_warning$"
1176 description = "Response time to result in warning status (seconds)"
1179 value = "$spop_critical$"
1180 description = "Response time to result in critical status (seconds)"
1183 value = "$spop_timeout$"
1184 description = "Seconds before connection times out (default: 10)"
1187 set_if = "$spop_ipv4$"
1188 description = "Use IPv4 connection"
1191 set_if = "$spop_ipv6$"
1192 description = "Use IPv6 connection"
1196 vars.spop_address = "$check_address$"
1197 vars.check_ipv4 = "$spop_ipv4$"
1198 vars.check_ipv6 = "$spop_ipv6$"
1201 object CheckCommand "ntp_time" {
1202 import "ipv4-or-ipv6"
1204 command = [ PluginDir + "/check_ntp_time" ]
1208 value = "$ntp_address$"
1209 description = "Host name, IP Address, or unix socket (must be an absolute path)"
1212 value = "$ntp_port$"
1213 description = "Port number (default: 123)"
1216 set_if = "$ntp_quiet$"
1217 description = "Returns UNKNOWN instead of CRITICAL if offset cannot be found"
1220 value = "$ntp_warning$"
1221 description = "Offset to result in warning status (seconds)"
1224 value = "$ntp_critical$"
1225 description = "Offset to result in critical status (seconds)"
1228 value = "$ntp_timeoffset$"
1229 description = "Expected offset of the ntp server relative to local server (seconds)"
1232 value = "$ntp_timeout$"
1233 description = "Seconds before connection times out (default: 10)"
1236 set_if = "$ntp_ipv4$"
1237 description = "Use IPv4 connection"
1240 set_if = "$ntp_ipv6$"
1241 description = "Use IPv6 connection"
1245 vars.ntp_address = "$check_address$"
1246 vars.check_ipv4 = "$ntp_ipv4$"
1247 vars.check_ipv6 = "$ntp_ipv6$"
1250 object CheckCommand "ntp_peer" {
1251 import "ipv4-or-ipv6"
1253 command = [ PluginDir + "/check_ntp_peer" ]
1257 value = "$ntp_address$"
1258 description = "Host name, IP Address, or unix socket (must be an absolute path)"
1261 value = "$ntp_port$"
1262 description = "Port number (default: 123)"
1265 set_if = "$ntp_quiet$"
1266 description = "Returns UNKNOWN instead of CRITICAL or WARNING if server isn't synchronized"
1269 value = "$ntp_warning$"
1270 description = "Offset to result in warning status (seconds)"
1273 value = "$ntp_critical$"
1274 description = "Offset to result in critical status (seconds)"
1277 value = "$ntp_wstratum$"
1278 description = "Warning threshold for stratum of server's synchronization peer"
1281 value = "$ntp_cstratum$"
1282 description = "Critical threshold for stratum of server's synchronization peer"
1285 value = "$ntp_wjitter$"
1286 description = "Warning threshold for jitter"
1289 value = "$ntp_cjitter$"
1290 description = "Critical threshold for jitter"
1293 value = "$ntp_wsource$"
1294 description = "Warning threshold for number of usable time sources (truechimers)"
1297 value = "$ntp_csource$"
1298 description = "Critical threshold for number of usable time sources (truechimers)"
1301 value = "$ntp_timeout$"
1302 description = "Seconds before connection times out (default: 10)"
1305 set_if = "$ntp_ipv4$"
1306 description = "Use IPv4 connection"
1309 set_if = "$ntp_ipv6$"
1310 description = "Use IPv6 connection"
1314 vars.ntp_address = "$check_address$"
1315 vars.check_ipv4 = "$ntp_ipv4$"
1316 vars.check_ipv6 = "$ntp_ipv6$"
1319 object CheckCommand "ssh" {
1320 import "ipv4-or-ipv6"
1322 command = [ PluginDir + "/check_ssh" ]
1326 value = "$ssh_port$"
1327 description = "Port number (default: 22)"
1330 value = "$ssh_timeout$"
1331 description = "Seconds before connection times out (default: 10)"
1334 value = "$ssh_address$"
1339 set_if = "$ssh_ipv4$"
1340 description = "Use IPv4 connection"
1343 set_if = "$ssh_ipv6$"
1344 description = "Use IPv6 connection"
1348 vars.ssh_address = "$check_address$"
1349 vars.check_ipv4 = "$ssh_ipv4$"
1350 vars.check_ipv6 = "$ssh_ipv6$"
1353 object CheckCommand "disk" {
1354 command = [ PluginDir + "/check_disk" ]
1358 value = "$disk_wfree$"
1359 description = "Exit with WARNING status if less than INTEGER units of disk are free or Exit with WARNING status if less than PERCENT of disk space is free"
1364 value = "$disk_cfree$"
1365 description = "Exit with CRITICAL status if less than INTEGER units of disk are free or Exit with CRITCAL status if less than PERCENT of disk space is free"
1370 value = "$disk_inode_wfree$"
1371 description = "Exit with WARNING status if less than PERCENT of inode space is free"
1375 value = "$disk_inode_cfree$"
1376 description = "Exit with CRITICAL status if less than PERCENT of inode space is free"
1380 value = "$disk_partitions$"
1381 description = "Path or partition (may be repeated)"
1387 value = "$disk_partition$"
1391 value = "$disk_partitions_excluded$"
1392 description = "Ignore device (only works if -p unspecified)"
1396 value = "$disk_partition_excluded$"
1399 set_if = "$disk_clear$"
1400 description = "Clear thresholds"
1403 set_if = "$disk_exact_match$"
1404 description = "For paths or partitions specified with -p, only check for exact paths"
1407 set_if = "$disk_errors_only$"
1408 description = "Display only devices/mountpoints with errors"
1411 set_if = "$disk_ignore_reserved$"
1412 description = "Don't account root-reserved blocks into freespace in perfdata"
1415 value = "$disk_group$"
1416 description = "Group paths. Thresholds apply to (free-)space of all partitions together"
1419 set_if = "$disk_kilobytes$"
1420 description = "Same as --units kB"
1423 set_if = "$disk_local$"
1424 description = " Only check local filesystems"
1427 set_if = "$disk_stat_remote_fs$"
1428 description = "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)"
1431 set_if = "$disk_mountpoint$"
1432 description = "Display the mountpoint instead of the partition"
1435 set_if = "$disk_megabytes$"
1436 description = "Same as --units MB"
1439 set_if = "$disk_all$"
1440 description = "Explicitly select all paths. This is equivalent to -R .*"
1444 value = "$disk_eregi_path$"
1445 description = "Case insensitive regular expression for path/partition (may be repeated)"
1449 value = "$disk_ereg_path$"
1450 description = "Regular expression for path or partition (may be repeated)"
1454 value = "$disk_ignore_eregi_path$"
1455 description = "Regular expression to ignore selected path/partition (case insensitive) (may be repeated)"
1460 value = "$disk_ignore_ereg_path$"
1461 description = "Regular expression to ignore selected path or partition (may be repeated)"
1466 value = "$disk_timeout$"
1467 description = "Seconds before connection times out (default: 10)"
1470 value = "$disk_units$"
1471 description = "Choose bytes, kB, MB, GB, TB (default: MB)"
1474 value = "$disk_exclude_type$"
1475 description = "Ignore all filesystems of indicated type (may be repeated)"
1480 vars.disk_wfree = "20%"
1481 vars.disk_cfree = "10%"
1482 vars.disk_megabytes = true
1483 vars.disk_exclude_type = [
1495 "fuse.gvfs-fuse-daemon",
1502 object CheckCommand "disk_smb" {
1503 command = [ PluginDir + "/check_disk_smb" ]
1507 value = "$disk_smb_hostname$"
1508 description = "NetBIOS name of the server."
1511 value = "$disk_smb_share$"
1512 description = "Share name to be tested."
1515 value = "$disk_smb_workgroup$"
1516 description = "Workgroup or Domain used (Defaults to 'WORKGROUP' if omitted)."
1519 value = "$disk_smb_address$"
1520 description = "IP-address of HOST (only necessary if HOST is in another network)."
1523 value = "$disk_smb_username$"
1524 description = "Username to log in to server. (Defaults to 'guest' if omitted)."
1527 value = "$disk_smb_password$"
1528 description = "Password to log in to server. (Defaults to an empty password if omitted)."
1531 value = "$disk_smb_wused$"
1532 description = "Percent of used space at which a warning will be generated (Default: 85%)."
1535 value = "$disk_smb_cused$"
1536 description = "Percent of used space at which a critical will be generated (Defaults: 95%)"
1539 value = "$disk_smb_port$"
1540 description = "Port to be used to connect to. Some Windows boxes use 139, others 445 (Defaults to smbclient default if omitted)."
1544 vars.disk_smb_wused = "85%"
1545 vars.disk_smb_cused = "95%"
1548 object CheckCommand "users" {
1549 command = [ PluginDir + "/check_users" ]
1553 value = "$users_wgreater$"
1554 description = "Set WARNING status if more than INTEGER users are logged in"
1557 value = "$users_cgreater$"
1558 description = "Set CRITICAL status if more than INTEGER users are logged in"
1562 vars.users_wgreater = 20
1563 vars.users_cgreater = 50
1566 object CheckCommand "procs" {
1567 command = [ PluginDir + "/check_procs" ]
1571 value = "$procs_warning$"
1572 description = "Generate warning state if metric is outside this range"
1575 value = "$procs_critical$"
1576 description = "Generate critical state if metric is outside this range"
1579 value = "$procs_metric$"
1580 description = "Check thresholds against metric"
1583 value = "$procs_timeout$"
1584 description = "Seconds before plugin times out"
1587 set_if = "$procs_traditional$"
1588 description = "Filter own process the traditional way by PID instead of /proc/pid/exe"
1591 value = "$procs_state$"
1592 description = "Only scan for processes that have one or more of the status flags you specify"
1595 value = "$procs_ppid$"
1596 description = "Only scan for children of the parent process ID indicated"
1599 value = "$procs_vsz$"
1600 description = "Only scan for processes with VSZ higher than indicated"
1603 value = "$procs_rss$"
1604 description = "Only scan for processes with RSS higher than indicated"
1607 value = "$procs_pcpu$"
1608 description = "Only scan for processes with PCPU higher than indicated"
1611 value = "$procs_user$"
1612 description = "Only scan for processes with user name or ID indicated"
1615 value = "$procs_argument$"
1616 description = "Only scan for processes with args that contain STRING"
1618 "--ereg-argument-array" = {
1619 value = "$procs_argument_regex$"
1620 description = "Only scan for processes with args that contain the regex STRING"
1623 value = "$procs_command$"
1624 description = "Only scan for exact matches of COMMAND (without path)"
1627 set_if = "$procs_nokthreads$"
1628 description = "Only scan for non kernel threads"
1632 vars.procs_traditional = false
1633 vars.procs_nokthreads = false
1634 vars.procs_warning = 250
1635 vars.procs_critical = 400
1638 object CheckCommand "swap" {
1639 command = [ PluginDir + "/check_swap" ]
1643 if (macro("$swap_integer$")) {
1644 return macro("$swap_wfree$")
1646 return macro("$swap_wfree$%")
1650 if (macro("$swap_integer$")) {
1651 return macro("$swap_cfree$")
1653 return macro("$swap_cfree$%")
1657 set_if = "$swap_allswaps$"
1658 description = "Conduct comparisons for all swap partitions, one by one"
1661 value = "$swap_noswap$"
1662 description = "Resulting state when there is no swap regardless of thresholds. Possible values are \"ok\", \"warning\", \"critical\", \"unknown\". Defaults to \"critical\""
1666 vars.swap_wfree = 50
1667 vars.swap_cfree = 25
1668 vars.swap_integer = false
1669 vars.swap_allswaps = false
1672 object CheckCommand "load" {
1673 command = [ PluginDir + "/check_load" ]
1677 value = "$load_wload1$,$load_wload5$,$load_wload15$"
1678 description = "Exit with WARNING status if load average exceeds WLOADn"
1681 value = "$load_cload1$,$load_cload5$,$load_cload15$"
1682 description = "Exit with CRITICAL status if load average exceed CLOADn; the load average format is the same used by 'uptime' and 'w'"
1685 set_if = "$load_percpu$"
1686 description = "Divide the load averages by the number of CPUs (when possible)"
1690 vars.load_wload1 = 5.0
1691 vars.load_wload5 = 4.0
1692 vars.load_wload15 = 3.0
1694 vars.load_cload1 = 10.0
1695 vars.load_cload5 = 6.0
1696 vars.load_cload15 = 4.0
1698 vars.load_percpu = false
1701 object CheckCommand "snmp" {
1702 command = [ PluginDir + "/check_snmp" ]
1706 value = "$snmp_address$"
1707 description = "Host name, IP Address, or unix socket (must be an absolute path)"
1710 value = "$snmp_oid$"
1711 description = "Object identifier(s) or SNMP variables whose value you wish to query"
1714 value = "$snmp_community$"
1715 description = "Optional community string for SNMP communication (default is 'public')"
1718 value = "$snmp_crit$"
1719 description = "Critical threshold range(s)"
1722 value = "$snmp_warn$"
1723 description = "Warning threshold range(s)"
1726 value = "$snmp_string$"
1727 description = "Return OK state (for that OID) if STRING is an exact match"
1730 value = "$snmp_ereg$"
1731 description = "Return OK state (for that OID) if extended regular expression REGEX matches"
1734 value = "$snmp_eregi$"
1735 description = "Return OK state (for that OID) if case-insensitive extended REGEX matches"
1738 value = "$snmp_label$"
1739 description = "Prefix label for output from plugin"
1742 value = "$snmp_units$"
1743 description = "Units label(s) for output data (e.g., 'sec.')"
1746 value = "$snmp_timeout$"
1747 description = "Seconds before connection times out (default: 10)"
1750 value = "$snmp_port$"
1751 description = "Port number (default: 161)"
1754 value = "$snmp_retries$"
1755 description = "Number of retries to be used in the requests"
1757 "--invert-search" = {
1758 set_if = "$snmp_invert_search$"
1759 description = "Invert search result and return CRITICAL if found"
1762 value = "$snmp_version$"
1763 description = "SNMP protocol version"
1766 value = "$snmp_miblist$"
1767 description = "List of MIBS to be loaded (default = none if using numeric OIDs or 'ALL' for symbolic OIDs.)"
1769 "--rate-multiplier" = {
1770 value = "$snmp_rate_multiplier$"
1771 description = "Converts rate per second. For example, set to 60 to convert to per minute"
1774 set_if = "$snmp_rate$"
1775 description = "Enable rate calculation"
1778 set_if = "$snmp_getnext$"
1779 description = "Use SNMP GETNEXT instead of SNMP GET"
1782 value = "$snmp_offset$"
1783 description = "Add/substract the specified OFFSET to numeric sensor data"
1786 value = "$snmp_output_delimiter$"
1787 description = "Separates output on multiple OID requests"
1790 set_if = "$snmp_perf_oids$"
1791 description = "Label performance data with OIDs instead of --label's"
1795 vars.snmp_address = {{
1796 var addr_v4 = macro("$address$")
1797 var addr_v6 = macro("$address6$")
1802 return "udp6:[" + addr_v6 + "]"
1806 vars.snmp_community = "public"
1807 vars.snmp_invert_search = false
1808 vars.snmp_timeout = "10"
1811 object CheckCommand "snmpv3" {
1812 import "ipv4-or-ipv6"
1814 command = [ PluginDir + "/check_snmp" ]
1818 value = "$snmpv3_address$"
1819 description = "Host name, IP Address, or unix socket (must be an absolute path)"
1822 value = "$snmpv3_port$"
1823 description = "Port number"
1826 set_if = "$snmpv3_getnext$"
1827 description = "Use SNMP GETNEXT instead of SNMP GET"
1831 description = "SNMP protocol version"
1834 value = "$snmpv3_seclevel$"
1835 description = "SNMPv3 securityLevel"
1838 value = "$snmpv3_auth_alg$"
1839 description = "SNMPv3 auth proto"
1842 value = "$snmpv3_user$"
1843 description = "SNMPv3 username"
1846 value = "$snmpv3_auth_key$"
1847 description = "SNMPv3 authentication password"
1850 value = "$snmpv3_priv_key$"
1851 description = "SNMPv3 privacy password"
1854 value = "$snmpv3_oid$"
1855 description = "Object identifier(s) or SNMP variables whose value you wish to query"
1858 value = "$snmpv3_priv_alg$"
1859 description = "SNMPv3 priv proto (default DES)"
1862 value = "$snmpv3_warn$"
1863 description = "Warning threshold range(s)"
1866 value = "$snmpv3_crit$"
1867 description = "Critical threshold range(s)"
1870 value = "$snmpv3_string$"
1871 description = "Return OK state (for that OID) if STRING is an exact match"
1874 value = "$snmpv3_ereg$"
1875 description = "Return OK state (for that OID) if extended regular expression REGEX matches"
1878 value = "$snmpv3_eregi$"
1879 description = "Return OK state (for that OID) if case-insensitive extended REGEX matches"
1881 "--invert-search" = {
1882 set_if = "$snmpv3_invert_search$"
1883 description = "Invert search result and return CRITICAL if found"
1886 value = "$snmpv3_label$"
1887 description = "Prefix label for output from plugin"
1890 value = "$snmpv3_miblist$"
1891 description = "List of SNMP MIBs for translating OIDs between numeric and textual representation"
1894 value = "$snmpv3_units$"
1895 description = "Units label(s) for output data (e.g., 'sec.')"
1897 "--rate-multiplier" = {
1898 value = "$snmpv3_rate_multiplier$"
1899 description = "Converts rate per second. For example, set to 60 to convert to per minute"
1902 set_if = "$snmpv3_rate$"
1903 description = "Enable rate calculation"
1906 value = "$snmpv3_timeout$"
1907 description = "Seconds before connection times out (default: 10)"
1911 vars.snmpv3_address = "$check_address$"
1912 vars.snmpv3_auth_alg = "SHA"
1913 vars.snmpv3_priv_alg = "AES"
1914 vars.snmpv3_seclevel = "authPriv"
1915 vars.snmpv3_timeout = "10"
1918 object CheckCommand "snmp-uptime" {
1921 vars.snmp_oid = "1.3.6.1.2.1.1.3.0"
1924 object CheckCommand "apt" {
1925 command = [ PluginDir + "/check_apt" ]
1929 value = "$apt_extra_opts$"
1930 description = "Read options from an ini file."
1933 value = "$apt_upgrade$"
1934 description = "[Default] Perform an upgrade. If an optional OPTS argument is provided, apt-get will be run with these command line options instead of the default."
1936 "--dist-upgrade" = {
1937 value = "$apt_dist_upgrade$"
1938 description = "Perform a dist-upgrade instead of normal upgrade. Like with -U OPTS can be provided to override the default options."
1941 value = "$apt_include$"
1942 description = "Include only packages matching REGEXP. Can be specified multiple times the values will be combined together."
1945 value = "$apt_exclude$"
1946 description = "Exclude packages matching REGEXP from the list of packages that would otherwise be included. Can be specified multiple times."
1949 value = "$apt_critical$"
1950 description = "If the full package information of any of the upgradable packages match this REGEXP, the plugin will return CRITICAL status. Can be specified multiple times."
1953 value = "$apt_timeout$"
1954 description = "Seconds before plugin times out (default: 10)."
1956 "--only-critical" = {
1957 set_if = "$apt_only_critical$"
1958 description = "Only warn about critical upgrades."
1965 object CheckCommand "dhcp" {
1966 command = [ PluginDir + "/check_dhcp" ]
1970 value = "$dhcp_serverip$"
1971 description = "IP address of DHCP server that we must hear from"
1974 value = "$dhcp_requestedip$"
1975 description = "IP address that should be offered by at least one DHCP server"
1978 value = "$dhcp_timeout$"
1979 description = "Seconds to wait for DHCPOFFER before timeout occurs"
1982 value = "$dhcp_interface$"
1983 description = "Interface to to use for listening (i.e. eth0)"
1986 value = "$dhcp_mac$"
1987 description = "MAC address to use in the DHCP request"
1990 set_if = "$dhcp_unicast$"
1991 description = "Unicast testing: mimic a DHCP relay"
1995 vars.dhcp_unicast = false
1998 object CheckCommand "dns" {
1999 import "ipv4-or-ipv6"
2001 command = [ PluginDir + "/check_dns" ]
2005 value = "$dns_lookup$"
2006 description = "The name or address you want to query."
2009 value = "$dns_server$"
2010 description = "Optional DNS server you want to use for the lookup."
2013 value = "$dns_query_type$"
2014 description = "Optional DNS record query type where TYPE =(A, AAAA, SRV, TXT, MX, ANY). The default query type is 'A' (IPv4 host entry)"
2017 value = "$dns_expected_answers$"
2018 description = "Optional ip address or host you expect the DNS server to return. Host must end with a dot (.). This option can be repeated multiple times (Returns OK if any value match). If multiple addresses are returned at once, you have to match the whole string of addresses separated with commas (sorted alphabetically)."
2021 set_if = "$dns_authoritative$"
2022 description = "Optionally expect the DNS server to be authoritative for the lookup"
2025 set_if = "$dns_accept_cname$"
2026 description = "Optionally accept cname responses as a valid result to a query. The default is to ignore cname responses as part of the result"
2029 value = "$dns_wtime$"
2030 description = "Return warning if elapsed time exceeds value."
2033 value = "$dns_ctime$"
2034 description = "Return critical if elapsed time exceeds value."
2037 value = "$dns_timeout$"
2038 description = "Seconds before connection times out. Defaults to 10."
2042 vars.dns_lookup = "$host.name$"
2043 vars.dns_timeout = 10
2046 object CheckCommand "dig" {
2047 import "ipv4-or-ipv6"
2049 command = [ PluginDir + "/check_dig" ]
2053 value = "$dig_server$"
2054 description = "Host name, IP Address, or unix socket (must be an absolute path)"
2057 value = "$dig_port$"
2058 description = "Port number (default: 53)"
2061 value = "$dig_lookup$"
2063 description = "Machine name to lookup"
2066 value = "$dig_record_type$"
2067 description = "Record type to lookup (default: A)"
2070 value = "$dig_expected_address$"
2071 description = "An address expected to be in the answer section"
2074 value = "$dig_arguments$"
2075 description = "Pass STRING as argument(s) to dig"
2078 value = "$dig_warning$"
2079 description = "Response time to result in warning status (seconds)"
2082 value = "$dig_critical$"
2083 description = "Response time to result in critical status (seconds)"
2086 value = "$dig_timeout$"
2087 description = "Seconds before connection times out (default: 10)"
2090 set_if = "$dig_ipv4$"
2091 description = "Force dig to only use IPv4 query transport"
2094 set_if = "$dig_ipv6$"
2095 description = "Force dig to only use IPv6 query transport"
2099 vars.dig_server = "$check_address$"
2100 vars.check_ipv4 = "$dig_ipv4$"
2101 vars.check_ipv6 = "$dig_ipv6$"
2104 object CheckCommand "nscp" {
2105 import "ipv4-or-ipv6"
2107 command = [ PluginDir + "/check_nt" ]
2111 value = "$nscp_address$"
2112 description = "Name of the host to check"
2115 value = "$nscp_port$"
2116 description = "Optional port number (default: 1248)"
2119 value = "$nscp_password$"
2120 description = "Password needed for the request"
2123 value = "$nscp_variable$"
2125 description = "Variable to check"
2128 value = "$nscp_params$"
2132 value = "$nscp_warn$"
2133 description = "Threshold which will result in a warning status"
2136 value = "$nscp_crit$"
2137 description = "Threshold which will result in a critical status"
2140 value = "$nscp_timeout$"
2141 description = "Seconds before connection attempt times out"
2145 set_if = "$nscp_showall$"
2146 description = "Use with SERVICESTATE to see working services or PROCSTATE for running processes"
2150 vars.nscp_address = "$check_address$"
2151 vars.nscp_port = 12489
2152 vars.nscp_showall = false
2155 object CheckCommand "by_ssh" {
2156 import "ipv4-or-ipv6"
2158 command = [ PluginDir + "/check_by_ssh" ]
2162 value = "$by_ssh_address$"
2163 description = "Host name, IP Address, or unix socket (must be an absolute path)"
2166 value = "$by_ssh_port$"
2167 description = "Port number (default: none)"
2170 var command = macro("$by_ssh_command$")
2171 var arguments = macro("$by_ssh_arguments$")
2173 if (typeof(command) == String && !arguments) {
2177 var escaped_args = []
2178 for (arg in resolve_arguments(command, arguments)) {
2179 escaped_args.add(escape_shell_arg(arg))
2181 return escaped_args.join(" ")
2184 value = "$by_ssh_logname$"
2185 description = "SSH user name on remote host [optional]"
2188 value = "$by_ssh_identity$"
2189 description = "identity of an authorized key [optional]"
2192 set_if = "$by_ssh_quiet$"
2193 description = "Tell ssh to suppress warning and diagnostic messages [optional]"
2196 value = "$by_ssh_warn$"
2197 description = "Response time to result in warning status (seconds)"
2200 value = "$by_ssh_crit$"
2201 description = "Response time to result in critical status (seconds)"
2204 value = "$by_ssh_timeout$"
2205 description = "Seconds before connection times out (default: 10)"
2208 value = "$by_ssh_options$"
2209 description = "Provide ssh options (may be repeated)"
2212 set_if = "$by_ssh_ipv4$"
2213 description = "Use IPv4 only"
2216 set_if = "$by_ssh_ipv6$"
2217 description = "Use IPv6 only"
2220 value = "$by_ssh_skip_stderr$"
2221 description = "Ignore all or (if specified) first n lines on STDERR [optional]"
2225 vars.by_ssh_address = "$check_address$"
2226 vars.by_ssh_quiet = false
2227 vars.check_ipv4 = "$by_ssh_ipv4$"
2228 vars.check_ipv6 = "$by_ssh_ipv6$"
2231 object CheckCommand "ups" {
2232 import "ipv4-or-ipv6"
2234 command = [ PluginDir + "/check_ups" ]
2238 value = "$ups_address$"
2239 description = "Address of the upsd server"
2243 value = "$ups_name$"
2244 description = "Name of the UPS to monitor"
2248 value = "$ups_port$"
2249 description = "Port number (default: 3493)"
2252 value = "$ups_variable$"
2253 description = "Variable to monitor, valid strings are LINE, TEMP, BATTPCT or LOADPCT"
2256 value = "$ups_warning$"
2257 description = "Warning threshold for the selected variable"
2260 value = "$ups_critical$"
2261 description = "Critical threshold for the selected variable"
2264 set_if = "$ups_celsius$"
2265 description = "Display temperature in degrees Celsius instead of Fahrenheit"
2268 value = "$ups_timeout$"
2269 description = "Seconds before the connection times out (default: 10)"
2273 vars.ups_address = "$check_address$"
2274 vars.ups_name = "ups"
2277 object CheckCommand "nrpe" {
2278 import "ipv4-or-ipv6"
2280 command = [ PluginDir + "/check_nrpe" ]
2284 value = "$nrpe_address$"
2285 description = "The address of the host running the NRPE daemon"
2288 value = "$nrpe_port$"
2291 value = "$nrpe_command$"
2294 set_if = "$nrpe_no_ssl$"
2295 description = "Do not use SSL"
2298 set_if = "$nrpe_timeout_unknown$"
2299 description = "Make socket timeouts return an UNKNOWN state instead of CRITICAL"
2302 value = "$nrpe_timeout$"
2303 description = "<interval>:<state> = <Number of seconds before connection times out>:<Check state to exit with in the event of a timeout (default=CRITICAL)>"
2306 value = "$nrpe_arguments$"
2311 set_if = "$nrpe_ipv4$"
2312 description = "Use IPv4 connection"
2315 set_if = "$nrpe_ipv6$"
2316 description = "Use IPv6 connection"
2319 set_if = "$nrpe_version_2$"
2320 description = "Use this if you want to connect to NRPE v2"
2324 vars.nrpe_address = "$check_address$"
2325 vars.nrpe_no_ssl = false
2326 vars.nrpe_timeout_unknown = false
2327 vars.check_ipv4 = "$nrpe_ipv4$"
2328 vars.check_ipv6 = "$nrpe_ipv6$"
2329 vars.nrpe_version_2 = false
2333 object CheckCommand "hpjd" {
2334 import "ipv4-or-ipv6"
2336 command = [ PluginDir + "/check_hpjd" ]
2340 value = "$hpjd_address$"
2341 description = "Host address"
2344 value = "$hpjd_community$"
2345 description = "The SNMP community name (default=public)"
2348 value = "$hpjd_port$"
2349 description = "Specify the port to check (default=161)"
2353 vars.hpjd_address = "$check_address$"
2356 object CheckCommand "icmp" {
2357 command = [ PluginDir + "/check_icmp" ]
2361 value = "$icmp_address$"
2364 description = "Host address"
2367 value = "$icmp_wrta$,$icmp_wpl$%"
2368 description = "warning threshold (currently 200.000ms,40%)"
2371 value = "$icmp_crta$,$icmp_cpl$%"
2372 description = "critical threshold (currently 500.000ms,80%)"
2375 value = "$icmp_source$"
2376 description = "specify a source IP address or device name"
2379 value = "$icmp_packets$"
2380 description = "number of packets to send (currently 5)"
2383 value = "$icmp_packet_interval$"
2384 description = "max packet interval (currently 80.000ms)"
2387 value = "$icmp_target_interval$"
2388 description = "max target interval (currently 0.000ms)"
2391 value = "$icmp_hosts_alive$"
2392 description = "number of alive hosts required for success"
2395 value = "$icmp_data_bytes$"
2396 description = "Number of icmp data bytes to send. Packet size will be data bytes + icmp header (currently 68 + 8)"
2399 value = "$icmp_timeout$"
2400 description = "timeout value (seconds, currently 10)"
2403 value = "$icmp_ttl$"
2404 description = "TTL on outgoing packets (currently 0)"
2408 vars.icmp_address = "$address$"
2409 vars.icmp_wrta = 100
2411 vars.icmp_crta = 200
2415 object CheckCommand "ldap" {
2416 import "ipv4-or-ipv6"
2418 command = [ PluginDir + "/check_ldap" ]
2422 value = "$ldap_address$"
2423 description = "Host name, IP Address, or unix socket (must be an absolute path)"
2426 value = "$ldap_port$"
2427 description = "Port number (default: 389)"
2430 value = "$ldap_attr$"
2431 description = "ldap attribute to search (default: \"(objectclass=*)\""
2434 value = "$ldap_base$"
2436 description = "ldap base (eg. ou=my unit, o=my org, c=at"
2439 value = "$ldap_bind$"
2440 description = "ldap bind DN (if required)"
2443 value = "$ldap_pass$"
2444 description = "ldap password (if required)"
2447 set_if = "$ldap_starttls$"
2448 description = "use starttls mechanism introduced in protocol version 3"
2451 set_if = "$ldap_ssl$"
2452 description = "use ldaps (ldap v2 ssl method). this also sets the default port to 636"
2455 set_if = "$ldap_v2$"
2456 description = "Use LDAP protocol version 2"
2459 set_if = "$ldap_v3$"
2460 description = "Use LDAP protocol version 3"
2463 value = "$ldap_warning$"
2464 description = "Response time to result in warning status (seconds)"
2467 value = "$ldap_critical$"
2468 description = "Response time to result in critical status (seconds)"
2471 value = "$ldap_warning_entries$"
2472 description = "Number of found entries to result in warning status (optional)"
2475 value = "$ldap_critical_entries$"
2476 description = "Number of found entries to result in critical status (optional)"
2479 value = "$ldap_timeout$"
2480 description = "Seconds before connection times out (default: 10)"
2483 set_if = "$ldap_verbose$"
2484 description = "Show details for command-line debugging"
2488 vars.ldap_address = "$check_address$"
2490 vars.ldap_v3 = false
2491 vars.ldap_timeout = 10s
2492 vars.ldap_verbose = false
2495 object CheckCommand "clamd" {
2496 command = [ PluginDir + "/check_clamd" ]
2500 value = "$clamd_address$"
2501 description = "The host's address or unix socket (must be an absolute path)."
2505 value = "$clamd_port$"
2506 description = "Port number (default: none)."
2509 value = "$clamd_expect$"
2510 description = "String to expect in server response (may be repeated)."
2514 set_if = "$clamd_all$"
2515 description = "All expect strings need to occur in server response. Default is any."
2520 set_if = "$clamd_escape_send$"
2521 description = "Enable usage of \n, \r, \t or \\ in send string. Default is nothing."
2525 value = "$clamd_send$"
2526 description = "String to send to the server."
2531 set_if = "$clamd_escape_quit$"
2532 description = "Can use \n, \r, \t or \\ in quit string. Default is \r\n added to end of quit."
2536 value = "$clamd_quit$"
2537 description = "String to send server to initiate a clean close of the connection."
2540 value = "$clamd_refuse$"
2541 description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
2544 value = "$clamd_mismatch$"
2545 description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
2548 set_if = "$clamd_jail$"
2549 description = "Hide output from TCP socket."
2552 value = "$clamd_maxbytes$"
2553 description = "Close connection once more than this number of bytes are received."
2556 value = "$clamd_delay$"
2557 description = "Seconds to wait between sending string and polling for response."
2560 value = "$clamd_certificate$"
2561 description = "Minimum number of days a certificate has to be valid. 1st value is number of days for warning, 2nd is critical (if not specified: 0) - seperated by comma."
2564 set_if = "$clamd_ssl$"
2565 description = "Use SSL for the connection."
2568 value = "$clamd_wtime$"
2569 description = "Response time to result in warning status (seconds)."
2572 value = "$clamd_ctime$"
2573 description = "Response time to result in critical status (seconds)."
2576 value = "$clamd_timeout$"
2577 description = "Seconds before connection times out. Defaults to 10."
2580 set_if = "$clamd_ipv4$"
2581 description = "Use IPv4 only"
2584 set_if = "$clamd_ipv6$"
2585 description = "Use IPv6 only"
2589 vars.clamd_ssl = false
2590 vars.clamd_refuse = "crit"
2591 vars.clamd_mismatch = "warn"
2592 vars.clamd_timeout = 10
2593 vars.check_ipv4 = "$clamd_ipv4$"
2594 vars.check_ipv6 = "$clamd_ipv6$"
2597 object CheckCommand "mailq" {
2598 command = [ PluginDir + "/check_mailq" ]
2602 value = "$mailq_warning$"
2603 description = "Min. number of messages in queue to generate warning"
2607 value = "$mailq_critical$"
2608 description = "Min. number of messages in queue to generate critical alert ( w < c )"
2612 value = "$mailq_domain_warning$"
2613 description = "Min. number of messages for same domain in queue to generate warning"
2616 value = "$mailq_domain_critical$"
2617 description = "Min. number of messages for same domain in queue to generate critical alert ( W < C )"
2620 value = "$mailq_timeout$"
2621 description = "Plugin timeout in seconds (default = 15)"
2624 value = "$mailq_servertype$"
2625 description = "[ sendmail | qmail | postfix | exim | nullmailer ] (default = autodetect)"
2628 set_if = "$mailq_sudo$"
2629 description = "Use sudo for mailq command"
2634 object CheckCommand "pgsql" {
2635 import "ipv4-or-ipv6"
2637 command = [ PluginDir + "/check_pgsql" ]
2641 value = "$pgsql_hostname$"
2642 description = "Host name, IP Address, or unix socket (must be an absolute path)"
2645 value = "$pgsql_port$"
2646 description = "Port number (default: 5432)"
2649 value = "$pgsql_database$"
2650 description = "Database to check (default: template1)"
2653 value = "$pgsql_username$"
2654 description = "Login name of user"
2657 value = "$pgsql_password$"
2658 description = "Password (BIG SECURITY ISSUE)"
2661 value = "$pgsql_options$"
2662 description = "Connection parameters (keyword = value), see below"
2665 value = "$pgsql_warning$"
2666 description = "Response time to result in warning status (seconds)"
2669 value = "$pgsql_critical$"
2670 description = "Response time to result in critical status (seconds)"
2673 value = "$pgsql_timeout$"
2674 description = "Seconds before connection times out (default: 10)"
2677 value = "$pgsql_query$"
2678 description = "SQL query to run. Only first column in first row will be read"
2681 value = "$pgsql_query_warning$"
2682 description = "SQL query value to result in warning status (double)"
2685 value = "$pgsql_query_critical$"
2686 description = "SQL query value to result in critical status (double)"
2690 vars.pgsql_hostname = "$check_address$"
2693 object CheckCommand "mysql" {
2694 import "ipv4-or-ipv6"
2696 command = [ PluginDir + "/check_mysql" ]
2700 value = "$mysql_hostname$"
2701 description = "Host name, IP Address, or unix socket (must be an absolute path)"
2704 value = "$mysql_port$"
2705 description = "Port number (default: 3306)"
2708 set_if = "$mysql_ignore_auth$"
2709 description = "Ignore authentication failure and check for mysql connectivity only"
2712 value = "$mysql_socket$"
2713 description = "Use the specified socket"
2716 value = "$mysql_database$"
2717 description = "Check database with indicated name"
2720 value = "$mysql_file$"
2721 description = "Read from the specified client options file"
2724 value = "$mysql_group$"
2725 description = "Use a client options group"
2728 value = "$mysql_username$"
2729 description = "Connect using the indicated username"
2732 value = "$mysql_password$"
2733 description = "Use the indicated password to authenticate the connection"
2736 set_if = "$mysql_check_slave$"
2737 description = "Check if the slave thread is running properly"
2740 value = "$mysql_warning$"
2741 description = "Exit with WARNING status if slave server is more than INTEGER seconds behind master"
2744 value = "$mysql_critical$"
2745 description = "Exit with CRITICAL status if slave server is more then INTEGER seconds behind master"
2748 set_if = "$mysql_ssl$"
2749 description = "Use ssl encryptation"
2752 value = "$mysql_cacert$"
2753 description = "Path to CA signing the cert"
2756 value = "$mysql_cert$"
2757 description = "Path to SSL certificate"
2760 value = "$mysql_key$"
2761 description = "Path to private SSL key"
2764 value = "$mysql_cadir$"
2765 description = "Path to CA directory"
2768 value = "$mysql_ciphers$"
2769 description = "List of valid SSL ciphers"
2773 vars.mysql_hostname = "$check_address$"
2776 object CheckCommand "negate" {
2777 command = [ PluginDir + "/negate" ]
2781 value = "$negate_timeout$"
2782 description = "Seconds before plugin times out (default: 11)"
2785 value = "$negate_timeout_result$"
2786 description = "Custom result on Negate timeouts"
2789 value = "$negate_ok$"
2792 value = "$negate_warning$"
2795 value = "$negate_critical$"
2798 value = "$negate_unknown$"
2801 set_if = "$negate_substitute$"
2802 description = "Substitute output text as well. Will only substitute text in CAPITALS"
2804 "--wrapped-plugin" = {
2806 var command = macro("$negate_command$")
2807 var arguments = macro("$negate_arguments$")
2809 if (typeof(command) == String && !arguments) {
2813 var escaped_args = []
2814 for (arg in resolve_arguments(command, arguments)) {
2815 escaped_args.add(arg)
2817 return escaped_args.join(" ")
2824 vars.negate_timeout_result = "UNKNOWN"
2827 object CheckCommand "file_age" {
2828 command = [ PluginDir + "/check_file_age" ]
2832 value = "$file_age_warning_time$"
2833 description = "File must be no more than this many seconds old (default: 240s)"
2836 value = "$file_age_critical_time$"
2837 description = "File must be no more than this many seconds old (default: 600s)"
2840 value = "$file_age_warning_size$"
2841 description = "File must be at least this many bytes long"
2844 value = "$file_age_critical_size$"
2845 description = "File must be at least this many bytes long (default: 0B)"
2848 set_if = "$file_age_ignoremissing$"
2849 description = "return OK if the file does not exist"
2852 value = "$file_age_file$"
2853 description = "File to monitor"
2857 vars.file_age_ignoremissing = false
2860 object CheckCommand "smart" {
2861 command = [ PluginDir + "/check_ide_smart" ]
2865 value = "$smart_device$"
2866 description = "Name of a local hard drive to monitor"
2872 object CheckCommand "breeze" {
2873 import "ipv4-or-ipv6"
2875 command = [ PluginDir + "/check_breeze" ]
2879 value = "$breeze_hostname$"
2880 description = "Name or IP address of host to check"
2884 value = "$breeze_community$"
2885 description = "SNMPv1 community (default public)"
2888 value = "$breeze_warning$"
2889 description = "Percentage strength below which a WARNING status will result"
2893 value = "$breeze_critical$"
2894 description = "Percentage strength below which a CRITICAL status will result"
2899 vars.breeze_hostname = "$check_address$"
2900 vars.breeze_warning = "50"
2901 vars.breeze_critical = "20"
2904 object CheckCommand "flexlm" {
2905 command = [ PluginDir + "/check_flexlm" ]
2909 value = "$flexlm_licensefile$"
2910 description = "Name of license file (usually license.dat)"
2914 value = "$flexlm_timeout$"
2915 description = "Plugin time out in seconds (default = 15)"
2920 object CheckCommand "game" {
2921 import "ipv4-or-ipv6"
2923 command = [ PluginDir + "/check_game" ]
2927 value = "$game_port$"
2928 description = "Port to connect to"
2931 value = "$game_timeout$"
2932 description = "Seconds before connection times out (default: 10)"
2935 value = "$game_gamefield$"
2936 description = "Field number in raw qstat output that contains game name"
2939 value = "$game_mapfield$"
2940 description = "Field number in raw qstat output that contains map name"
2943 value = "$game_pingfield$"
2944 description = "Field number in raw qstat output that contains ping time"
2947 value = "$game_gametime$"
2948 description = "Field number in raw qstat output that contains game time"
2951 value = "$game_hostname$"
2952 description = "Name of the host running the game"
2955 value = "$game_game$"
2956 description = "Name of the game"
2961 value = "$game_ipaddress$"
2962 description = "Ipaddress of the game server to query"
2969 object CheckCommand "mysql_query" {
2970 import "ipv4-or-ipv6"
2972 command = [ PluginDir + "/check_mysql_query" ]
2976 value = "$mysql_query_hostname$"
2977 description = "Host name, IP Address, or unix socket (must be an absolute path)"
2980 value = "$mysql_query_port$"
2981 description = "Port number (default: 3306)"
2984 value = "$mysql_query_username$"
2985 description = "Username to login with"
2988 value = "$mysql_query_password$"
2989 description = "Password to login with"
2992 value = "$mysql_query_database$"
2993 description = "Database to check"
2996 value = "$mysql_query_file$"
2997 description = "Read from the specified client options file"
3000 value = "$mysql_query_group$"
3001 description = "Use a client options group"
3004 value = "$mysql_query_execute$"
3005 description = "SQL query to run. Only first column in first row will be read"
3008 value = "$mysql_query_warning$"
3009 description = "Warning range (format: start:end). Alert if outside this range"
3012 value = "$mysql_query_critical$"
3013 description = "Critical range"
3017 vars.mysql_query_hostname = "$check_address$"
3020 object CheckCommand "radius" {
3021 import "ipv4-or-ipv6"
3024 PluginDir + "/check_radius",
3029 value = "$radius_address$",
3030 description = "Host name, IP Address, or unix socket (must be an absolute path)"
3033 value = "$radius_config_file$",
3034 description = "Configuration file"
3037 value = "$radius_username$",
3038 description = "The user to authenticate"
3041 value = "$radius_password$",
3042 description = "Password for authentication"
3045 value = "$radius_port$",
3046 description = "Port number (default: 1645)"
3049 value = "$radius_nas_id$",
3050 description = "NAS identifier"
3053 value = "$radius_nas_address$",
3054 description = "NAS IP Address"
3057 value = "$radius_expect$",
3058 description = "Response string to expect from the server"
3061 value = "$radius_retries$",
3062 description = "Number of times to retry a failed connection"
3065 value = "$radius_timeout$",
3066 description = "Seconds before connection times out (default: 10) Optional :<timeout state> can be a state integer (0,1,2,3) or a state STRING"
3070 vars.radius_address = "$check_address$"
3073 object CheckCommand "nscp_api" {
3074 import "ipv4-or-ipv6"
3076 command = [ PluginDir + "/check_nscp_api" ]
3080 value = "$nscp_api_host$"
3081 description = "NSCP API host address"
3085 value = "$nscp_api_port$"
3086 description = "NSCP API host port. Defaults to 8443."
3089 value = "$nscp_api_password$"
3090 description = "NSCP API password"
3093 value = "$nscp_api_query$"
3094 description = "NSCPI API Query endpoint to use"
3097 value = "$nscp_api_arguments$"
3098 description = "NSCP API Query arguments"
3103 vars.nscp_api_host = "$check_address$"
3106 object CheckCommand "rpc" {
3107 import "ipv4-or-ipv6"
3109 command = [ PluginDir + "/check_rpc" ]
3113 value = "$rpc_address$"
3114 description = "RPC host address"
3118 value = "$rpc_command$"
3119 description = "Programm name (or number)"
3123 value = "$rpc_port$"
3124 description = "RPC port"
3127 value = "$rpc_version$"
3128 description = "The version to check"
3131 set_if = "$rpc_udp$"
3132 description = "Test UDP"
3135 set_if = "$rpc_tcp$"
3136 description = "Test TCP"
3139 set_if = "$rpc_verbose$"
3140 description = "Show verbose details"
3144 vars.rpc_address = "$check_address$"