]> granicus.if.org Git - icinga2/blob - itl/command-plugins.conf
add order tags to disk check
[icinga2] / itl / command-plugins.conf
1 /******************************************************************************
2  * Icinga 2                                                                   *
3  * Copyright (C) 2012-2017 Icinga Development Team (https://www.icinga.com/)  *
4  *                                                                            *
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.                     *
9  *                                                                            *
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.                               *
14  *                                                                            *
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  ******************************************************************************/
19
20 template CheckCommand "ipv4-or-ipv6" {
21         vars.check_address = {{
22                 var addr_v4 = macro("$address$")
23                 var addr_v6 = macro("$address6$")
24
25                 if (addr_v4 && !macro("$check_ipv6$") || macro("$check_ipv4$")) {
26                         return addr_v4
27                 } else {
28                         return addr_v6
29                 }
30         }}
31
32         vars.check_ipv4 = false
33         vars.check_ipv6 = false
34 }
35
36 template CheckCommand "ping-common" {
37         command = [ PluginDir + "/check_ping" ]
38
39         arguments = {
40                 "-H" = {
41                         value = "$ping_address$"
42                         description = "host to ping"
43                 }
44                 "-w" = {
45                         value = "$ping_wrta$,$ping_wpl$%"
46                         description = "warning threshold pair"
47                 }
48                 "-c" = {
49                         value = "$ping_crta$,$ping_cpl$%"
50                         description = "critical threshold pair"
51                 }
52                 "-p" = {
53                         value = "$ping_packets$"
54                         description = "number of ICMP ECHO packets to send (Default: 5)"
55                 }
56                 "-t" = {
57                         value = "$ping_timeout$"
58                         description = "Seconds before connection times out (default: 10)"
59                 }
60         }
61
62         vars.ping_wrta = 100
63         vars.ping_wpl = 5
64         vars.ping_crta = 200
65         vars.ping_cpl = 15
66 }
67
68 object CheckCommand "ping" {
69         import "ping-common"
70         import "ipv4-or-ipv6"
71
72         vars.ping_address = "$check_address$"
73 }
74
75 object CheckCommand "ping4" {
76         import "ping-common"
77
78         command += [ "-4" ]
79
80         vars.ping_address = "$address$"
81 }
82
83 object CheckCommand "ping6" {
84         import "ping-common"
85
86         command += [ "-6" ]
87
88         vars.ping_address = "$address6$"
89 }
90
91 template CheckCommand "hostalive-common" {
92         vars.ping_wrta = 3000.0
93         vars.ping_wpl = 80
94
95         vars.ping_crta = 5000.0
96         vars.ping_cpl = 100
97 }
98
99 object CheckCommand "hostalive" {
100         import "ping"
101         import "hostalive-common"
102 }
103
104 object CheckCommand "hostalive4" {
105         import "ping4"
106         import "hostalive-common"
107 }
108
109 object CheckCommand "hostalive6" {
110         import "ping6"
111         import "hostalive-common"
112 }
113
114 template CheckCommand "fping-common" {
115         command = [
116                 PluginDir + "/check_fping",
117                 "$fping_address$"
118         ]
119
120         arguments = {
121                 "-w" = {
122                         value = "$fping_wrta$,$fping_wpl$%"
123                         description = "warning threshold pair"
124                 }
125                 "-c" = {
126                         value = "$fping_crta$,$fping_cpl$%"
127                         description = "critical threshold pair"
128                 }
129                 "-n" = {
130                         value = "$fping_number$"
131                         description = "number of ICMP packets to send (default: 1)"
132                 }
133                 "-i" = {
134                         value = "$fping_interval$"
135                         description = "Interval (ms) between sending packets (default: fping's default for -p)"
136                 }
137                 "-b" = {
138                         value = "$fping_bytes$"
139                         description = "size of ICMP packet (default: 56)"
140                 }
141                 "-T" = {
142                         value = "$fping_target_timeout$"
143                         description = "Target timeout (ms) (default: fping's default for -t)"
144                 }
145                 "-S" = {
146                         value = "$fping_source_ip$"
147                         description = "name or IP Address of sourceip"
148                 }
149                 "-I" = {
150                         value = "$fping_source_interface$"
151                         description = "source interface name"
152                 }
153         }
154
155         vars.fping_wrta = 100
156         vars.fping_wpl = 5
157         vars.fping_crta = 200
158         vars.fping_cpl = 15
159         vars.fping_number = 5
160         vars.fping_interval = 500
161 }
162
163 object CheckCommand "fping4" {
164         import "fping-common"
165
166         command += [ "-4" ]
167
168         vars.fping_address = "$address$"
169 }
170
171 object CheckCommand "fping6" {
172         import "fping-common"
173
174         command += [ "-6" ]
175
176         vars.fping_address = "$address6$"
177 }
178
179 object CheckCommand "dummy" {
180         command = [ PluginDir + "/check_dummy" ]
181
182         arguments = {
183                 "state" = {
184                         value = "$dummy_state$"
185                         skip_key = true
186                         order = 1
187                         description = "The state. Can be one of 0 (ok), 1 (warning), 2 (critical) and 3 (unknown). Defaults to 0."
188                 }
189                 "text" = {
190                         value = "$dummy_text$"
191                         skip_key = true
192                         order = 2
193                         description = "Plugin output. Defaults to Check was successful."
194                 }
195         }
196
197         vars.dummy_state = 0
198         vars.dummy_text = "Check was successful."
199 }
200
201 object CheckCommand "passive" {
202         import "dummy"
203
204         vars.dummy_state = 3
205         vars.dummy_text = "No Passive Check Result Received."
206 }
207
208 object CheckCommand "tcp" {
209         import "ipv4-or-ipv6"
210
211         command = [ PluginDir + "/check_tcp" ]
212
213         arguments = {
214                 "-H" = {
215                         value =  "$tcp_address$"
216                         description = "Host name, IP Address, or unix socket (must be an absolute path)."
217                 }
218                 "-p" = {
219                         value =  "$tcp_port$"
220                         description = "The TCP port number."
221                 }
222                 "-e" = {
223                         value = "$tcp_expect$"
224                         description = "String to expect in server response (may be repeated)."
225                 }
226                 "-A" = {
227                         set_if = "$tcp_all$"
228                         description = "All expect strings need to occur in server response. Defaults to false."
229                 }
230                 "-E_send" = {
231                         key = "-E"
232                         order = 1
233                         set_if = "$tcp_escape_send$"
234                         description = "Enable usage of \n, \r, \t or \\ in send string."
235                 }
236                 "-s" = {
237                         order = 2
238                         value = "$tcp_send$"
239                         description = "String to send to the server."
240                 }
241                 "-E_quit" = {
242                         key = "-E"
243                         order = 3
244                         set_if = "$tcp_escape_quit$"
245                         description = "Enable usage of \n, \r, \t or \\ in quit string."
246                 }
247                 "-q" = {
248                         order = 4
249                         value = "$tcp_quit$"
250                         description = "String to send server to initiate a clean close of the connection."
251                 }
252                 "-r" = {
253                         value = "$tcp_refuse$"
254                         description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
255                 }
256                 "-M" = {
257                         value = "$tcp_mismatch$"
258                         description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
259                 }
260                 "-j" = {
261                         set_if = "$tcp_jail$"
262                         description = "Hide output from TCP socket."
263                 }
264                 "-m" = {
265                         value = "$tcp_maxbytes$"
266                         description = "Close connection once more than this number of bytes are received."
267                 }
268                 "-d" = {
269                         value = "$tcp_delay$"
270                         description = "Seconds to wait between sending string and polling for response."
271                 }
272                 "-D" = {
273                         value = "$tcp_certificate$"
274                         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."
275                 }
276                 "-S" = {
277                         set_if = "$tcp_ssl$"
278                         description = "Use SSL for the connection."
279                 }
280                 "-w" = {
281                         value = "$tcp_wtime$"
282                         description = "Response time to result in warning status (seconds)."
283                 }
284                 "-c" = {
285                         value = "$tcp_ctime$"
286                         description = "Response time to result in critical status (seconds)."
287                 }
288                 "-t" = {
289                         value = "$tcp_timeout$"
290                         description = "Seconds before connection times out. Defaults to 10."
291                 }
292                 "-4" = {
293                         set_if = "$tcp_ipv4$"
294                         description = "Use IPv4 connection"
295                 }
296                 "-6" = {
297                         set_if = "$tcp_ipv6$"
298                         description = "Use IPv6 connection"
299                 }
300         }
301
302         vars.tcp_address = "$check_address$"
303         vars.tcp_all = false
304         vars.tcp_refuse = "crit"
305         vars.tcp_mismatch = "warn"
306         vars.tcp_timeout = 10
307         vars.check_ipv4 = "$tcp_ipv4$"
308         vars.check_ipv6 = "$tcp_ipv6$"
309 }
310
311 object CheckCommand "ssl" {
312         import "ipv4-or-ipv6"
313
314         command = [ PluginDir + "/check_tcp" ]
315
316         arguments = {
317                 "-H" = {
318                         value = "$ssl_address$"
319                         description = "Host address"
320                 }
321                 "-p" = {
322                         value = "$ssl_port$"
323                         description ="TCP port (default: 443)"
324                 }
325                 "--ssl" = {
326                         description = "Use SSL for the connection"
327                 }
328                 "-t" = {
329                         value = "$ssl_timeout$"
330                         description = "Seconds before connection times out (default: 10)"
331                 }
332                 "-D" = {{
333                         var days_warn = macro("$ssl_cert_valid_days_warn$")
334                         var days_critical = macro("$ssl_cert_valid_days_critical$")
335                         if (days_warn) {
336                                 if (days_critical) {
337                                         return days_warn + "," + days_critical
338                                 } else {
339                                         return days_warn
340                                 }
341                         }
342                 }}
343                 "-N" = {
344                         value = "$ssl_sni$"
345                         description = "Enable SSL/TLS hostname extension support (SNI)"
346                 }
347         }
348
349         vars.ssl_address = "$check_address$"
350         vars.ssl_port = 443
351         vars.ssl_cert_valid_days_warn = false
352         vars.ssl_cert_valid_days_critical = false
353         vars.ssl_sni = "$ssl_address$"
354 }
355
356
357 object CheckCommand "udp" {
358         import "ipv4-or-ipv6"
359
360         command = [
361                 PluginDir + "/check_udp",
362                 "-H", "$udp_address$",
363                 "-p", "$udp_port$"
364         ]
365
366         arguments = {
367                 "-s" = {
368                         value = "$udp_send$"
369                         required = true
370                         description = "String to send to the server"
371                 }
372                 "-e" = {
373                         value = "$udp_expect$"
374                         required = true
375                         description = " String to expect in server response"
376                 }
377                 "-q" = {
378                         value = "$udp_quit$"
379                         description = "String to send server to initiate a clean close of the connection"
380                 }
381                 "-4" = {
382                         set_if = "$udp_ipv4$"
383                         description = "Use IPv4 connection"
384                 }
385                 "-6" = {
386                         set_if = "$udp_ipv6$"
387                         description = "Use IPv6 connection"
388                 }
389         }
390
391         vars.udp_address = "$check_address$"
392         vars.check_ipv4 = "$udp_ipv4$"
393         vars.check_ipv6 = "$udp_ipv6$"
394 }
395
396 object CheckCommand "http" {
397         import "ipv4-or-ipv6"
398
399         command = [ PluginDir + "/check_http" ]
400
401         arguments = {
402                 "-H" = {
403                         value = "$http_vhost$"
404                         description = "Host name argument for servers using host headers (virtual host)"
405                 }
406                 "-I" = {
407                         value = "$http_address$"
408                         description = "IP address or name (use numeric address if possible to bypass DNS lookup)"
409                 }
410                 "-u" = {
411                         value = "$http_uri$"
412                         description = "URL to GET or POST (default: /)"
413                 }
414                 "-p" = {
415                         value = "$http_port$"
416                         description = "Port number (default: 80)"
417                 }
418                 "-S" = {
419                         set_if = "$http_ssl$"
420                         description = "Connect via SSL"
421                 }
422                 "-S1" = {
423                         set_if = "$http_ssl_force_tlsv1$"
424                         description = "Connect via SSL version TLSv1"
425                 }
426                 "-S1.1" = {
427                         set_if = "$http_ssl_force_tlsv1_1$"
428                         description = "Connect via SSL version TLSv1.1"
429                 }
430                 "-S1.2" = {
431                         set_if = "$http_ssl_force_tlsv1_2$"
432                         description = "Connect via SSL version TLSv1.2"
433                 }
434                 "-S2" = {
435                         set_if = "$http_ssl_force_sslv2$"
436                         description = "Connect via SSL version SSLv2"
437                 }
438                 "-S3" = {
439                         set_if = "$http_ssl_force_sslv3$"
440                         description = "Connect via SSL version SSLv3"
441                 }
442                 "-S1+" = {
443                         set_if = "$http_ssl_force_tlsv1_or_higher$"
444                         description = "Connect via SSL version TLSv1 and newer"
445                 }
446                 "-S1.1+" = {
447                         set_if = "$http_ssl_force_tlsv1_1_or_higher$"
448                         description = "Connect via SSL version TLSv1.1 and newer"
449                 }
450                 "-S1.2+" = {
451                         set_if = "$http_ssl_force_tlsv1_2_or_higher$"
452                         description = "Connect via SSL version TLSv1.2 and newer"
453                 }
454                 "-S2+" = {
455                         set_if = "$http_ssl_force_sslv2_or_higher$"
456                         description = "Connect via SSL version SSLv2 and newer"
457                 }
458                 "-S3+" = {
459                         set_if = "$http_ssl_force_sslv3_or_higher$"
460                         description = "Connect via SSL version SSLv3 and newer"
461                 }
462                 "--sni" = {
463                         set_if = "$http_sni$"
464                         description = "Enable SSL/TLS hostname extension support (SNI)"
465                 }
466                 "-C" = {
467                         value = "$http_certificate$"
468                         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."
469                 }
470                 "-J" = {
471                         value = "$http_clientcert$"
472                         description = "Name of file contains the client certificate (PEM format)"
473                 }
474                 "-K" = {
475                         value = "$http_privatekey$"
476                         description = "Name of file contains the private key (PEM format)"
477                 }
478                 "-a" = {
479                         value = "$http_auth_pair$"
480                         description = "Username:password on sites with basic authentication"
481                 }
482                 "--no-body" = {
483                         set_if = "$http_ignore_body$"
484                         description = "Don't wait for document body: stop reading after headers"
485                 }
486                 "-w" = {
487                         value = "$http_warn_time$"
488                         description = "Response time to result in warning status (seconds)"
489                 }
490                 "-c" = {
491                         value = "$http_critical_time$"
492                         description = "Response time to result in critical status (seconds)"
493                 }
494                 "-e" = {
495                         value = "$http_expect$"
496                         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.)"
497                 }
498                 "-d" = {
499                         value = "$http_headerstring$"
500                         description = "String to expect in the response headers"
501                 }
502                 "-s" = {
503                         value = "$http_string$"
504                         description = "String to expect in the content"
505                 }
506                 "-P" = {
507                         value = "$http_post$"
508                         description = "URL encoded http POST data"
509                 }
510                 "-j" = {
511                         value = "$http_method$"
512                         description = "Set http method (for example: HEAD, OPTIONS, TRACE, PUT, DELETE)"
513                 }
514                 "-M" = {
515                         value = "$http_maxage$"
516                         description = "Warn if document is more than seconds old"
517                 }
518                 "-T" = {
519                         value = "$http_contenttype$"
520                         description = "Specify Content-Type header when POSTing"
521                 }
522                 "-l" = {
523                         set_if = "$http_linespan$"
524                         description = "Allow regex to span newline"
525                         order = 1
526                 }
527                 "-r" = {
528                         value = "$http_expect_body_regex$"
529                         description = "Search page for regex"
530                         order = 2
531                 }
532                 "-R" = {
533                         value = "$http_expect_body_eregi$"
534                         description = "Search page for case-insensitive regex"
535                         order = 2
536                 }
537                 "--invert-regex" = {
538                         set_if = "$http_invertregex$"
539                         description = "Return CRITICAL if found, OK if not"
540                 }
541                 "-b" = {
542                         value = "$http_proxy_auth_pair$"
543                         description = "Username:password on proxy-servers with basic authentication"
544                 }
545                 "-A" = {
546                         value = "$http_useragent$"
547                         description = "String to be sent in http header as User Agent"
548                 }
549                 "-k" = {
550                         value = "$http_header$"
551                         description = "Any other tags to be sent in http header"
552                 }
553                 "-E" = {
554                         set_if = "$http_extendedperfdata$"
555                         description = "Print additional perfdata"
556                 }
557                 "-f" = {
558                         value = "$http_onredirect$"
559                         description = "How to handle redirect pages"
560                 }
561                 "-m" = {
562                         value = "$http_pagesize$"
563                         description = "Minim page size required:Maximum page size required"
564                 }
565                 "-t" = {
566                         value = "$http_timeout$"
567                         description = "Seconds before connection times out"
568                 }
569                 "-4" = {
570                         set_if = "$http_ipv4$"
571                         description = "Use IPv4 connection"
572                 }
573                 "-6" = {
574                         set_if = "$http_ipv6$"
575                         description = "Use IPv6 connection"
576                 }
577                 "-L" = {
578                         set_if = "$http_link$"
579                         description = "Wrap output in HTML link"
580                 }
581                 "-v" = {
582                         set_if = "$http_verbose$"
583                         description = "Show details for command-line debugging"
584                 }
585         }
586
587         vars.http_address = "$check_address$"
588         vars.http_ssl = false
589         vars.http_sni = false
590         vars.http_linespan = false
591         vars.http_invertregex = false
592         vars.check_ipv4 = "$http_ipv4$"
593         vars.check_ipv6 = "$http_ipv6$"
594         vars.http_link = false
595         vars.http_verbose = false
596 }
597
598 object CheckCommand "ftp" {
599         import "ipv4-or-ipv6"
600
601         command = [ PluginDir + "/check_ftp" ]
602
603         arguments = {
604                 "-H" = {
605                         value = "$ftp_address$"
606                         description = "The host's address. Defaults to $address$ or $address6$ if the address attribute is not set."
607                 }
608                 "-p" = {
609                         value = "$ftp_port$"
610                         description = "The FTP port number. Defaults to none"
611                 }
612                 "-e" = {
613                         value = "$ftp_expect$"
614                         description = "String to expect in server response (may be repeated)."
615                 }
616                 "-A" = {
617                         set_if = "$ftp_all$"
618                         description = "All expect strings need to occur in server response. Default is any."
619                 }
620                 "-E_send" = {
621                         key = "-E"
622                         order = 1
623                         set_if = "$ftp_escape_send$"
624                         description = "Enable usage of \n, \r, \t or \\ in send string. Default is nothing."
625                 }
626                 "-s" = {
627                         order = 2
628                         value = "$ftp_send$"
629                         description = "String to send to the server."
630                 }
631                 "-E_quit" = {
632                         key = "-E"
633                         order = 3
634                         set_if = "$ftp_escape_quit$"
635                         description = "Can use \n, \r, \t or \\ in quit string. Default is \r\n added to end of quit."
636                 }
637                 "-q" = {
638                         order = 4
639                         value = "$ftp_quit$"
640                         description = "String to send server to initiate a clean close of the connection."
641                 }
642                 "-r" = {
643                         value = "$ftp_refuse$"
644                         description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
645                 }
646                 "-M" = {
647                         value = "$ftp_mismatch$"
648                         description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
649                 }
650                 "-j" = {
651                         set_if = "$ftp_jail$"
652                         description = "Hide output from TCP socket."
653                 }
654                 "-m" = {
655                         value = "$ftp_maxbytes$"
656                         description = "Close connection once more than this number of bytes are received."
657                 }
658                 "-d" = {
659                         value = "$ftp_delay$"
660                         description = "Seconds to wait between sending string and polling for response."
661                 }
662                 "-D" = {
663                         value = "$ftp_certificate$"
664                         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."
665                 }
666                 "-S" = {
667                         set_if = "$ftp_ssl$"
668                         description = "Use SSL for the connection."
669                 }
670                 "-w" = {
671                         value = "$ftp_wtime$"
672                         description = "Response time to result in warning status (seconds)."
673                 }
674                 "-c" = {
675                         value = "$ftp_ctime$"
676                         description = "Response time to result in critical status (seconds)."
677                 }
678                 "-t" = {
679                         value = "$ftp_timeout$"
680                         description = "Seconds before connection times out. Defaults to 10."
681                 }
682                 "-4" = {
683                         set_if = "$ftp_ipv4$"
684                         description = "Use IPv4 connection"
685                 }
686                 "-6" = {
687                         set_if = "$ftp_ipv6$"
688                         description = "Use IPv6 connection"
689                 }
690         }
691
692         vars.ftp_address = "$check_address$"
693         vars.ftp_ssl = false
694         vars.ftp_refuse = "crit"
695         vars.ftp_mismatch = "warn"
696         vars.ftp_timeout = 10
697         vars.check_ipv4 = "$ftp_ipv4$"
698         vars.check_ipv6 = "$ftp_ipv6$"
699 }
700
701 object CheckCommand "smtp" {
702         import "ipv4-or-ipv6"
703
704         command = [ PluginDir + "/check_smtp" ]
705
706         arguments = {
707                 "-H" = {
708                         value = "$smtp_address$"
709                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
710                 }
711                 "-p" = {
712                         value = "$smtp_port$"
713                         description = "Port number (default: 25)"
714                 }
715                 "-f" = {
716                         value = "$smtp_mail_from$"
717                         description = "FROM-address to include in MAIL command, required by Exchange 2000"
718                 }
719                 "-e" = {
720                         value = "$smtp_expect$"
721                         description = "String to expect in first line of server response (default: '220')"
722                 }
723                 "-C" = {
724                         value = "$smtp_command$"
725                         description = "SMTP command"
726                 }
727                 "-R" = {
728                         value = "$smtp_response$"
729                         description = "Expected response to command (may be used repeatedly)"
730                 }
731                 "-F" = {
732                         value = "$smtp_helo_fqdn$"
733                         description = "FQDN used for HELO"
734                 }
735                 "-D" = {
736                         value = "$smtp_certificate_age$"
737                         description = "Minimum number of days a certificate has to be valid"
738                 }
739                 "-S" = {
740                         set_if = "$smtp_starttls$"
741                         description = "Use STARTTLS for the connection."
742                 }
743                 "-A" = {
744                         value = "$smtp_authtype$"
745                         description = "SMTP AUTH type to check (default none, only LOGIN supported)"
746                 }
747                 "-U" = {
748                         value = "$smtp_authuser$"
749                         description = "SMTP AUTH username"
750                 }
751                 "-P" = {
752                         value = "$smtp_authpass$"
753                         description = "SMTP AUTH password"
754                 }
755                 "-q" = {
756                         value = "$smtp_ignore_quit$"
757                         description = "Ignore failure when sending QUIT command to server"
758                 }
759                 "-w" = {
760                         value = "$smtp_warning$"
761                         description = "Response time to result in warning status (seconds)"
762                 }
763                 "-c" = {
764                         value = "$smtp_critical$"
765                         description = "Response time to result in critical status (seconds)"
766                 }
767                 "-t" = {
768                         value = "$smtp_timeout$"
769                         description = "Seconds before connection times out (default: 10)"
770                 }
771                 "-4" = {
772                         set_if = "$smtp_ipv4$"
773                         description = "Use IPv4 connection"
774                 }
775                 "-6" = {
776                         set_if = "$smtp_ipv6$"
777                         description = "Use IPv6 connection"
778                 }
779         }
780
781         vars.smtp_address = "$check_address$"
782         vars.check_ipv4 = "$smtp_ipv4$"
783         vars.check_ipv6 = "$smtp_ipv6$"
784 }
785
786 object CheckCommand "ssmtp" {
787         import "ipv4-or-ipv6"
788
789         command = [ PluginDir + "/check_ssmtp" ]
790
791         arguments = {
792                 "-H" = {
793                         value = "$ssmtp_address$"
794                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
795                 }
796                 "-p" = {
797                         value = "$ssmtp_port$"
798                         description = "Port number (default: none)"
799                 }
800                 "-E" = {
801                         value = "$ssmtp_escape$"
802                         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"
803                 }
804                 "-s" = {
805                         value = "$ssmtp_send$"
806                         description = "String to send to the server"
807                 }
808                 "-e" = {
809                         value = "$ssmtp_expect$"
810                         description = "String to expect in server response (may be repeated)"
811                 }
812                 "-A" = {
813                         set_if = "$ssmtp_all$"
814                         description = "All expect strings need to occur in server response. Default is any."
815                 }
816                 "-q" = {
817                         value = "$ssmtp_quit$"
818                         description = "String to send server to initiate a clean close of the connection"
819                 }
820                 "-r" = {
821                         value = "$ssmtp_refuse$"
822                         description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
823                 }
824                 "-M" = {
825                         value = "$ssmtp_mismatch$"
826                         description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
827                 }
828                 "-j" = {
829                         set_if = "$ssmtp_jail$"
830                         description = "Hide output from TCP socket."
831                 }
832                 "-m" = {
833                         value = "$ssmtp_maxbytes$"
834                         description = "Close connection once more than this number of bytes are received"
835                 }
836                 "-d" = {
837                         value = "$ssmtp_delay$"
838                         description = "Seconds to wait between sending string and polling for response"
839                 }
840                 "-D" = {
841                         value = "$ssmtp_certificate_age$"
842                         description = "Minimum number of days a certificate has to be valid"
843                 }
844                 "-S" = {
845                         set_if = "$ssmtp_ssl$"
846                         description = "Use SSL for the connection."
847                 }
848                 "-w" = {
849                         value = "$ssmtp_warning$"
850                         description = "Response time to result in warning status (seconds)"
851                 }
852                 "-c" = {
853                         value = "$ssmtp_critical$"
854                         description = "Response time to result in critical status (seconds)"
855                 }
856                 "-t" = {
857                         value = "$ssmtp_timeout$"
858                         description = "Seconds before connection times out (default: 10)"
859                 }
860                 "-4" = {
861                         set_if = "$ssmtp_ipv4$"
862                         description = "Use IPv4 connection"
863                 }
864                 "-6" = {
865                         set_if = "$ssmtp_ipv6$"
866                         description = "Use IPv6 connection"
867                 }
868         }
869
870         vars.ssmtp_address = "$check_address$"
871         vars.check_ipv4 = "$ssmtp_ipv4$"
872         vars.check_ipv6 = "$ssmtp_ipv6$"
873 }
874
875 object CheckCommand "imap" {
876         import "ipv4-or-ipv6"
877
878         command = [ PluginDir + "/check_imap" ]
879
880         arguments = {
881                 "-H" = {
882                         value = "$imap_address$"
883                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
884                 }
885                 "-p" = {
886                         value = "$imap_port$"
887                         description = "Port number (default: none)"
888                 }
889                 "-E" = {
890                         value = "$imap_escape$"
891                         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"
892                 }
893                 "-s" = {
894                         value = "$imap_send$"
895                         description = "String to send to the server"
896                 }
897                 "-e" = {
898                         value = "$imap_expect$"
899                         description = "String to expect in server response (may be repeated)"
900                 }
901                 "-A" = {
902                         set_if = "$imap_all$"
903                         description = "All expect strings need to occur in server response. Default is any."
904                 }
905                 "-q" = {
906                         value = "$imap_quit$"
907                         description = "String to send server to initiate a clean close of the connection"
908                 }
909                 "-r" = {
910                         value = "$imap_refuse$"
911                         description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
912                 }
913                 "-M" = {
914                         value = "$imap_mismatch$"
915                         description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
916                 }
917                 "-j" = {
918                         set_if = "$imap_jail$"
919                         description = "Hide output from TCP socket."
920                 }
921                 "-m" = {
922                         value = "$imap_maxbytes$"
923                         description = "Close connection once more than this number of bytes are received"
924                 }
925                 "-d" = {
926                         value = "$imap_delay$"
927                         description = "Seconds to wait between sending string and polling for response"
928                 }
929                 "-D" = {
930                         value = "$imap_certificate_age$"
931                         description = "Minimum number of days a certificate has to be valid"
932                 }
933                 "-S" = {
934                         set_if = "$imap_ssl$"
935                         description = "Use SSL for the connection."
936                 }
937                 "-w" = {
938                         value = "$imap_warning$"
939                         description = "Response time to result in warning status (seconds)"
940                 }
941                 "-c" = {
942                         value = "$imap_critical$"
943                         description = "Response time to result in critical status (seconds)"
944                 }
945                 "-t" = {
946                         value = "$imap_timeout$"
947                         description = "Seconds before connection times out (default: 10)"
948                 }
949                 "-4" = {
950                         set_if = "$imap_ipv4$"
951                         description = "Use IPv4 connection"
952                 }
953                 "-6" = {
954                         set_if = "$imap_ipv6$"
955                         description = "Use IPv6 connection"
956                 }
957         }
958
959         vars.imap_address = "$check_address$"
960         vars.check_ipv4 = "$imap_ipv4$"
961         vars.check_ipv6 = "$imap_ipv6$"
962 }
963
964 object CheckCommand "simap" {
965         import "ipv4-or-ipv6"
966
967         command = [ PluginDir + "/check_simap" ]
968
969         arguments = {
970                 "-H" = {
971                         value = "$simap_address$"
972                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
973                 }
974                 "-p" = {
975                         value = "$simap_port$"
976                         description = "Port number (default: none)"
977                 }
978                 "-E" = {
979                         value = "$simap_escape$"
980                         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"
981                 }
982                 "-s" = {
983                         value = "$simap_send$"
984                         description = "String to send to the server"
985                 }
986                 "-e" = {
987                         value = "$simap_expect$"
988                         description = "String to expect in server response (may be repeated)"
989                 }
990                 "-A" = {
991                         set_if = "$simap_all$"
992                         description = "All expect strings need to occur in server response. Default is any."
993                 }
994                 "-q" = {
995                         value = "$simap_quit$"
996                         description = "String to send server to initiate a clean close of the connection"
997                 }
998                 "-r" = {
999                         value = "$simap_refuse$"
1000                         description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
1001                 }
1002                 "-M" = {
1003                         value = "$simap_mismatch$"
1004                         description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
1005                         }
1006                 "-j" = {
1007                         set_if = "$simap_jail$"
1008                         description = "Hide output from TCP socket."
1009                 }
1010                 "-m" = {
1011                         value = "$simap_maxbytes$"
1012                         description = "Close connection once more than this number of bytes are received"
1013                 }
1014                 "-d" = {
1015                         value = "$simap_delay$"
1016                         description = "Seconds to wait between sending string and polling for response"
1017                 }
1018                 "-D" = {
1019                         value = "$simap_certificate_age$"
1020                         description = "Minimum number of days a certificate has to be valid"
1021                 }
1022                 "-S" = {
1023                         set_if = "$simap_ssl$"
1024                         description = "Use SSL for the connection."
1025                 }
1026                 "-w" = {
1027                         value = "$simap_warning$"
1028                         description = "Response time to result in warning status (seconds)"
1029                 }
1030                 "-c" = {
1031                         value = "$simap_critical$"
1032                         description = "Response time to result in critical status (seconds)"
1033                 }
1034                 "-t" = {
1035                         value = "$simap_timeout$"
1036                         description = "Seconds before connection times out (default: 10)"
1037                 }
1038                 "-4" = {
1039                         set_if = "$simap_ipv4$"
1040                         description = "Use IPv4 connection"
1041                 }
1042                 "-6" = {
1043                         set_if = "$simap_ipv6$"
1044                         description = "Use IPv6 connection"
1045                 }
1046         }
1047
1048         vars.simap_address = "$check_address$"
1049         vars.check_ipv4 = "$simap_ipv4$"
1050         vars.check_ipv6 = "$simap_ipv6$"
1051 }
1052
1053 object CheckCommand "pop" {
1054         import "ipv4-or-ipv6"
1055
1056         command = [ PluginDir + "/check_pop" ]
1057
1058         arguments = {
1059                 "-H" = {
1060                         value = "$pop_address$"
1061                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
1062                 }
1063                 "-p" = {
1064                         value = "$pop_port$"
1065                         description = "Port number (default: none)"
1066                 }
1067                 "-E" = {
1068                         value = "$pop_escape$"
1069                         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"
1070                 }
1071                 "-s" = {
1072                         value = "$pop_send$"
1073                         description = "String to send to the server"
1074                 }
1075                 "-e" = {
1076                         value = "$pop_expect$"
1077                         description = "String to expect in server response (may be repeated)"
1078                 }
1079                 "-A" = {
1080                         set_if = "$pop_all$"
1081                         description = "All expect strings need to occur in server response. Default is any."
1082                 }
1083                 "-q" = {
1084                         value = "$pop_quit$"
1085                         description = "String to send server to initiate a clean close of the connection"
1086                 }
1087                 "-r" = {
1088                         value = "$pop_refuse$"
1089                         description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
1090                 }
1091                 "-M" = {
1092                         value = "$pop_mismatch$"
1093                         description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
1094                 }
1095                 "-j" = {
1096                         set_if = "$pop_jail$"
1097                         description = "Hide output from TCP socket."
1098                 }
1099                 "-m" = {
1100                         value = "$pop_maxbytes$"
1101                         description = "Close connection once more than this number of bytes are received"
1102                 }
1103                 "-d" = {
1104                         value = "$pop_delay$"
1105                         description = "Seconds to wait between sending string and polling for response"
1106                 }
1107                 "-D" = {
1108                         value = "$pop_certificate_age$"
1109                         description = "Minimum number of days a certificate has to be valid"
1110                 }
1111                 "-S" = {
1112                         set_if = "$pop_ssl$"
1113                         description = "Use SSL for the connection."
1114                 }
1115                 "-w" = {
1116                         value = "$pop_warning$"
1117                         description = "Response time to result in warning status (seconds)"
1118                 }
1119                 "-c" = {
1120                         value = "$pop_critical$"
1121                         description = "Response time to result in critical status (seconds)"
1122                 }
1123                 "-t" = {
1124                         value = "$pop_timeout$"
1125                         description = "Seconds before connection times out (default: 10)"
1126                 }
1127                 "-4" = {
1128                         set_if = "$pop_ipv4$"
1129                         description = "Use IPv4 connection"
1130                 }
1131                 "-6" = {
1132                         set_if = "$pop_ipv6$"
1133                         description = "Use IPv6 connection"
1134                 }
1135         }
1136
1137         vars.pop_address = "$check_address$"
1138         vars.check_ipv4 = "$pop_ipv4$"
1139         vars.check_ipv6 = "$pop_ipv6$"
1140 }
1141
1142 object CheckCommand "spop" {
1143         import "ipv4-or-ipv6"
1144
1145         command = [ PluginDir + "/check_spop" ]
1146
1147         arguments = {
1148                 "-H" = {
1149                         value = "$spop_address$"
1150                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
1151                 }
1152                 "-p" = {
1153                         value = "$spop_port$"
1154                         description = "Port number (default: none)"
1155                 }
1156                 "-E" = {
1157                         value = "$spop_escape$"
1158                         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"
1159                 }
1160                 "-s" = {
1161                         value = "$spop_send$"
1162                         description = "String to send to the server"
1163                 }
1164                 "-e" = {
1165                         value = "$spop_expect$"
1166                         description = "String to expect in server response (may be repeated)"
1167                 }
1168                 "-A" = {
1169                         set_if = "$spop_all$"
1170                         description = "All expect strings need to occur in server response. Default is any."
1171                 }
1172                 "-q" = {
1173                         value = "$spop_quit$"
1174                         description = "String to send server to initiate a clean close of the connection"
1175                 }
1176                 "-r" = {
1177                         value = "$spop_refuse$"
1178                         description = "Accept TCP refusals with states ok, warn, crit (default: crit)"
1179                 }
1180                 "-M" = {
1181                         value = "$spop_mismatch$"
1182                         description = "Accept expected string mismatches with states ok, warn, crit (default: warn)"
1183                 }
1184                 "-j" = {
1185                         set_if = "$spop_jail$"
1186                         description = "Hide output from TCP socket."
1187                 }
1188                 "-m" = {
1189                         value = "$spop_maxbytes$"
1190                         description = "Close connection once more than this number of bytes are received"
1191                 }
1192                 "-d" = {
1193                         value = "$spop_delay$"
1194                         description = "Seconds to wait between sending string and polling for response"
1195                 }
1196                 "-D" = {
1197                         value = "$spop_certificate_age$"
1198                         description = "Minimum number of days a certificate has to be valid"
1199                 }
1200                 "-S" = {
1201                         set_if = "$spop_ssl$"
1202                         description = "Use SSL for the connection."
1203                 }
1204                 "-w" = {
1205                         value = "$spop_warning$"
1206                         description = "Response time to result in warning status (seconds)"
1207                 }
1208                 "-c" = {
1209                         value = "$spop_critical$"
1210                         description = "Response time to result in critical status (seconds)"
1211                 }
1212                 "-t" = {
1213                         value = "$spop_timeout$"
1214                         description = "Seconds before connection times out (default: 10)"
1215                 }
1216                 "-4" = {
1217                         set_if = "$spop_ipv4$"
1218                         description = "Use IPv4 connection"
1219                 }
1220                 "-6" = {
1221                         set_if = "$spop_ipv6$"
1222                         description = "Use IPv6 connection"
1223                 }
1224         }
1225
1226         vars.spop_address = "$check_address$"
1227         vars.check_ipv4 = "$spop_ipv4$"
1228         vars.check_ipv6 = "$spop_ipv6$"
1229 }
1230
1231 object CheckCommand "ntp_time" {
1232         import "ipv4-or-ipv6"
1233
1234         command = [ PluginDir + "/check_ntp_time" ]
1235
1236         arguments = {
1237                 "-H" = {
1238                         value = "$ntp_address$"
1239                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
1240                 }
1241                 "-p" = {
1242                         value = "$ntp_port$"
1243                         description = "Port number (default: 123)"
1244                 }
1245                 "-q" = {
1246                         set_if = "$ntp_quiet$"
1247                         description = "Returns UNKNOWN instead of CRITICAL if offset cannot be found"
1248                 }
1249                 "-w" = {
1250                         value = "$ntp_warning$"
1251                         description = "Offset to result in warning status (seconds)"
1252                 }
1253                 "-c" = {
1254                         value = "$ntp_critical$"
1255                         description = "Offset to result in critical status (seconds)"
1256                 }
1257                 "-o" = {
1258                         value = "$ntp_timeoffset$"
1259                         description = "Expected offset of the ntp server relative to local server (seconds)"
1260                 }
1261                 "-t" = {
1262                         value = "$ntp_timeout$"
1263                         description = "Seconds before connection times out (default: 10)"
1264                 }
1265                 "-4" = {
1266                         set_if = "$ntp_ipv4$"
1267                         description = "Use IPv4 connection"
1268                 }
1269                 "-6" = {
1270                         set_if = "$ntp_ipv6$"
1271                         description = "Use IPv6 connection"
1272                 }
1273         }
1274
1275         vars.ntp_address = "$check_address$"
1276         vars.check_ipv4 = "$ntp_ipv4$"
1277         vars.check_ipv6 = "$ntp_ipv6$"
1278 }
1279
1280 object CheckCommand "ntp_peer" {
1281         import "ipv4-or-ipv6"
1282
1283         command = [ PluginDir + "/check_ntp_peer" ]
1284
1285         arguments = {
1286                 "-H" = {
1287                         value = "$ntp_address$"
1288                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
1289                 }
1290                 "-p" = {
1291                         value = "$ntp_port$"
1292                         description = "Port number (default: 123)"
1293                 }
1294                 "-q" = {
1295                         set_if = "$ntp_quiet$"
1296                         description = "Returns UNKNOWN instead of CRITICAL or WARNING if server isn't synchronized"
1297                 }
1298                 "-w" = {
1299                         value = "$ntp_warning$"
1300                         description = "Offset to result in warning status (seconds)"
1301                 }
1302                 "-c" = {
1303                         value = "$ntp_critical$"
1304                         description = "Offset to result in critical status (seconds)"
1305                 }
1306                 "-W" = {
1307                         value = "$ntp_wstratum$"
1308                         description = "Warning threshold for stratum of server's synchronization peer"
1309                 }
1310                 "-C" = {
1311                         value = "$ntp_cstratum$"
1312                         description = "Critical threshold for stratum of server's synchronization peer"
1313                 }
1314                 "-j" = {
1315                         value = "$ntp_wjitter$"
1316                         description = "Warning threshold for jitter"
1317                 }
1318                 "-k" = {
1319                         value = "$ntp_cjitter$"
1320                         description = "Critical threshold for jitter"
1321                 }
1322                 "-m" = {
1323                         value = "$ntp_wsource$"
1324                         description = "Warning threshold for number of usable time sources (truechimers)"
1325                 }
1326                 "-n" = {
1327                         value = "$ntp_csource$"
1328                         description = "Critical threshold for number of usable time sources (truechimers)"
1329                 }
1330                 "-t" = {
1331                         value = "$ntp_timeout$"
1332                         description = "Seconds before connection times out (default: 10)"
1333                 }
1334                 "-4" = {
1335                         set_if = "$ntp_ipv4$"
1336                         description = "Use IPv4 connection"
1337                 }
1338                 "-6" = {
1339                         set_if = "$ntp_ipv6$"
1340                         description = "Use IPv6 connection"
1341                 }
1342         }
1343
1344         vars.ntp_address = "$check_address$"
1345         vars.check_ipv4 = "$ntp_ipv4$"
1346         vars.check_ipv6 = "$ntp_ipv6$"
1347 }
1348
1349 object CheckCommand "ssh" {
1350         import "ipv4-or-ipv6"
1351
1352         command = [ PluginDir + "/check_ssh" ]
1353
1354         arguments = {
1355                 "-p" = {
1356                         value = "$ssh_port$"
1357                         description = "Port number (default: 22)"
1358                 }
1359                 "-t" = {
1360                         value = "$ssh_timeout$"
1361                         description = "Seconds before connection times out (default: 10)"
1362                 }
1363                 "host" = {
1364                         value = "$ssh_address$"
1365                         skip_key = true
1366                         order = 1
1367                 }
1368                 "-4" = {
1369                         set_if = "$ssh_ipv4$"
1370                         description = "Use IPv4 connection"
1371                 }
1372                 "-6" = {
1373                         set_if = "$ssh_ipv6$"
1374                         description = "Use IPv6 connection"
1375                 }
1376         }
1377
1378         vars.ssh_address = "$check_address$"
1379         vars.check_ipv4 = "$ssh_ipv4$"
1380         vars.check_ipv6 = "$ssh_ipv6$"
1381 }
1382
1383 object CheckCommand "disk" {
1384         command = [ PluginDir + "/check_disk" ]
1385
1386         arguments = {
1387                 "-w" = {
1388                         value = "$disk_wfree$"
1389                         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"
1390                         required = true
1391                         order = -3
1392                 }
1393                 "-c" = {
1394                         value = "$disk_cfree$"
1395                         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"
1396                         required = true
1397                         order = -3
1398                 }
1399                 "-W" = {
1400                         value = "$disk_inode_wfree$"
1401                         description = "Exit with WARNING status if less than PERCENT of inode space is free"
1402                         order = -3
1403                 }
1404                 "-K" = {
1405                         value = "$disk_inode_cfree$"
1406                         description = "Exit with CRITICAL status if less than PERCENT of inode space is free"
1407                         order = -3
1408                 }
1409                 "-p" = {
1410                         value = "$disk_partitions$"
1411                         description = "Path or partition (may be repeated)"
1412                         repeat_key = true
1413                         order = 1
1414                 }
1415                 "-p_old" = {
1416                         key = "-p"
1417                         value = "$disk_partition$"
1418                         order = 1
1419                 }
1420                 "-x" = {
1421                         value = "$disk_partitions_excluded$"
1422                         description = "Ignore device (only works if -p unspecified)"
1423                 }
1424                 "-x_old" = {
1425                         key = "-x"
1426                         value = "$disk_partition_excluded$"
1427                 }
1428                 "-C" = {
1429                         set_if = "$disk_clear$"
1430                         description = "Clear thresholds"
1431                 }
1432                 "-E" = {
1433                         set_if = "$disk_exact_match$"
1434                         description = "For paths or partitions specified with -p, only check for exact paths"
1435                 }
1436                 "-e" = {
1437                         set_if = "$disk_errors_only$"
1438                         description = "Display only devices/mountpoints with errors"
1439                 }
1440                 "-f" = {
1441                         set_if = "$disk_ignore_reserved$"
1442                         description = "Don't account root-reserved blocks into freespace in perfdata"
1443                 }
1444                 "-g" = {
1445                         value = "$disk_group$"
1446                         description = "Group paths. Thresholds apply to (free-)space of all partitions together"
1447                 }
1448                 "-k" = {
1449                         set_if = "$disk_kilobytes$"
1450                         description = "Same as --units kB"
1451                 }
1452                 "-l" = {
1453                         set_if = "$disk_local$"
1454                         description = " Only check local filesystems"
1455                 }
1456                 "-L" = {
1457                         set_if = "$disk_stat_remote_fs$"
1458                         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)"
1459                 }
1460                 "-M" = {
1461                         set_if = "$disk_mountpoint$"
1462                         description = "Display the mountpoint instead of the partition"
1463                 }
1464                 "-m" = {
1465                         set_if = "$disk_megabytes$"
1466                         description = "Same as --units MB"
1467                 }
1468                 "-A" = {
1469                         set_if = "$disk_all$"
1470                         description = "Explicitly select all paths. This is equivalent to -R .*"
1471                         order = 1
1472                 }
1473                 "-R" = {
1474                         value = "$disk_eregi_path$"
1475                         description = "Case insensitive regular expression for path/partition (may be repeated)"
1476                         repeat_key = true
1477                 }
1478                 "-r" = {
1479                         value = "$disk_ereg_path$"
1480                         description = "Regular expression for path or partition (may be repeated)"
1481                         repeat_key = true
1482                 }
1483                 "-I" = {
1484                         value = "$disk_ignore_eregi_path$"
1485                         description = "Regular expression to ignore selected path/partition (case insensitive) (may be repeated)"
1486                         repeat_key = true
1487                         order = 2
1488                 }
1489                 "-i" = {
1490                         value = "$disk_ignore_ereg_path$"
1491                         description = "Regular expression to ignore selected path or partition (may be repeated)"
1492                         repeat_key = true
1493                         order = 2
1494                 }
1495                 "-t" = {
1496                         value = "$disk_timeout$"
1497                         description = "Seconds before connection times out (default: 10)"
1498                 }
1499                 "-u" = {
1500                         value = "$disk_units$"
1501                         description = "Choose bytes, kB, MB, GB, TB (default: MB)"
1502                 }
1503                 "-X" = {
1504                         value = "$disk_exclude_type$"
1505                         description = "Ignore all filesystems of indicated type (may be repeated)"
1506                         repeat_key = true
1507                 }
1508         }
1509
1510         vars.disk_wfree = "20%"
1511         vars.disk_cfree = "10%"
1512         vars.disk_megabytes = true
1513         vars.disk_exclude_type = [ "none", "tmpfs", "sysfs", "proc", "configfs", "devtmpfs", "devfs", "mtmfs", "tracefs", "cgroup", "fuse.gvfsd-fuse", "fuse.gvfs-fuse-daemon", "fdescfs" ]
1514 }
1515
1516 object CheckCommand "disk_smb" {
1517         command = [ PluginDir + "/check_disk_smb" ]
1518
1519         arguments = {
1520                 "-H" = {
1521                         value = "$disk_smb_hostname$"
1522                         description = "NetBIOS name of the server."
1523                 }
1524                 "-s" = {
1525                         value = "$disk_smb_share$"
1526                         description = "Share name to be tested."
1527                 }
1528                 "-W" = {
1529                         value = "$disk_smb_workgroup$"
1530                         description = "Workgroup or Domain used (Defaults to 'WORKGROUP' if omitted)."
1531                 }
1532                 "-a" = {
1533                         value = "$disk_smb_address$"
1534                         description = "IP-address of HOST (only necessary if HOST is in another network)."
1535                 }
1536                 "-u" = {
1537                         value = "$disk_smb_username$"
1538                         description = "Username to log in to server. (Defaults to 'guest' if omitted)."
1539                 }
1540                 "-p" = {
1541                         value = "$disk_smb_password$"
1542                         description = "Password to log in to server. (Defaults to an empty password if omitted)."
1543                 }
1544                 "-w" = {
1545                         value = "$disk_smb_wused$"
1546                         description = "Percent of used space at which a warning will be generated (Default: 85%)."
1547                 }
1548                 "-c" = {
1549                         value = "$disk_smb_cused$"
1550                         description = "Percent of used space at which a critical will be generated (Defaults: 95%)"
1551                 }
1552                 "-P" = {
1553                         value = "$disk_smb_port$"
1554                         description = "Port to be used to connect to. Some Windows boxes use 139, others 445 (Defaults to smbclient default if omitted)."
1555                 }
1556         }
1557
1558         vars.disk_smb_wused = "85%"
1559         vars.disk_smb_cused = "95%"
1560 }
1561
1562 object CheckCommand "users" {
1563         command = [ PluginDir + "/check_users" ]
1564
1565         arguments = {
1566                 "-w" = {
1567                         value = "$users_wgreater$"
1568                         description = "Set WARNING status if more than INTEGER users are logged in"
1569                 }
1570                 "-c" = {
1571                         value = "$users_cgreater$"
1572                         description = "Set CRITICAL status if more than INTEGER users are logged in"
1573                 }
1574         }
1575
1576         vars.users_wgreater = 20
1577         vars.users_cgreater = 50
1578 }
1579
1580 object CheckCommand "procs" {
1581         command = [ PluginDir + "/check_procs" ]
1582
1583         arguments = {
1584                 "-w" = {
1585                         value = "$procs_warning$"
1586                         description = "Generate warning state if metric is outside this range"
1587                 }
1588                 "-c" = {
1589                         value = "$procs_critical$"
1590                         description = "Generate critical state if metric is outside this range"
1591                 }
1592                 "-m" = {
1593                         value = "$procs_metric$"
1594                         description = "Check thresholds against metric"
1595                 }
1596                 "-t" = {
1597                         value = "$procs_timeout$"
1598                         description = "Seconds before plugin times out"
1599                 }
1600                 "-T" = {
1601                         set_if = "$procs_traditional$"
1602                         description = "Filter own process the traditional way by PID instead of /proc/pid/exe"
1603                 }
1604                 "-s" = {
1605                         value = "$procs_state$"
1606                         description = "Only scan for processes that have one or more of the status flags you specify"
1607                 }
1608                 "-p" = {
1609                         value = "$procs_ppid$"
1610                         description = "Only scan for children of the parent process ID indicated"
1611                 }
1612                 "-z" = {
1613                         value = "$procs_vsz$"
1614                         description = "Only scan for processes with VSZ higher than indicated"
1615                 }
1616                 "-r" = {
1617                         value = "$procs_rss$"
1618                         description = "Only scan for processes with RSS higher than indicated"
1619                 }
1620                 "-P" = {
1621                         value = "$procs_pcpu$"
1622                         description = "Only scan for processes with PCPU higher than indicated"
1623                 }
1624                 "-u" = {
1625                         value = "$procs_user$"
1626                         description = "Only scan for processes with user name or ID indicated"
1627                 }
1628                 "-a" = {
1629                         value = "$procs_argument$"
1630                         description = "Only scan for processes with args that contain STRING"
1631                 }
1632                 "--ereg-argument-array" = {
1633                         value = "$procs_argument_regex$"
1634                         description = "Only scan for processes with args that contain the regex STRING"
1635                 }
1636                 "-C" = {
1637                         value = "$procs_command$"
1638                         description = "Only scan for exact matches of COMMAND (without path)"
1639                 }
1640                 "-k" = {
1641                         set_if = "$procs_nokthreads$"
1642                         description = "Only scan for non kernel threads"
1643                 }
1644         }
1645
1646         vars.procs_traditional = false
1647         vars.procs_nokthreads = false
1648         vars.procs_warning = 250
1649         vars.procs_critical = 400
1650 }
1651
1652 object CheckCommand "swap" {
1653         command = [ PluginDir + "/check_swap" ]
1654
1655         arguments = {
1656                 "-w" = {{
1657                         if (macro("$swap_integer$")) {
1658                                 return macro("$swap_wfree$")
1659                         } else {
1660                                 return macro("$swap_wfree$%")
1661                         }
1662                 }}
1663                 "-c" = {{
1664                         if (macro("$swap_integer$")) {
1665                                 return macro("$swap_cfree$")
1666                         } else {
1667                                 return macro("$swap_cfree$%")
1668                         }
1669                 }}
1670                 "-a" = {
1671                         set_if = "$swap_allswaps$"
1672                         description = "Conduct comparisons for all swap partitions, one by one"
1673                 }
1674                 "-n" = {
1675                         value = "$swap_noswap$"
1676                         description = "Resulting state when there is no swap regardless of thresholds. Possible values are \"ok\", \"warning\", \"critical\", \"unknown\". Defaults to \"critical\""
1677                 }
1678         }
1679
1680         vars.swap_wfree = 50
1681         vars.swap_cfree = 25
1682         vars.swap_integer = false
1683         vars.swap_allswaps = false
1684 }
1685
1686 object CheckCommand "load" {
1687         command = [ PluginDir + "/check_load" ]
1688
1689         arguments = {
1690                 "-w" = {
1691                         value = "$load_wload1$,$load_wload5$,$load_wload15$"
1692                         description = "Exit with WARNING status if load average exceeds WLOADn"
1693                 }
1694                 "-c" = {
1695                         value = "$load_cload1$,$load_cload5$,$load_cload15$"
1696                         description = "Exit with CRITICAL status if load average exceed CLOADn; the load average format is the same used by 'uptime' and 'w'"
1697                 }
1698                 "-r" = {
1699                         set_if = "$load_percpu$"
1700                         description = "Divide the load averages by the number of CPUs (when possible)"
1701                 }
1702         }
1703
1704         vars.load_wload1 = 5.0
1705         vars.load_wload5 = 4.0
1706         vars.load_wload15 = 3.0
1707
1708         vars.load_cload1 = 10.0
1709         vars.load_cload5 = 6.0
1710         vars.load_cload15 = 4.0
1711
1712         vars.load_percpu = false
1713 }
1714
1715 object CheckCommand "snmp" {
1716         command = [ PluginDir + "/check_snmp" ]
1717
1718         arguments = {
1719                 "-H" = {
1720                         value = "$snmp_address$"
1721                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
1722                 }
1723                 "-o" = {
1724                         value = "$snmp_oid$"
1725                         description = "Object identifier(s) or SNMP variables whose value you wish to query"
1726                 }
1727                 "-C" = {
1728                         value = "$snmp_community$"
1729                         description = "Optional community string for SNMP communication (default is 'public')"
1730                 }
1731                 "-c" = {
1732                         value = "$snmp_crit$"
1733                         description = "Critical threshold range(s)"
1734                 }
1735                 "-w" = {
1736                         value = "$snmp_warn$"
1737                         description = "Warning threshold range(s)"
1738                 }
1739                 "-s" = {
1740                         value = "$snmp_string$"
1741                         description = "Return OK state (for that OID) if STRING is an exact match"
1742                 }
1743                 "-r" = {
1744                         value = "$snmp_ereg$"
1745                         description = "Return OK state (for that OID) if extended regular expression REGEX matches"
1746                 }
1747                 "-R" = {
1748                         value = "$snmp_eregi$"
1749                         description = "Return OK state (for that OID) if case-insensitive extended REGEX matches"
1750                 }
1751                 "-l" = {
1752                         value = "$snmp_label$"
1753                         description = "Prefix label for output from plugin"
1754                 }
1755                 "-u" = {
1756                         value = "$snmp_units$"
1757                         description = "Units label(s) for output data (e.g., 'sec.')"
1758                 }
1759                 "-t" = {
1760                         value = "$snmp_timeout$"
1761                         description = "Seconds before connection times out (default: 10)"
1762                 }
1763                 "-p" = {
1764                         value = "$snmp_port$"
1765                         description = "Port number (default: 161)"
1766                 }
1767                 "-e" = {
1768                         value = "$snmp_retries$"
1769                         description = "Number of retries to be used in the requests"
1770                 }
1771                 "--invert-search" = {
1772                         set_if = "$snmp_invert_search$"
1773                         description = "Invert search result and return CRITICAL if found"
1774                 }
1775                 "-P" = {
1776                         value = "$snmp_version$"
1777                         description = "SNMP protocol version"
1778                 }
1779                 "-m" = {
1780                         value = "$snmp_miblist$"
1781                         description = "List of MIBS to be loaded (default = none if using numeric OIDs or 'ALL' for symbolic OIDs.)"
1782                 }
1783                 "--rate-multiplier" = {
1784                         value = "$snmp_rate_multiplier$"
1785                         description = "Converts rate per second. For example, set to 60 to convert to per minute"
1786                 }
1787                 "--rate" = {
1788                         set_if = "$snmp_rate$"
1789                         description = "Enable rate calculation"
1790                 }
1791                 "-n" = {
1792                         set_if = "$snmp_getnext$"
1793                         description = "Use SNMP GETNEXT instead of SNMP GET"
1794                 }
1795                 "--offset" = {
1796                         value = "$snmp_offset$"
1797                         description = "Add/substract the specified OFFSET to numeric sensor data"
1798                 }
1799                 "-D" = {
1800                         value = "$snmp_output_delimiter$"
1801                         description = "Separates output on multiple OID requests"
1802                 }
1803                 "-O" = {
1804                         set_if = "$snmp_perf_oids$"
1805                         description = "Label performance data with OIDs instead of --label's"
1806                 }
1807         }
1808
1809         vars.snmp_address = {{
1810                 var addr_v4 = macro("$address$")
1811                 var addr_v6 = macro("$address6$")
1812
1813                 if (addr_v4) {
1814                         return addr_v4
1815                 } else {
1816                         return "udp6:[" + addr_v6 + "]"
1817                 }
1818         }}
1819
1820         vars.snmp_community = "public"
1821         vars.snmp_invert_search = false
1822         vars.snmp_timeout = "10"
1823 }
1824
1825 object CheckCommand "snmpv3" {
1826         import "ipv4-or-ipv6"
1827
1828         command = [ PluginDir + "/check_snmp" ]
1829
1830         arguments = {
1831                 "-H" = {
1832                         value = "$snmpv3_address$"
1833                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
1834                 }
1835                 "-p" = {
1836                         value = "$snmpv3_port$"
1837                         description = "Port number"
1838                 }
1839                 "-n" = {
1840                         set_if = "$snmpv3_getnext$"
1841                         description = "Use SNMP GETNEXT instead of SNMP GET"
1842                 }
1843                 "-P" = {
1844                         value = 3
1845                         description = "SNMP protocol version"
1846                 }
1847                 "-L" = {
1848                         value = "$snmpv3_seclevel$"
1849                         description = "SNMPv3 securityLevel"
1850                 }
1851                 "-a" = {
1852                         value = "$snmpv3_auth_alg$"
1853                         description = "SNMPv3 auth proto"
1854                 }
1855                 "-U" = {
1856                         value = "$snmpv3_user$"
1857                         description = "SNMPv3 username"
1858                 }
1859                 "-A" = {
1860                         value = "$snmpv3_auth_key$"
1861                         description = "SNMPv3 authentication password"
1862                 }
1863                 "-X" = {
1864                         value = "$snmpv3_priv_key$"
1865                         description = "SNMPv3 privacy password"
1866                 }
1867                 "-o" = {
1868                         value = "$snmpv3_oid$"
1869                         description = "Object identifier(s) or SNMP variables whose value you wish to query"
1870                 }
1871                 "-x" = {
1872                         value = "$snmpv3_priv_alg$"
1873                         description = "SNMPv3 priv proto (default DES)"
1874                 }
1875                 "-w" = {
1876                         value = "$snmpv3_warn$"
1877                         description = "Warning threshold range(s)"
1878                 }
1879                 "-c" = {
1880                         value = "$snmpv3_crit$"
1881                         description = "Critical threshold range(s)"
1882                 }
1883                 "-s" = {
1884                         value = "$snmpv3_string$"
1885                         description = "Return OK state (for that OID) if STRING is an exact match"
1886                 }
1887                 "-r" = {
1888                         value = "$snmpv3_ereg$"
1889                         description = "Return OK state (for that OID) if extended regular expression REGEX matches"
1890                 }
1891                 "-R" = {
1892                         value = "$snmpv3_eregi$"
1893                         description = "Return OK state (for that OID) if case-insensitive extended REGEX matches"
1894                 }
1895                 "--invert-search" = {
1896                         set_if = "$snmpv3_invert_search$"
1897                         description = "Invert search result and return CRITICAL if found"
1898                 }
1899                 "-l" = {
1900                         value = "$snmpv3_label$"
1901                         description = "Prefix label for output from plugin"
1902                 }
1903                 "-m" = {
1904                         value = "$snmpv3_miblist$"
1905                         description = "List of SNMP MIBs for translating OIDs between numeric and textual representation"
1906                 }
1907                 "-u" = {
1908                         value = "$snmpv3_units$"
1909                         description = "Units label(s) for output data (e.g., 'sec.')"
1910                 }
1911                 "--rate-multiplier" = {
1912                         value = "$snmpv3_rate_multiplier$"
1913                         description = "Converts rate per second. For example, set to 60 to convert to per minute"
1914                 }
1915                 "--rate" = {
1916                         set_if = "$snmpv3_rate$"
1917                         description = "Enable rate calculation"
1918                 }
1919                 "-t" = {
1920                         value = "$snmpv3_timeout$"
1921                         description = "Seconds before connection times out (default: 10)"
1922                 }
1923         }
1924
1925         vars.snmpv3_address = "$check_address$"
1926         vars.snmpv3_auth_alg = "SHA"
1927         vars.snmpv3_priv_alg = "AES"
1928         vars.snmpv3_seclevel = "authPriv"
1929         vars.snmpv3_timeout = "10"
1930 }
1931
1932 object CheckCommand "snmp-uptime" {
1933         import "snmp"
1934
1935         vars.snmp_oid = "1.3.6.1.2.1.1.3.0"
1936 }
1937
1938 object CheckCommand "apt" {
1939         command = [ PluginDir + "/check_apt" ]
1940
1941         arguments = {
1942                 "--extra-opts" = {
1943                         value = "$apt_extra_opts$"
1944                         description = "Read options from an ini file."
1945                 }
1946                 "--upgrade" = {
1947                         value = "$apt_upgrade$"
1948                         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."
1949                 }
1950                 "--dist-upgrade" = {
1951                         value = "$apt_dist_upgrade$"
1952                         description = "Perform a dist-upgrade instead of normal upgrade. Like with -U OPTS can be provided to override the default options."
1953                 }
1954                 "--include" = {
1955                         value = "$apt_include$"
1956                         description = "Include only packages matching REGEXP. Can be specified multiple times the values will be combined together."
1957                 }
1958                 "--exclude" = {
1959                         value = "$apt_exclude$"
1960                         description = "Exclude packages matching REGEXP from the list of packages that would otherwise be included. Can be specified multiple times."
1961                 }
1962                 "--critical" = {
1963                         value = "$apt_critical$"
1964                         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."
1965                 }
1966                 "--timeout" = {
1967                         value = "$apt_timeout$"
1968                         description = "Seconds before plugin times out (default: 10)."
1969                 }
1970                 "--only-critical" = {
1971                         set_if = "$apt_only_critical$"
1972                         description = "Only warn about critical upgrades."
1973                 }
1974         }
1975
1976         timeout = 5m
1977 }
1978
1979 object CheckCommand "dhcp" {
1980         command = [ PluginDir + "/check_dhcp" ]
1981
1982         arguments = {
1983                 "-s" = {
1984                         value = "$dhcp_serverip$"
1985                         description = "IP address of DHCP server that we must hear from"
1986                 }
1987                 "-r" = {
1988                         value = "$dhcp_requestedip$"
1989                         description = "IP address that should be offered by at least one DHCP server"
1990                 }
1991                 "-t" = {
1992                         value = "$dhcp_timeout$"
1993                         description = "Seconds to wait for DHCPOFFER before timeout occurs"
1994                 }
1995                 "-i" = {
1996                         value = "$dhcp_interface$"
1997                         description = "Interface to to use for listening (i.e. eth0)"
1998                 }
1999                 "-m" = {
2000                         value = "$dhcp_mac$"
2001                         description = "MAC address to use in the DHCP request"
2002                 }
2003                 "-u" = {
2004                         set_if = "$dhcp_unicast$"
2005                         description = "Unicast testing: mimic a DHCP relay"
2006                 }
2007         }
2008
2009         vars.dhcp_unicast = false
2010 }
2011
2012 object CheckCommand "dns" {
2013         import "ipv4-or-ipv6"
2014
2015         command = [ PluginDir + "/check_dns" ]
2016
2017         arguments = {
2018                 "-H" = {
2019                         value = "$dns_lookup$"
2020                         description = "The name or address you want to query."
2021                 }
2022                 "-s" = {
2023                         value = "$dns_server$"
2024                         description = "Optional DNS server you want to use for the lookup."
2025                 }
2026                 "-q" = {
2027                         value = "$dns_query_type$"
2028                         description = "Optional DNS record query type where TYPE =(A, AAAA, SRV, TXT, MX, ANY). The default query type is 'A' (IPv4 host entry)"
2029                 }
2030                 "-a" = {
2031                         value = "$dns_expected_answers$"
2032                         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)."
2033                 }
2034                 "-A" = {
2035                         set_if = "$dns_authoritative$"
2036                         description = "Optionally expect the DNS server to be authoritative for the lookup"
2037                 }
2038                 "-n" = {
2039                         set_if = "$dns_accept_cname$"
2040                         description = "Optionally accept cname responses as a valid result to a query. The default is to ignore cname responses as part of the result"
2041                 }
2042                 "-w" = {
2043                         value = "$dns_wtime$"
2044                         description = "Return warning if elapsed time exceeds value."
2045                 }
2046                 "-c" = {
2047                         value = "$dns_ctime$"
2048                         description = "Return critical if elapsed time exceeds value."
2049                 }
2050                 "-t" = {
2051                         value = "$dns_timeout$"
2052                         description = "Seconds before connection times out. Defaults to 10."
2053                 }
2054         }
2055
2056         vars.dns_lookup = "$host.name$"
2057         vars.dns_timeout = 10
2058 }
2059
2060 object CheckCommand "dig" {
2061         import "ipv4-or-ipv6"
2062
2063         command = [ PluginDir + "/check_dig" ]
2064
2065         arguments = {
2066                 "-H" = {
2067                         value = "$dig_server$"
2068                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
2069                 }
2070                 "-p" = {
2071                         value = "$dig_port$"
2072                         description = "Port number (default: 53)"
2073                 }
2074                 "-l" = {
2075                         value = "$dig_lookup$"
2076                         required = true
2077                         description = "Machine name to lookup"
2078                 }
2079                 "-T" = {
2080                         value = "$dig_record_type$"
2081                         description = "Record type to lookup (default: A)"
2082                 }
2083                 "-a" = {
2084                         value = "$dig_expected_address$"
2085                         description = "An address expected to be in the answer section"
2086                 }
2087                 "-A" = {
2088                         value = "$dig_arguments$"
2089                         description = "Pass STRING as argument(s) to dig"
2090                 }
2091                 "-w" = {
2092                         value = "$dig_warning$"
2093                         description = "Response time to result in warning status (seconds)"
2094                 }
2095                 "-c" = {
2096                         value = "$dig_critical$"
2097                         description = "Response time to result in critical status (seconds)"
2098                 }
2099                 "-t" = {
2100                         value = "$dig_timeout$"
2101                         description = "Seconds before connection times out (default: 10)"
2102                 }
2103                 "-4" = {
2104                         set_if = "$dig_ipv4$"
2105                         description = "Force dig to only use IPv4 query transport"
2106                 }
2107                 "-6" = {
2108                         set_if = "$dig_ipv6$"
2109                         description = "Force dig to only use IPv6 query transport"
2110                 }
2111         }
2112
2113         vars.dig_server = "$check_address$"
2114         vars.check_ipv4 = "$dig_ipv4$"
2115         vars.check_ipv6 = "$dig_ipv6$"
2116 }
2117
2118 object CheckCommand "nscp" {
2119         import "ipv4-or-ipv6"
2120
2121         command = [ PluginDir + "/check_nt" ]
2122
2123         arguments = {
2124                 "-H" = {
2125                         value = "$nscp_address$"
2126                         description = "Name of the host to check"
2127                 }
2128                 "-p" = {
2129                         value = "$nscp_port$"
2130                         description = "Optional port number (default: 1248)"
2131                 }
2132                 "-s" = {
2133                         value = "$nscp_password$"
2134                         description = "Password needed for the request"
2135                 }
2136                 "-v" = {
2137                         value = "$nscp_variable$"
2138                         required = true
2139                         description = "Variable to check"
2140                 }
2141                 "-l" = {
2142                         value = "$nscp_params$"
2143                         repeat_key = false
2144                 }
2145                 "-w" = {
2146                         value = "$nscp_warn$"
2147                         description = "Threshold which will result in a warning status"
2148                 }
2149                 "-c" = {
2150                         value = "$nscp_crit$"
2151                         description = "Threshold which will result in a critical status"
2152                 }
2153                 "-t" = {
2154                         value = "$nscp_timeout$"
2155                         description = "Seconds before connection attempt times out"
2156                 }
2157                 "-d" = {
2158                         value = "SHOWALL"
2159                         set_if = "$nscp_showall$"
2160                         description = "Use with SERVICESTATE to see working services or PROCSTATE for running processes"
2161                 }
2162         }
2163
2164         vars.nscp_address = "$check_address$"
2165         vars.nscp_port = 12489
2166         vars.nscp_showall = false
2167 }
2168
2169 object CheckCommand "by_ssh" {
2170         import "ipv4-or-ipv6"
2171
2172         command = [ PluginDir + "/check_by_ssh" ]
2173
2174         arguments = {
2175                 "-H" = {
2176                         value = "$by_ssh_address$"
2177                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
2178                 }
2179                 "-p" = {
2180                         value = "$by_ssh_port$"
2181                         description = "Port number (default: none)"
2182                 }
2183                 "-C" = {{
2184                         var command = macro("$by_ssh_command$")
2185                         var arguments = macro("$by_ssh_arguments$")
2186
2187                         if (typeof(command) == String && !arguments) {
2188                                 return command
2189                         }
2190
2191                         var escaped_args = []
2192                         for (arg in resolve_arguments(command, arguments)) {
2193                                 escaped_args.add(escape_shell_arg(arg))
2194                         }
2195                         return escaped_args.join(" ")
2196                 }}
2197                 "-l" = {
2198                         value = "$by_ssh_logname$"
2199                         description = "SSH user name on remote host [optional]"
2200                 }
2201                 "-i" = {
2202                         value = "$by_ssh_identity$"
2203                         description = "identity of an authorized key [optional]"
2204                 }
2205                 "-q" = {
2206                         set_if = "$by_ssh_quiet$"
2207                         description = "Tell ssh to suppress warning and diagnostic messages [optional]"
2208                 }
2209                 "-w" = {
2210                         value = "$by_ssh_warn$"
2211                         description = "Response time to result in warning status (seconds)"
2212                 }
2213                 "-c" = {
2214                         value = "$by_ssh_crit$"
2215                         description = "Response time to result in critical status (seconds)"
2216                 }
2217                 "-t" = {
2218                         value = "$by_ssh_timeout$"
2219                         description = "Seconds before connection times out (default: 10)"
2220                 }
2221                 "-o" = {
2222                         value = "$by_ssh_options$"
2223                         description = "Provide ssh options (may be repeated)"
2224                 }
2225                 "-4" = {
2226                         set_if = "$by_ssh_ipv4$"
2227                         description = "Use IPv4 only"
2228                 }
2229                 "-6" = {
2230                         set_if = "$by_ssh_ipv6$"
2231                         description = "Use IPv6 only"
2232                 }
2233         }
2234
2235         vars.by_ssh_address = "$check_address$"
2236         vars.by_ssh_quiet = false
2237         vars.check_ipv4 = "$by_ssh_ipv4$"
2238         vars.check_ipv6 = "$by_ssh_ipv6$"
2239 }
2240
2241 object CheckCommand "ups" {
2242         import "ipv4-or-ipv6"
2243
2244         command = [ PluginDir + "/check_ups" ]
2245
2246         arguments = {
2247                 "-H" = {
2248                         value = "$ups_address$"
2249                         description = "Address of the upsd server"
2250                         required = true
2251                 }
2252                 "-u" = {
2253                         value = "$ups_name$"
2254                         description = "Name of the UPS to monitor"
2255                         required = true
2256                 }
2257                 "-p" = {
2258                         value = "$ups_port$"
2259                         description = "Port number (default: 3493)"
2260                 }
2261                 "-v" = {
2262                         value = "$ups_variable$"
2263                         description = "Variable to monitor, valid strings are LINE, TEMP, BATTPCT or LOADPCT"
2264                 }
2265                 "-w" = {
2266                         value = "$ups_warning$"
2267                         description = "Warning threshold for the selected variable"
2268                 }
2269                 "-c" = {
2270                         value = "$ups_critical$"
2271                         description = "Critical threshold for the selected variable"
2272                 }
2273                 "-T" = {
2274                         set_if = "$ups_celsius$"
2275                         description = "Display temperature in degrees Celsius instead of Fahrenheit"
2276                 }
2277                 "-t" = {
2278                         value = "$ups_timeout$"
2279                         description = "Seconds before the connection times out (default: 10)"
2280                 }
2281         }
2282
2283         vars.ups_address = "$check_address$"
2284         vars.ups_name = "ups"
2285 }
2286
2287 object CheckCommand "nrpe" {
2288         import "ipv4-or-ipv6"
2289
2290         command = [ PluginDir + "/check_nrpe" ]
2291
2292         arguments = {
2293                 "-H" = {
2294                         value = "$nrpe_address$"
2295                         description = "The address of the host running the NRPE daemon"
2296                 }
2297                 "-p" = {
2298                         value = "$nrpe_port$"
2299                 }
2300                 "-c" = {
2301                         value = "$nrpe_command$"
2302                 }
2303                 "-n" = {
2304                         set_if = "$nrpe_no_ssl$"
2305                         description = "Do not use SSL"
2306                 }
2307                 "-u" = {
2308                         set_if = "$nrpe_timeout_unknown$"
2309                         description = "Make socket timeouts return an UNKNOWN state instead of CRITICAL"
2310                 }
2311                 "-t" = {
2312                         value = "$nrpe_timeout$"
2313                         description = "<interval>:<state> = <Number of seconds before connection times out>:<Check state to exit with in the event of a timeout (default=CRITICAL)>"
2314                 }
2315                 "-a" = {
2316                         value = "$nrpe_arguments$"
2317                         repeat_key = false
2318                         order = 1
2319                 }
2320                 "-4" = {
2321                         set_if = "$nrpe_ipv4$"
2322                         description = "Use IPv4 connection"
2323                 }
2324                 "-6" = {
2325                         set_if = "$nrpe_ipv6$"
2326                         description = "Use IPv6 connection"
2327                 }
2328                 "-2" = {
2329                         set_if = "$nrpe_version_2$"
2330                         description = "Use this if you want to connect to NRPE v2"
2331                 }
2332         }
2333
2334         vars.nrpe_address = "$check_address$"
2335         vars.nrpe_no_ssl = false
2336         vars.nrpe_timeout_unknown = false
2337         vars.check_ipv4 = "$nrpe_ipv4$"
2338         vars.check_ipv6 = "$nrpe_ipv6$"
2339         vars.nrpe_version_2 = false
2340         timeout = 5m
2341 }
2342
2343 object CheckCommand "hpjd" {
2344         import "ipv4-or-ipv6"
2345
2346         command = [ PluginDir + "/check_hpjd" ]
2347
2348         arguments = {
2349                 "-H" = {
2350                         value = "$hpjd_address$"
2351                         description = "Host address"
2352                 }
2353                 "-C" = {
2354                         value = "$hpjd_community$"
2355                         description = "The SNMP community name (default=public)"
2356                 }
2357                 "-p" = {
2358                         value = "$hpjd_port$"
2359                         description = "Specify the port to check (default=161)"
2360                 }
2361         }
2362
2363         vars.hpjd_address = "$check_address$"
2364 }
2365
2366 object CheckCommand "icmp" {
2367         command = [ PluginDir + "/check_icmp" ]
2368
2369         arguments = {
2370                 "-H" = {
2371                         value = "$icmp_address$"
2372                         repeat_key = false
2373                         order = 1
2374                         description = "Host address"
2375                 }
2376                 "-w" = {
2377                         value = "$icmp_wrta$,$icmp_wpl$%"
2378                         description = "warning threshold (currently 200.000ms,40%)"
2379                 }
2380                 "-c" = {
2381                         value = "$icmp_crta$,$icmp_cpl$%"
2382                         description = "critical threshold (currently 500.000ms,80%)"
2383                 }
2384                 "-s" = {
2385                         value = "$icmp_source$"
2386                         description = "specify a source IP address or device name"
2387                 }
2388                 "-n" = {
2389                         value = "$icmp_packets$"
2390                         description = "number of packets to send (currently 5)"
2391                 }
2392                 "-i" = {
2393                         value = "$icmp_packet_interval$"
2394                         description = "max packet interval (currently 80.000ms)"
2395                 }
2396                 "-I" = {
2397                         value = "$icmp_target_interval$"
2398                         description = "max target interval (currently 0.000ms)"
2399                 }
2400                 "-m" = {
2401                         value = "$icmp_hosts_alive$"
2402                         description = "number of alive hosts required for success"
2403                 }
2404                 "-b" = {
2405                         value = "$icmp_data_bytes$"
2406                         description = "Number of icmp data bytes to send. Packet size will be data bytes + icmp header (currently 68 + 8)"
2407                 }
2408                 "-t" = {
2409                         value = "$icmp_timeout$"
2410                         description = "timeout value (seconds, currently  10)"
2411                 }
2412                 "-l" = {
2413                         value = "$icmp_ttl$"
2414                         description = "TTL on outgoing packets (currently 0)"
2415                 }
2416         }
2417
2418         vars.icmp_address = "$address$"
2419         vars.icmp_wrta = 100
2420         vars.icmp_wpl = 5
2421         vars.icmp_crta = 200
2422         vars.icmp_cpl = 15
2423 }
2424
2425 object CheckCommand "ldap" {
2426         import "ipv4-or-ipv6"
2427
2428         command = [ PluginDir + "/check_ldap" ]
2429
2430         arguments = {
2431                 "-H" = {
2432                         value = "$ldap_address$"
2433                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
2434                 }
2435                 "-p" = {
2436                         value = "$ldap_port$"
2437                         description = "Port number (default: 389)"
2438                 }
2439                 "-a" = {
2440                         value = "$ldap_attr$"
2441                         description = "ldap attribute to search (default: \"(objectclass=*)\""
2442                 }
2443                 "-b" = {
2444                         value = "$ldap_base$"
2445                         required = true
2446                         description = "ldap base (eg. ou=my unit, o=my org, c=at"
2447                 }
2448                 "-D" = {
2449                         value = "$ldap_bind$"
2450                         description = "ldap bind DN (if required)"
2451                 }
2452                 "-P" = {
2453                         value = "$ldap_pass$"
2454                         description = "ldap password (if required)"
2455                 }
2456                 "-T" = {
2457                         set_if = "$ldap_starttls$"
2458                         description = "use starttls mechanism introduced in protocol version 3"
2459                 }
2460                 "-S" = {
2461                         set_if = "$ldap_ssl$"
2462                         description = "use ldaps (ldap v2 ssl method). this also sets the default port to 636"
2463                 }
2464                 "-2" = {
2465                         set_if = "$ldap_v2$"
2466                         description = "Use LDAP protocol version 2"
2467                 }
2468                 "-3" = {
2469                         set_if = "$ldap_v3$"
2470                         description = "Use LDAP protocol version 3"
2471                 }
2472                 "-w" = {
2473                         value = "$ldap_warning$"
2474                         description = "Response time to result in warning status (seconds)"
2475                 }
2476                 "-c" = {
2477                         value = "$ldap_critical$"
2478                         description = "Response time to result in critical status (seconds)"
2479                 }
2480                 "-W" = {
2481                         value = "$ldap_warning_entries$"
2482                         description = "Number of found entries to result in warning status (optional)"
2483                 }
2484                 "-C" = {
2485                         value = "$ldap_critical_entries$"
2486                         description = "Number of found entries to result in critical status (optional)"
2487                 }
2488                 "-t" = {
2489                         value = "$ldap_timeout$"
2490                         description = "Seconds before connection times out (default: 10)"
2491                 }
2492                 "-v" = {
2493                         set_if = "$ldap_verbose$"
2494                         description = "Show details for command-line debugging"
2495                 }
2496         }
2497
2498         vars.ldap_address = "$check_address$"
2499         vars.ldap_v2 = true
2500         vars.ldap_v3 = false
2501         vars.ldap_timeout = 10s
2502         vars.ldap_verbose = false
2503 }
2504
2505 object CheckCommand "clamd" {
2506         command = [ PluginDir + "/check_clamd" ]
2507
2508         arguments = {
2509                 "-H" = {
2510                         value = "$clamd_address$"
2511                         description = "The host's address or unix socket (must be an absolute path)."
2512                         required = true
2513                 }
2514                 "-p" = {
2515                         value = "$clamd_port$"
2516                         description = "Port number (default: none)."
2517                 }
2518                 "-e" = {
2519                         value = "$clamd_expect$"
2520                         description = "String to expect in server response (may be repeated)."
2521                         repeat_key = true
2522                 }
2523                 "-A" = {
2524                         set_if = "$clamd_all$"
2525                         description = "All expect strings need to occur in server response. Default is any."
2526                 }
2527                 "-E_send" = {
2528                         key = "-E"
2529                         order = 1
2530                         set_if = "$clamd_escape_send$"
2531                         description = "Enable usage of \n, \r, \t or \\ in send string. Default is nothing."
2532                 }
2533                 "-s" = {
2534                         order = 2
2535                         value = "$clamd_send$"
2536                         description = "String to send to the server."
2537                 }
2538                 "-E_quit" = {
2539                         key = "-E"
2540                         order = 3
2541                         set_if = "$clamd_escape_quit$"
2542                         description = "Can use \n, \r, \t or \\ in quit string. Default is \r\n added to end of quit."
2543                 }
2544                 "-q" = {
2545                         order = 4
2546                         value = "$clamd_quit$"
2547                         description = "String to send server to initiate a clean close of the connection."
2548                 }
2549                 "-r" = {
2550                         value = "$clamd_refuse$"
2551                         description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
2552                 }
2553                 "-M" = {
2554                         value = "$clamd_mismatch$"
2555                         description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
2556                 }
2557                 "-j" = {
2558                         set_if = "$clamd_jail$"
2559                         description = "Hide output from TCP socket."
2560                 }
2561                 "-m" = {
2562                         value = "$clamd_maxbytes$"
2563                         description = "Close connection once more than this number of bytes are received."
2564                 }
2565                 "-d" = {
2566                         value = "$clamd_delay$"
2567                         description = "Seconds to wait between sending string and polling for response."
2568                 }
2569                 "-D" = {
2570                         value = "$clamd_certificate$"
2571                         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."
2572                 }
2573                 "-S" = {
2574                         set_if = "$clamd_ssl$"
2575                         description = "Use SSL for the connection."
2576                 }
2577                 "-w" = {
2578                         value = "$clamd_wtime$"
2579                         description = "Response time to result in warning status (seconds)."
2580                 }
2581                 "-c" = {
2582                         value = "$clamd_ctime$"
2583                         description = "Response time to result in critical status (seconds)."
2584                 }
2585                 "-t" = {
2586                         value = "$clamd_timeout$"
2587                         description = "Seconds before connection times out. Defaults to 10."
2588                 }
2589                 "-4" = {
2590                         set_if = "$clamd_ipv4$"
2591                         description = "Use IPv4 only"
2592                 }
2593                 "-6" = {
2594                         set_if = "$clamd_ipv6$"
2595                         description = "Use IPv6 only"
2596                 }
2597         }
2598
2599         vars.clamd_ssl = false
2600         vars.clamd_refuse = "crit"
2601         vars.clamd_mismatch = "warn"
2602         vars.clamd_timeout = 10
2603         vars.check_ipv4 = "$clamd_ipv4$"
2604         vars.check_ipv6 = "$clamd_ipv6$"
2605 }
2606
2607 object CheckCommand "mailq" {
2608         command = [ PluginDir + "/check_mailq" ]
2609
2610         arguments = {
2611                 "-w" = {
2612                         value = "$mailq_warning$"
2613                         description = "Min. number of messages in queue to generate warning"
2614                         required = true
2615                 }
2616                 "-c" = {
2617                         value = "$mailq_critical$"
2618                         description = "Min. number of messages in queue to generate critical alert ( w < c )"
2619                         required = true
2620                 }
2621                 "-W" = {
2622                         value = "$mailq_domain_warning$"
2623                         description = "Min. number of messages for same domain in queue to generate warning"
2624                 }
2625                 "-C" = {
2626                         value = "$mailq_domain_critical$"
2627                         description = "Min. number of messages for same domain in queue to generate critical alert ( W < C )"
2628                 }
2629                 "-t" = {
2630                         value = "$mailq_timeout$"
2631                         description = "Plugin timeout in seconds (default = 15)"
2632                 }
2633                 "-M" = {
2634                         value = "$mailq_servertype$"
2635                         description = "[ sendmail | qmail | postfix | exim | nullmailer ] (default = autodetect)"
2636                 }
2637                 "-s" = {
2638                         set_if = "$mailq_sudo$"
2639                         description = "Use sudo for mailq command"
2640                 }
2641         }
2642 }
2643
2644 object CheckCommand "pgsql" {
2645         import "ipv4-or-ipv6"
2646
2647         command = [ PluginDir + "/check_pgsql" ]
2648
2649         arguments = {
2650                 "-H" = {
2651                         value = "$pgsql_hostname$"
2652                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
2653                 }
2654                 "-P" = {
2655                         value = "$pgsql_port$"
2656                         description = "Port number (default: 5432)"
2657                 }
2658                 "-d" = {
2659                         value = "$pgsql_database$"
2660                         description = "Database to check (default: template1)"
2661                 }
2662                 "-l" = {
2663                         value = "$pgsql_username$"
2664                         description = "Login name of user"
2665                 }
2666                 "-p" = {
2667                         value = "$pgsql_password$"
2668                         description = "Password (BIG SECURITY ISSUE)"
2669                 }
2670                 "-o" = {
2671                         value = "$pgsql_options$"
2672                         description = "Connection parameters (keyword = value), see below"
2673                         }
2674                 "-w" = {
2675                         value = "$pgsql_warning$"
2676                         description = "Response time to result in warning status (seconds)"
2677                 }
2678                 "-c" = {
2679                         value = "$pgsql_critical$"
2680                         description = "Response time to result in critical status (seconds)"
2681                 }
2682                 "-t" = {
2683                         value = "$pgsql_timeout$"
2684                         description = "Seconds before connection times out (default: 10)"
2685                 }
2686                 "-q" = {
2687                         value = "$pgsql_query$"
2688                         description = "SQL query to run. Only first column in first row will be read"
2689                 }
2690                 "-W" = {
2691                         value = "$pgsql_query_warning$"
2692                         description = "SQL query value to result in warning status (double)"
2693                 }
2694                 "-C" = {
2695                         value = "$pgsql_query_critical$"
2696                         description = "SQL query value to result in critical status (double)"
2697                 }
2698         }
2699
2700         vars.pgsql_hostname = "$check_address$"
2701 }
2702
2703 object CheckCommand "mysql" {
2704         import "ipv4-or-ipv6"
2705
2706         command = [ PluginDir + "/check_mysql" ]
2707
2708         arguments = {
2709                 "-H" = {
2710                         value = "$mysql_hostname$"
2711                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
2712                 }
2713                 "-P" = {
2714                         value = "$mysql_port$"
2715                         description = "Port number (default: 3306)"
2716                 }
2717                 "-n" = {
2718                         set_if = "$mysql_ignore_auth$"
2719                         description = "Ignore authentication failure and check for mysql connectivity only"
2720                 }
2721                 "-s" = {
2722                         value = "$mysql_socket$"
2723                         description = "Use the specified socket"
2724                 }
2725                 "-d" = {
2726                         value = "$mysql_database$"
2727                         description = "Check database with indicated name"
2728                 }
2729                 "-f" = {
2730                         value = "$mysql_file$"
2731                         description = "Read from the specified client options file"
2732                 }
2733                 "-g" = {
2734                         value = "$mysql_group$"
2735                         description = "Use a client options group"
2736                 }
2737                 "-u" = {
2738                         value = "$mysql_username$"
2739                         description = "Connect using the indicated username"
2740                 }
2741                 "-p" = {
2742                         value = "$mysql_password$"
2743                         description = "Use the indicated password to authenticate the connection"
2744                 }
2745                 "-S" = {
2746                         set_if = "$mysql_check_slave$"
2747                         description = "Check if the slave thread is running properly"
2748                 }
2749                 "-w" = {
2750                         value = "$mysql_warning$"
2751                         description = "Exit with WARNING status if slave server is more than INTEGER seconds behind master"
2752                 }
2753                 "-c" = {
2754                         value = "$mysql_critical$"
2755                         description = "Exit with CRITICAL status if slave server is more then INTEGER seconds behind master"
2756                 }
2757                 "-l" = {
2758                         set_if = "$mysql_ssl$"
2759                         description = "Use ssl encryptation"
2760                 }
2761                 "-C" = {
2762                         value = "$mysql_cacert$"
2763                         description = "Path to CA signing the cert"
2764                 }
2765                 "-a" = {
2766                         value = "$mysql_cert$"
2767                         description = "Path to SSL certificate"
2768                 }
2769                 "-k" = {
2770                         value = "$mysql_key$"
2771                         description = "Path to private SSL key"
2772                 }
2773                 "-D" = {
2774                         value = "$mysql_cadir$"
2775                         description = "Path to CA directory"
2776                 }
2777                 "-L" = {
2778                         value = "$mysql_ciphers$"
2779                         description = "List of valid SSL ciphers"
2780                 }
2781         }
2782
2783         vars.mysql_hostname = "$check_address$"
2784 }
2785
2786 object CheckCommand "negate" {
2787         command = [ PluginDir + "/negate" ]
2788
2789         arguments = {
2790                 "-t" = {
2791                         value = "$negate_timeout$"
2792                         description = "Seconds before plugin times out (default: 11)"
2793                 }
2794                 "-T" = {
2795                         value = "$negate_timeout_result$"
2796                         description = "Custom result on Negate timeouts"
2797                 }
2798                 "-o" = {
2799                         value = "$negate_ok$"
2800                 }
2801                 "-w" = {
2802                         value = "$negate_warning$"
2803                 }
2804                 "-c" = {
2805                         value = "$negate_critical$"
2806                 }
2807                 "-u" = {
2808                         value = "$negate_unknown$"
2809                 }
2810                 "-s" = {
2811                         set_if = "$negate_substitute$"
2812                         description = "Substitute output text as well. Will only substitute text in CAPITALS"
2813                 }
2814                 "--wrapped-plugin" = {
2815                         value = {{
2816                                 var command = macro("$negate_command$")
2817                                 var arguments = macro("$negate_arguments$")
2818
2819                                 if (typeof(command) == String && !arguments) {
2820                                         return command
2821                                 }
2822
2823                                 var escaped_args = []
2824                                 for (arg in resolve_arguments(command, arguments)) {
2825                                         escaped_args.add(arg)
2826                                 }
2827                                 return escaped_args.join(" ")
2828                         }}
2829                         skip_key = true
2830                         order = 1
2831                 }
2832         }
2833
2834         vars.negate_timeout_result = "UNKNOWN"
2835 }
2836
2837 object CheckCommand "file_age" {
2838         command = [ PluginDir + "/check_file_age" ]
2839
2840         arguments = {
2841                 "-w" = {
2842                         value = "$file_age_warning_time$"
2843                         description = "File must be no more than this many seconds old (default: 240s)"
2844                 }
2845                 "-c" = {
2846                         value = "$file_age_critical_time$"
2847                         description = "File must be no more than this many seconds old (default: 600s)"
2848                 }
2849                 "-W" = {
2850                         value = "$file_age_warning_size$"
2851                         description = "File must be at least this many bytes long"
2852                 }
2853                 "-C" = {
2854                         value = "$file_age_critical_size$"
2855                         description = "File must be at least this many bytes long (default: 0B)"
2856                 }
2857                 "-i" = {
2858                         set_if = "$file_age_ignoremissing$"
2859                         description = "return OK if the file does not exist"
2860                 }
2861                 "-f" = {
2862                         value = "$file_age_file$"
2863                         description = "File to monitor"
2864                 }
2865         }
2866
2867         vars.file_age_ignoremissing = false
2868 }
2869
2870 object CheckCommand "smart" {
2871         command = [ PluginDir + "/check_ide_smart" ]
2872
2873         arguments = {
2874                 "-d" = {
2875                         value = "$smart_device$"
2876                         description = "Name of a local hard drive to monitor"
2877                         required = true
2878                 }
2879         }
2880 }
2881
2882 object CheckCommand "breeze" {
2883         import "ipv4-or-ipv6"
2884
2885         command = [ PluginDir + "/check_breeze" ]
2886
2887         arguments = {
2888                 "-H" = {
2889                         value = "$breeze_hostname$"
2890                         description = "Name or IP address of host to check"
2891                         required = true
2892                 }
2893                 "-C" = {
2894                         value = "$breeze_community$"
2895                         description = "SNMPv1 community (default public)"
2896                 }
2897                 "-w" = {
2898                         value = "$breeze_warning$"
2899                         description = "Percentage strength below which a WARNING status will result"
2900                         required = true
2901                 }
2902                 "-c" = {
2903                         value = "$breeze_critical$"
2904                         description = "Percentage strength below which a CRITICAL status will result"
2905                         required = true
2906                 }
2907         }
2908
2909         vars.breeze_hostname = "$check_address$"
2910         vars.breeze_warning = "50"
2911         vars.breeze_critical = "20"
2912 }
2913
2914 object CheckCommand "flexlm" {
2915         command = [ PluginDir + "/check_flexlm" ]
2916
2917         arguments = {
2918                 "-F" = {
2919                         value = "$flexlm_licensefile$"
2920                         description = "Name of license file (usually license.dat)"
2921                         required = true
2922                 }
2923                 "-t" = {
2924                         value = "$flexlm_timeout$"
2925                         description = "Plugin time out in seconds (default = 15)"
2926                 }
2927         }
2928 }
2929
2930 object CheckCommand "game" {
2931         import "ipv4-or-ipv6"
2932
2933         command = [ PluginDir + "/check_game" ]
2934
2935         arguments = {
2936                 "-P" = {
2937                         value = "$game_port$"
2938                         description = "Port to connect to"
2939                 }
2940                 "-t" = {
2941                         value = "$game_timeout$"
2942                         description = "Seconds before connection times out (default: 10)"
2943                 }
2944                 "-g" = {
2945                         value = "$game_gamefield$"
2946                         description = "Field number in raw qstat output that contains game name"
2947                 }
2948                 "-m" = {
2949                         value = "$game_mapfield$"
2950                         description = "Field number in raw qstat output that contains map name"
2951                 }
2952                 "-p" = {
2953                         value = "$game_pingfield$"
2954                         description = "Field number in raw qstat output that contains ping time"
2955                 }
2956                 "-G" = {
2957                         value = "$game_gametime$"
2958                         description = "Field number in raw qstat output that contains game time"
2959                 }
2960                 "-H" = {
2961                         value = "$game_hostname$"
2962                         description = "Name of the host running the game"
2963                 }
2964                 "game" = {
2965                         value = "$game_game$"
2966                         description = "Name of the game"
2967                         order = 1
2968                         skip_key = true
2969                 }
2970                 "ipaddress" = {
2971                         value = "$game_ipaddress$"
2972                         description = "Ipaddress of the game server to query"
2973                         order = 2
2974                         skip_key = true
2975                 }
2976         }
2977 }
2978
2979 object CheckCommand "mysql_query" {
2980         import "ipv4-or-ipv6"
2981
2982         command = [ PluginDir + "/check_mysql_query" ]
2983
2984         arguments = {
2985                 "-H" = {
2986                         value = "$mysql_query_hostname$"
2987                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
2988                 }
2989                 "-P" = {
2990                         value = "$mysql_query_port$"
2991                         description = "Port number (default: 3306)"
2992                 }
2993                 "-u" = {
2994                         value = "$mysql_query_username$"
2995                         description = "Username to login with"
2996                 }
2997                 "-p" = {
2998                         value = "$mysql_query_password$"
2999                         description = "Password to login with"
3000                 }
3001                 "-d" = {
3002                         value = "$mysql_query_database$"
3003                         description = "Database to check"
3004                 }
3005                 "-f" = {
3006                         value = "$mysql_query_file$"
3007                         description = "Read from the specified client options file"
3008                 }
3009                 "-g" = {
3010                         value = "$mysql_query_group$"
3011                         description = "Use a client options group"
3012                 }
3013                 "-q" = {
3014                         value = "$mysql_query_execute$"
3015                         description = "SQL query to run. Only first column in first row will be read"
3016                 }
3017                 "-w" = {
3018                         value = "$mysql_query_warning$"
3019                         description = "Warning range (format: start:end). Alert if outside this range"
3020                 }
3021                 "-c" = {
3022                         value = "$mysql_query_critical$"
3023                         description = "Critical range"
3024                 }
3025         }
3026
3027         vars.mysql_query_hostname = "$check_address$"
3028 }
3029
3030 object CheckCommand "radius" {
3031         import "ipv4-or-ipv6"
3032
3033         command = [
3034                 PluginDir + "/check_radius",
3035         ]
3036
3037         arguments = {
3038                 "-H" = {
3039                         value = "$radius_address$",
3040                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
3041                 }
3042                 "-F" = {
3043                         value = "$radius_config_file$",
3044                         description = "Configuration file"
3045                 }
3046                 "-u" = {
3047                         value = "$radius_username$",
3048                         description = "The user to authenticate"
3049                 }
3050                 "-p" = {
3051                         value = "$radius_password$",
3052                         description = "Password for authentication"
3053                 }
3054                 "-P" = {
3055                         value = "$radius_port$",
3056                         description = "Port number (default: 1645)"
3057                 },
3058                 "-n" = {
3059                         value = "$radius_nas_id$",
3060                         description = "NAS identifier"
3061                 }
3062                 "-N" = {
3063                         value = "$radius_nas_address$",
3064                         description = "NAS IP Address"
3065                 },
3066                 "-e" = {
3067                         value = "$radius_expect$",
3068                         description = "Response string to expect from the server"
3069                 },
3070                 "-r" = {
3071                         value = "$radius_retries$",
3072                         description = "Number of times to retry a failed connection"
3073                 },
3074                 "-t" = {
3075                         value = "$radius_timeout$",
3076                         description = "Seconds before connection times out (default: 10) Optional :<timeout state> can be a state integer (0,1,2,3) or a state STRING"
3077                 },
3078         }
3079
3080         vars.radius_address = "$check_address$"
3081 }
3082
3083 object CheckCommand "nscp_api" {
3084         import "ipv4-or-ipv6"
3085
3086         command = [ PluginDir + "/check_nscp_api" ]
3087
3088         arguments = {
3089                 "-H" = {
3090                         value = "$nscp_api_host$"
3091                         description = "NSCP API host address"
3092                         required = true
3093                 }
3094                 "-P" = {
3095                         value = "$nscp_api_port$"
3096                         description = "NSCP API host port. Defaults to 8443."
3097                 }
3098                 "--password" = {
3099                         value = "$nscp_api_password$"
3100                         description = "NSCP API password"
3101                 }
3102                 "-q" = {
3103                         value = "$nscp_api_query$"
3104                         description = "NSCPI API Query endpoint to use"
3105                 }
3106                 "-a" = {
3107                         value = "$nscp_api_arguments$"
3108                         description = "NSCP API Query arguments"
3109                         repeat_key = true
3110                 }
3111         }
3112
3113         vars.nscp_api_host = "$check_address$"
3114 }