]> granicus.if.org Git - icinga2/blob - itl/command-plugins.conf
Merge pull request #5164 from rhopfer/master
[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" = "$ping_address$"
41                 "-w" = "$ping_wrta$,$ping_wpl$%"
42                 "-c" = "$ping_crta$,$ping_cpl$%"
43                 "-p" = "$ping_packets$"
44                 "-t" = "$ping_timeout$"
45         }
46
47         vars.ping_wrta = 100
48         vars.ping_wpl = 5
49         vars.ping_crta = 200
50         vars.ping_cpl = 15
51 }
52
53 object CheckCommand "ping" {
54         import "ping-common"
55         import "ipv4-or-ipv6"
56
57         vars.ping_address = "$check_address$"
58 }
59
60 object CheckCommand "ping4" {
61         import "ping-common"
62
63         command += [ "-4" ]
64
65         vars.ping_address = "$address$"
66 }
67
68 object CheckCommand "ping6" {
69         import "ping-common"
70
71         command += [ "-6" ]
72
73         vars.ping_address = "$address6$"
74 }
75
76 template CheckCommand "hostalive-common" {
77         vars.ping_wrta = 3000.0
78         vars.ping_wpl = 80
79
80         vars.ping_crta = 5000.0
81         vars.ping_cpl = 100
82 }
83
84 object CheckCommand "hostalive" {
85         import "ping"
86         import "hostalive-common"
87 }
88
89 object CheckCommand "hostalive4" {
90         import "ping4"
91         import "hostalive-common"
92 }
93
94 object CheckCommand "hostalive6" {
95         import "ping6"
96         import "hostalive-common"
97 }
98
99 template CheckCommand "fping-common" {
100         command = [
101                 PluginDir + "/check_fping",
102                 "$fping_address$"
103         ]
104
105         arguments = {
106                 "-w" = "$fping_wrta$,$fping_wpl$%"
107                 "-c" = "$fping_crta$,$fping_cpl$%"
108                 "-n" = "$fping_number$"
109                 "-i" = "$fping_interval$"
110                 "-b" = "$fping_bytes$"
111                 "-T" = "$fping_target_timeout$"
112                 "-S" = "$fping_source_ip$"
113                 "-I" = "$fping_source_interface$"
114         }
115
116         vars.fping_wrta = 100
117         vars.fping_wpl = 5
118         vars.fping_crta = 200
119         vars.fping_cpl = 15
120         vars.fping_number = 5
121         vars.fping_interval = 500
122 }
123
124 object CheckCommand "fping4" {
125         import "fping-common"
126
127         command += [ "-4" ]
128
129         vars.fping_address = "$address$"
130 }
131
132 object CheckCommand "fping6" {
133         import "fping-common"
134
135         command += [ "-6" ]
136
137         vars.fping_address = "$address6$"
138 }
139
140 object CheckCommand "dummy" {
141         command = [ PluginDir + "/check_dummy" ]
142
143         arguments = {
144                 "state" = {
145                         value = "$dummy_state$"
146                         skip_key = true
147                         order = 1
148                         description = "The state. Can be one of 0 (ok), 1 (warning), 2 (critical) and 3 (unknown). Defaults to 0."
149                 }
150                 "text" = {
151                         value = "$dummy_text$"
152                         skip_key = true
153                         order = 2
154                         description = "Plugin output. Defaults to Check was successful."
155                 }
156         }
157
158         vars.dummy_state = 0
159         vars.dummy_text = "Check was successful."
160 }
161
162 object CheckCommand "passive" {
163         import "dummy"
164
165         vars.dummy_state = 3
166         vars.dummy_text = "No Passive Check Result Received."
167 }
168
169 object CheckCommand "tcp" {
170         import "ipv4-or-ipv6"
171
172         command = [ PluginDir + "/check_tcp" ]
173
174         arguments = {
175                 "-H" = {
176                         value =  "$tcp_address$"
177                         description = "Host name, IP Address, or unix socket (must be an absolute path)."
178                 }
179                 "-p" = {
180                         value =  "$tcp_port$"
181                         description = "The TCP port number."
182                 }
183                 "-e" = {
184                         value = "$tcp_expect$"
185                         description = "String to expect in server response (may be repeated)."
186                 }
187                 "-A" = {
188                         set_if = "$tcp_all$"
189                         description = "All expect strings need to occur in server response. Defaults to false."
190                 }
191                 "-E_send" = {
192                         key = "-E"
193                         order = 1
194                         set_if = "$tcp_escape_send$"
195                         description = "Enable usage of \n, \r, \t or \\ in send string."
196                 }
197                 "-s" = {
198                         order = 2
199                         value = "$tcp_send$"
200                         description = "String to send to the server."
201                 }
202                 "-E_quit" = {
203                         key = "-E"
204                         order = 3
205                         set_if = "$tcp_escape_quit$"
206                         description = "Enable usage of \n, \r, \t or \\ in quit string."
207                 }
208                 "-q" = {
209                         order = 4
210                         value = "$tcp_quit$"
211                         description = "String to send server to initiate a clean close of the connection."
212                 }
213                 "-r" = {
214                         value = "$tcp_refuse$"
215                         description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
216                 }
217                 "-M" = {
218                         value = "$tcp_mismatch$"
219                         description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
220                 }
221                 "-j" = {
222                         set_if = "$tcp_jail$"
223                         description = "Hide output from TCP socket."
224                 }
225                 "-m" = {
226                         value = "$tcp_maxbytes$"
227                         description = "Close connection once more than this number of bytes are received."
228                 }
229                 "-d" = {
230                         value = "$tcp_delay$"
231                         description = "Seconds to wait between sending string and polling for response."
232                 }
233                 "-D" = {
234                         value = "$tcp_certificate$"
235                         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."
236                 }
237                 "-S" = {
238                         set_if = "$tcp_ssl$"
239                         description = "Use SSL for the connection."
240                 }
241                 "-w" = {
242                         value = "$tcp_wtime$"
243                         description = "Response time to result in warning status (seconds)."
244                 }
245                 "-c" = {
246                         value = "$tcp_ctime$"
247                         description = "Response time to result in critical status (seconds)."
248                 }
249                 "-t" = {
250                         value = "$tcp_timeout$"
251                         description = "Seconds before connection times out. Defaults to 10."
252                 }
253                 "-4" = {
254                         set_if = "$tcp_ipv4$"
255                         description = "Use IPv4 connection"
256                 }
257                 "-6" = {
258                         set_if = "$tcp_ipv6$"
259                         description = "Use IPv6 connection"
260                 }
261         }
262
263         vars.tcp_address = "$check_address$"
264         vars.tcp_all = false
265         vars.tcp_refuse = "crit"
266         vars.tcp_mismatch = "warn"
267         vars.tcp_timeout = 10
268         vars.check_ipv4 = "$tcp_ipv4$"
269         vars.check_ipv6 = "$tcp_ipv6$"
270 }
271
272 object CheckCommand "ssl" {
273         import "ipv4-or-ipv6"
274
275         command = [ PluginDir + "/check_tcp" ]
276
277         arguments = {
278                 "-H" = {
279                         value = "$ssl_address$"
280                         description = "Host address"
281                 }
282                 "-p" = {
283                         value = "$ssl_port$"
284                         description ="TCP port (default: 443)"
285                 }
286                 "--ssl" = { }
287                 "-t" = {
288                         value = "$ssl_timeout$"
289                         description = "Seconds before connection times out (default: 10)"
290                 }
291                 "-D" = {{
292                         var days_warn = macro("$ssl_cert_valid_days_warn$")
293                         var days_critical = macro("$ssl_cert_valid_days_critical$")
294                         if (days_warn) {
295                                 if (days_critical) {
296                                         return days_warn + "," + days_critical
297                                 } else {
298                                         return days_warn
299                                 }
300                         }
301                 }}
302                 "-N" = "$ssl_sni$"
303         }
304
305         vars.ssl_address = "$check_address$"
306         vars.ssl_port = 443
307         vars.ssl_cert_valid_days_warn = false
308         vars.ssl_cert_valid_days_critical = false
309         vars.ssl_sni = "$ssl_address$"
310 }
311
312
313 object CheckCommand "udp" {
314         import "ipv4-or-ipv6"
315
316         command = [
317                 PluginDir + "/check_udp",
318                 "-H", "$udp_address$",
319                 "-p", "$udp_port$"
320         ]
321
322         arguments = {
323                 "-s" = {
324                         value = "$udp_send$"
325                         required = true
326                 }
327                 "-e" = {
328                         value = "$udp_expect$"
329                         required = true
330                 }
331                 "-q" = "$udp_quit$"
332                 "-4" = {
333                         set_if = "$udp_ipv4$"
334                         description = "Use IPv4 connection"
335                 }
336                 "-6" = {
337                         set_if = "$udp_ipv6$"
338                         description = "Use IPv6 connection"
339                 }
340         }
341
342         vars.udp_address = "$check_address$"
343         vars.check_ipv4 = "$udp_ipv4$"
344         vars.check_ipv6 = "$udp_ipv6$"
345 }
346
347 object CheckCommand "http" {
348         import "ipv4-or-ipv6"
349
350         command = [ PluginDir + "/check_http" ]
351
352         arguments = {
353                 "-H" = "$http_vhost$"
354                 "-I" = "$http_address$"
355                 "-u" = "$http_uri$"
356                 "-p" = "$http_port$"
357                 "-S" = {
358                         set_if = "$http_ssl$"
359                 }
360                 "-S1" = {
361                         set_if = "$http_ssl_force_tlsv1$"
362                 }
363                 "-S1.1" = {
364                         set_if = "$http_ssl_force_tlsv1_1$"
365                 }
366                 "-S1.2" = {
367                         set_if = "$http_ssl_force_tlsv1_2$"
368                 }
369                 "-S2" = {
370                         set_if = "$http_ssl_force_sslv2$"
371                 }
372                 "-S3" = {
373                         set_if = "$http_ssl_force_sslv3$"
374                 }
375                 "-S1+" = {
376                         set_if = "$http_ssl_force_tlsv1_or_higher$"
377                 }
378                 "-S1.1+" = {
379                         set_if = "$http_ssl_force_tlsv1_1_or_higher$"
380                 }
381                 "-S1.2+" = {
382                         set_if = "$http_ssl_force_tlsv1_2_or_higher$"
383                 }
384                 "-S2+" = {
385                         set_if = "$http_ssl_force_sslv2_or_higher$"
386                 }
387                 "-S3+" = {
388                         set_if = "$http_ssl_force_sslv3_or_higher$"
389                 }
390                 "--sni" = {
391                         set_if = "$http_sni$"
392                 }
393                 "-C" = {
394                         value = "$http_certificate$"
395                         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."
396                 }
397                 "-J" = {
398                         value = "$http_clientcert$"
399                         description = "Name of file contains the client certificate (PEM format)"
400                 }
401                 "-K" = {
402                         value = "$http_privatekey$"
403                         description = "Name of file contains the private key (PEM format)"
404                 }
405                 "-a" = {
406                         value = "$http_auth_pair$"
407                         description = "Username:password on sites with basic authentication"
408                 }
409                 "--no-body" = {
410                         set_if = "$http_ignore_body$"
411                 }
412                 "-w" = "$http_warn_time$"
413                 "-c" = "$http_critical_time$"
414                 "-e" = "$http_expect$"
415                 "-d" = {
416                         value = "$http_headerstring$"
417                         description = "String to expect in the response headers"
418                 }
419                 "-s" = {
420                         value = "$http_string$"
421                         description = "String to expect in the content"
422                 }
423                 "-P" = {
424                         value = "$http_post$"
425                         description = "URL encoded http POST data"
426                 }
427                 "-j" = {
428                         value = "$http_method$"
429                         description = "Set http method (for example: HEAD, OPTIONS, TRACE, PUT, DELETE)"
430                 }
431                 "-M" = {
432                         value = "$http_maxage$"
433                         description = "Warn if document is more than seconds old"
434                 }
435                 "-T" = {
436                         value = "$http_contenttype$"
437                         description = "Specify Content-Type header when POSTing"
438                 }
439                 "-l" = {
440                         set_if = "$http_linespan$"
441                         description = "Allow regex to span newline"
442                         order = 1
443                 }
444                 "-r" = {
445                         value = "$http_expect_body_regex$"
446                         description = "Search page for regex"
447                         order = 2
448                 }
449                 "-R" = {
450                         value = "$http_expect_body_eregi$"
451                         description = "Search page for case-insensitive regex"
452                         order = 2
453                 }
454                 "--invert-regex" = {
455                         set_if = "$http_invertregex$"
456                         description = "Return CRITICAL if found, OK if not"
457                 }
458                 "-b" = {
459                         value = "$http_proxy_auth_pair$"
460                         description = "Username:password on proxy-servers with basic authentication"
461                 }
462                 "-A" = {
463                         value = "$http_useragent$"
464                         description = "String to be sent in http header as User Agent"
465                 }
466                 "-k" = {
467                         value = "$http_header$"
468                         description = "Any other tags to be sent in http header"
469                 }
470                 "-E" = {
471                         set_if = "$http_extendedperfdata$"
472                         description = "Print additional perfdata"
473                 }
474                 "-f" = {
475                         value = "$http_onredirect$"
476                         description = "How to handle redirect pages"
477                 }
478                 "-m" = {
479                         value = "$http_pagesize$"
480                         description = "Minim page size required:Maximum page size required"
481                 }
482                 "-t" = {
483                         value = "$http_timeout$"
484                         description = "Seconds before connection times out"
485                 }
486                 "-4" = {
487                         set_if = "$http_ipv4$"
488                         description = "Use IPv4 connection"
489                 }
490                 "-6" = {
491                         set_if = "$http_ipv6$"
492                         description = "Use IPv6 connection"
493                 }
494                 "-L" = {
495                         set_if = "$http_link$"
496                         description = "Wrap output in HTML link"
497                 }
498                 "-v" = {
499                         set_if = "$http_verbose$"
500                         description = "Show details for command-line debugging"
501                 }
502         }
503
504         vars.http_address = "$check_address$"
505         vars.http_ssl = false
506         vars.http_sni = false
507         vars.http_linespan = false
508         vars.http_invertregex = false
509         vars.check_ipv4 = "$http_ipv4$"
510         vars.check_ipv6 = "$http_ipv6$"
511         vars.http_link = false
512         vars.http_verbose = false
513 }
514
515 object CheckCommand "ftp" {
516         import "ipv4-or-ipv6"
517
518         command = [ PluginDir + "/check_ftp" ]
519
520         arguments = {
521                 "-H" = {
522                         value = "$ftp_address$"
523                         description = "The host's address. Defaults to $address$ or $address6$ if the address attribute is not set."
524                 }
525                 "-p" = {
526                         value = "$ftp_port$"
527                         description = "The FTP port number. Defaults to none"
528                 }
529                 "-e" = {
530                         value = "$ftp_expect$"
531                         description = "String to expect in server response (may be repeated)."
532                 }
533                 "-A" = {
534                         set_if = "$ftp_all$"
535                         description = "All expect strings need to occur in server response. Default is any."
536                 }
537                 "-E_send" = {
538                         key = "-E"
539                         order = 1
540                         set_if = "$ftp_escape_send$"
541                         description = "Enable usage of \n, \r, \t or \\ in send string. Default is nothing."
542                 }
543                 "-s" = {
544                         order = 2
545                         value = "$ftp_send$"
546                         description = "String to send to the server."
547                 }
548                 "-E_quit" = {
549                         key = "-E"
550                         order = 3
551                         set_if = "$ftp_escape_quit$"
552                         description = "Can use \n, \r, \t or \\ in quit string. Default is \r\n added to end of quit."
553                 }
554                 "-q" = {
555                         order = 4
556                         value = "$ftp_quit$"
557                         description = "String to send server to initiate a clean close of the connection."
558                 }
559                 "-r" = {
560                         value = "$ftp_refuse$"
561                         description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
562                 }
563                 "-M" = {
564                         value = "$ftp_mismatch$"
565                         description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
566                 }
567                 "-j" = {
568                         set_if = "$ftp_jail$"
569                         description = "Hide output from TCP socket."
570                 }
571                 "-m" = {
572                         value = "$ftp_maxbytes$"
573                         description = "Close connection once more than this number of bytes are received."
574                 }
575                 "-d" = {
576                         value = "$ftp_delay$"
577                         description = "Seconds to wait between sending string and polling for response."
578                 }
579                 "-D" = {
580                         value = "$ftp_certificate$"
581                         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."
582                 }
583                 "-S" = {
584                         set_if = "$ftp_ssl$"
585                         description = "Use SSL for the connection."
586                 }
587                 "-w" = {
588                         value = "$ftp_wtime$"
589                         description = "Response time to result in warning status (seconds)."
590                 }
591                 "-c" = {
592                         value = "$ftp_ctime$"
593                         description = "Response time to result in critical status (seconds)."
594                 }
595                 "-t" = {
596                         value = "$ftp_timeout$"
597                         description = "Seconds before connection times out. Defaults to 10."
598                 }
599                 "-4" = {
600                         set_if = "$ftp_ipv4$"
601                         description = "Use IPv4 connection"
602                 }
603                 "-6" = {
604                         set_if = "$ftp_ipv6$"
605                         description = "Use IPv6 connection"
606                 }
607         }
608
609         vars.ftp_address = "$check_address$"
610         vars.ftp_ssl = false
611         vars.ftp_refuse = "crit"
612         vars.ftp_mismatch = "warn"
613         vars.ftp_timeout = 10
614         vars.check_ipv4 = "$ftp_ipv4$"
615         vars.check_ipv6 = "$ftp_ipv6$"
616 }
617
618 object CheckCommand "smtp" {
619         import "ipv4-or-ipv6"
620
621         command = [ PluginDir + "/check_smtp" ]
622
623         arguments = {
624                 "-H" = "$smtp_address$"
625                 "-p" = "$smtp_port$"
626                 "-f" = "$smtp_mail_from$"
627                 "-e" = "$smtp_expect$"
628                 "-C" = "$smtp_command$"
629                 "-R" = "$smtp_response$"
630                 "-F" = "$smtp_helo_fqdn$"
631                 "-D" = "$smtp_certificate_age$"
632                 "-S" = {
633                         set_if = "$smtp_starttls$"
634                         description = "Use STARTTLS for the connection."
635                 }
636                 "-A" = "$smtp_authtype$"
637                 "-U" = "$smtp_authuser$"
638                 "-P" = "$smtp_authpass$"
639                 "-q" = "$smtp_ignore_quit$"
640                 "-w" = "$smtp_warning$"
641                 "-c" = "$smtp_critical$"
642                 "-t" = "$smtp_timeout$"
643                 "-4" = {
644                         set_if = "$smtp_ipv4$"
645                         description = "Use IPv4 connection"
646                 }
647                 "-6" = {
648                         set_if = "$smtp_ipv6$"
649                         description = "Use IPv6 connection"
650                 }
651         }
652
653         vars.smtp_address = "$check_address$"
654         vars.check_ipv4 = "$smtp_ipv4$"
655         vars.check_ipv6 = "$smtp_ipv6$"
656 }
657
658 object CheckCommand "ssmtp" {
659         import "ipv4-or-ipv6"
660
661         command = [ PluginDir + "/check_ssmtp" ]
662
663         arguments = {
664                 "-H" = "$ssmtp_address$"
665                 "-p" = "$ssmtp_port$"
666                 "-E" = "$ssmtp_escape$"
667                 "-s" = "$ssmtp_send$"
668                 "-e" = "$ssmtp_expect$"
669                 "-A" = {
670                         set_if = "$ssmtp_all$"
671                         description = "All expect strings need to occur in server response. Default is any."
672                 }
673                 "-q" = "$ssmtp_quit$"
674                 "-r" = "$ssmtp_refuse$"
675                 "-M" = "$ssmtp_mismatch$"
676                 "-j" = {
677                         set_if = "$ssmtp_jail$"
678                         description = "Hide output from TCP socket."
679                 }
680                 "-m" = "$ssmtp_maxbytes$"
681                 "-d" = "$ssmtp_delay$"
682                 "-D" = "$ssmtp_certificate_age$"
683                 "-S" = {
684                         set_if = "$ssmtp_ssl$"
685                         description = "Use SSL for the connection."
686                 }
687                 "-w" = "$ssmtp_warning$"
688                 "-c" = "$ssmtp_critical$"
689                 "-t" = "$ssmtp_timeout$"
690                 "-4" = {
691                         set_if = "$ssmtp_ipv4$"
692                         description = "Use IPv4 connection"
693                 }
694                 "-6" = {
695                         set_if = "$ssmtp_ipv6$"
696                         description = "Use IPv6 connection"
697                 }
698         }
699
700         vars.ssmtp_address = "$check_address$"
701         vars.check_ipv4 = "$ssmtp_ipv4$"
702         vars.check_ipv6 = "$ssmtp_ipv6$"
703 }
704
705 object CheckCommand "imap" {
706         import "ipv4-or-ipv6"
707
708         command = [ PluginDir + "/check_imap" ]
709
710         arguments = {
711                 "-H" = "$imap_address$"
712                 "-p" = "$imap_port$"
713                 "-E" = "$imap_escape$"
714                 "-s" = "$imap_send$"
715                 "-e" = "$imap_expect$"
716                 "-A" = {
717                         set_if = "$imap_all$"
718                         description = "All expect strings need to occur in server response. Default is any."
719                 }
720                 "-q" = "$imap_quit$"
721                 "-r" = "$imap_refuse$"
722                 "-M" = "$imap_mismatch$"
723                 "-j" = {
724                         set_if = "$imap_jail$"
725                         description = "Hide output from TCP socket."
726                 }
727                 "-m" = "$imap_maxbytes$"
728                 "-d" = "$imap_delay$"
729                 "-D" = "$imap_certificate_age$"
730                 "-S" = {
731                         set_if = "$imap_ssl$"
732                         description = "Use SSL for the connection."
733                 }
734                 "-w" = "$imap_warning$"
735                 "-c" = "$imap_critical$"
736                 "-t" = "$imap_timeout$"
737                 "-4" = {
738                         set_if = "$imap_ipv4$"
739                         description = "Use IPv4 connection"
740                 }
741                 "-6" = {
742                         set_if = "$imap_ipv6$"
743                         description = "Use IPv6 connection"
744                 }
745         }
746
747         vars.imap_address = "$check_address$"
748         vars.check_ipv4 = "$imap_ipv4$"
749         vars.check_ipv6 = "$imap_ipv6$"
750 }
751
752 object CheckCommand "simap" {
753         import "ipv4-or-ipv6"
754
755         command = [ PluginDir + "/check_simap" ]
756
757         arguments = {
758                 "-H" = "$simap_address$"
759                 "-p" = "$simap_port$"
760                 "-E" = "$simap_escape$"
761                 "-s" = "$simap_send$"
762                 "-e" = "$simap_expect$"
763                 "-A" = {
764                         set_if = "$simap_all$"
765                         description = "All expect strings need to occur in server response. Default is any."
766                 }
767                 "-q" = "$simap_quit$"
768                 "-r" = "$simap_refuse$"
769                 "-M" = "$simap_mismatch$"
770                 "-j" = {
771                         set_if = "$simap_jail$"
772                         description = "Hide output from TCP socket."
773                 }
774                 "-m" = "$simap_maxbytes$"
775                 "-d" = "$simap_delay$"
776                 "-D" = "$simap_certificate_age$"
777                 "-S" = {
778                         set_if = "$simap_ssl$"
779                         description = "Use SSL for the connection."
780                 }
781                 "-w" = "$simap_warning$"
782                 "-c" = "$simap_critical$"
783                 "-t" = "$simap_timeout$"
784                 "-4" = {
785                         set_if = "$simap_ipv4$"
786                         description = "Use IPv4 connection"
787                 }
788                 "-6" = {
789                         set_if = "$simap_ipv6$"
790                         description = "Use IPv6 connection"
791                 }
792         }
793
794         vars.simap_address = "$check_address$"
795         vars.check_ipv4 = "$simap_ipv4$"
796         vars.check_ipv6 = "$simap_ipv6$"
797 }
798
799 object CheckCommand "pop" {
800         import "ipv4-or-ipv6"
801
802         command = [ PluginDir + "/check_pop" ]
803
804         arguments = {
805                 "-H" = "$pop_address$"
806                 "-p" = "$pop_port$"
807                 "-E" = "$pop_escape$"
808                 "-s" = "$pop_send$"
809                 "-e" = "$pop_expect$"
810                 "-A" = {
811                         set_if = "$pop_all$"
812                         description = "All expect strings need to occur in server response. Default is any."
813                 }
814                 "-q" = "$pop_quit$"
815                 "-r" = "$pop_refuse$"
816                 "-M" = "$pop_mismatch$"
817                 "-j" = {
818                         set_if = "$pop_jail$"
819                         description = "Hide output from TCP socket."
820                 }
821                 "-m" = "$pop_maxbytes$"
822                 "-d" = "$pop_delay$"
823                 "-D" = "$pop_certificate_age$"
824                 "-S" = {
825                         set_if = "$pop_ssl$"
826                         description = "Use SSL for the connection."
827                 }
828                 "-w" = "$pop_warning$"
829                 "-c" = "$pop_critical$"
830                 "-t" = "$pop_timeout$"
831                 "-4" = {
832                         set_if = "$pop_ipv4$"
833                         description = "Use IPv4 connection"
834                 }
835                 "-6" = {
836                         set_if = "$pop_ipv6$"
837                         description = "Use IPv6 connection"
838                 }
839         }
840
841         vars.pop_address = "$check_address$"
842         vars.check_ipv4 = "$pop_ipv4$"
843         vars.check_ipv6 = "$pop_ipv6$"
844 }
845
846 object CheckCommand "spop" {
847         import "ipv4-or-ipv6"
848
849         command = [ PluginDir + "/check_spop" ]
850
851         arguments = {
852                 "-H" = "$spop_address$"
853                 "-p" = "$spop_port$"
854                 "-E" = "$spop_escape$"
855                 "-s" = "$spop_send$"
856                 "-e" = "$spop_expect$"
857                 "-A" = {
858                         set_if = "$spop_all$"
859                         description = "All expect strings need to occur in server response. Default is any."
860                 }
861                 "-q" = "$spop_quit$"
862                 "-r" = "$spop_refuse$"
863                 "-M" = "$spop_mismatch$"
864                 "-j" = {
865                         set_if = "$spop_jail$"
866                         description = "Hide output from TCP socket."
867                 }
868                 "-m" = "$spop_maxbytes$"
869                 "-d" = "$spop_delay$"
870                 "-D" = "$spop_certificate_age$"
871                 "-S" = {
872                         set_if = "$spop_ssl$"
873                         description = "Use SSL for the connection."
874                 }
875                 "-w" = "$spop_warning$"
876                 "-c" = "$spop_critical$"
877                 "-t" = "$spop_timeout$"
878                 "-4" = {
879                         set_if = "$spop_ipv4$"
880                         description = "Use IPv4 connection"
881                 }
882                 "-6" = {
883                         set_if = "$spop_ipv6$"
884                         description = "Use IPv6 connection"
885                 }
886         }
887
888         vars.spop_address = "$check_address$"
889         vars.check_ipv4 = "$spop_ipv4$"
890         vars.check_ipv6 = "$spop_ipv6$"
891 }
892
893 object CheckCommand "ntp_time" {
894         import "ipv4-or-ipv6"
895
896         command = [ PluginDir + "/check_ntp_time" ]
897
898         arguments = {
899                 "-H" = "$ntp_address$"
900                 "-p" = "$ntp_port$"
901                 "-q" = {
902                         set_if = "$ntp_quiet$"
903                         description = "Returns UNKNOWN instead of CRITICAL if offset cannot be found"
904                 }
905                 "-w" = "$ntp_warning$"
906                 "-c" = "$ntp_critical$"
907                 "-o" = "$ntp_timeoffset$"
908                 "-t" = "$ntp_timeout$"
909                 "-4" = {
910                         set_if = "$ntp_ipv4$"
911                         description = "Use IPv4 connection"
912                 }
913                 "-6" = {
914                         set_if = "$ntp_ipv6$"
915                         description = "Use IPv6 connection"
916                 }
917         }
918
919         vars.ntp_address = "$check_address$"
920         vars.check_ipv4 = "$ntp_ipv4$"
921         vars.check_ipv6 = "$ntp_ipv6$"
922 }
923
924 object CheckCommand "ntp_peer" {
925         import "ipv4-or-ipv6"
926
927         command = [ PluginDir + "/check_ntp_peer" ]
928
929         arguments = {
930                 "-H" = "$ntp_address$"
931                 "-p" = "$ntp_port$"
932                 "-w" = "$ntp_warning$"
933                 "-c" = "$ntp_critical$"
934                 "-W" = "$ntp_wstratum$"
935                 "-C" = "$ntp_cstratum$"
936                 "-j" = "$ntp_wjitter$"
937                 "-k" = "$ntp_cjitter$"
938                 "-m" = "$ntp_wsource$"
939                 "-n" = "$ntp_csource$"
940                 "-t" = "$ntp_timeout$"
941                 "-4" = {
942                         set_if = "$ntp_ipv4$"
943                         description = "Use IPv4 connection"
944                 }
945                 "-6" = {
946                         set_if = "$ntp_ipv6$"
947                         description = "Use IPv6 connection"
948                 }
949         }
950
951         vars.ntp_address = "$check_address$"
952         vars.check_ipv4 = "$ntp_ipv4$"
953         vars.check_ipv6 = "$ntp_ipv6$"
954 }
955
956 object CheckCommand "ssh" {
957         import "ipv4-or-ipv6"
958
959         command = [ PluginDir + "/check_ssh" ]
960
961         arguments = {
962                 "-p" = "$ssh_port$"
963                 "-t" = "$ssh_timeout$"
964                 "host" = {
965                         value = "$ssh_address$"
966                         skip_key = true
967                         order = 1
968                 }
969                 "-4" = {
970                         set_if = "$ssh_ipv4$"
971                         description = "Use IPv4 connection"
972                 }
973                 "-6" = {
974                         set_if = "$ssh_ipv6$"
975                         description = "Use IPv6 connection"
976                 }
977         }
978
979         vars.ssh_address = "$check_address$"
980         vars.check_ipv4 = "$ssh_ipv4$"
981         vars.check_ipv6 = "$ssh_ipv6$"
982 }
983
984 object CheckCommand "disk" {
985         command = [ PluginDir + "/check_disk" ]
986
987         arguments = {
988                 "-w" = {
989                         value = "$disk_wfree$"
990                         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"
991                         required = true
992                         order = -3
993                 }
994
995                 "-c" = {
996                         value = "$disk_cfree$"
997                         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"
998                         required = true
999                         order = -3
1000                 }
1001
1002                 "-W" = {
1003                         value = "$disk_inode_wfree$"
1004                         description = "Exit with WARNING status if less than PERCENT of inode space is free"
1005                 }
1006
1007                 "-K" = {
1008                         value = "$disk_inode_cfree$"
1009                         description = "Exit with CRITICAL status if less than PERCENT of inode space is free"
1010                 }
1011
1012                 "-p" = {
1013                         value = "$disk_partitions$"
1014                         description = "Path or partition (may be repeated)"
1015                         repeat_key = true
1016                         order = 1
1017                 }
1018
1019                 "-p_old" = {
1020                         key = "-p"
1021                         value = "$disk_partition$"
1022                         order = 1
1023                 }
1024
1025                 "-x" = {
1026                         value = "$disk_partitions_excluded$"
1027                         description = "Ignore device (only works if -p unspecified)"
1028                 }
1029
1030                 "-x_old" = {
1031                         key = "-x"
1032                         value = "$disk_partition_excluded$"
1033                 }
1034
1035                 "-C" = {
1036                         set_if = "$disk_clear$"
1037                         description = "Clear thresholds"
1038                 }
1039
1040                 "-E" = {
1041                         set_if = "$disk_exact_match$"
1042                         description = "For paths or partitions specified with -p, only check for exact paths"
1043                 }
1044
1045                 "-e" = {
1046                         set_if = "$disk_errors_only$"
1047                         description = "Display only devices/mountpoints with errors"
1048                 }
1049
1050                 "-f" = {
1051                         set_if = "$disk_ignore_reserved$"
1052                         description = "Don't account root-reserved blocks into freespace in perfdata"
1053                 }
1054
1055                 "-g" = {
1056                         value = "$disk_group$"
1057                         description = "Group paths. Thresholds apply to (free-)space of all partitions together"
1058                 }
1059
1060                 "-k" = {
1061                         set_if = "$disk_kilobytes$"
1062                         description = "Same as --units kB"
1063                 }
1064
1065                 "-l" = {
1066                         set_if = "$disk_local$"
1067                         description = " Only check local filesystems"
1068                 }
1069
1070                 "-L" = {
1071                         set_if = "$disk_stat_remote_fs$"
1072                         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)"
1073                 }
1074
1075                 "-M" = {
1076                         set_if = "$disk_mountpoint$"
1077                         description = "Display the mountpoint instead of the partition"
1078                 }
1079
1080                 "-m" = {
1081                         set_if = "$disk_megabytes$"
1082                         description = "Same as --units MB"
1083                 }
1084
1085                 "-A" = {
1086                         set_if = "$disk_all$"
1087                         description = "Explicitly select all paths. This is equivalent to -R .*"
1088                 }
1089
1090                 "-R" = {
1091                         value = "$disk_eregi_path$"
1092                         description = "Case insensitive regular expression for path/partition (may be repeated)"
1093                         repeat_key = true
1094                 }
1095
1096                 "-r" = {
1097                         value = "$disk_ereg_path$"
1098                         description = "Regular expression for path or partition (may be repeated)"
1099                         repeat_key = true
1100                 }
1101
1102                 "-I" = {
1103                         value = "$disk_ignore_eregi_path$"
1104                         description = "Regular expression to ignore selected path/partition (case insensitive) (may be repeated)"
1105                         repeat_key = true
1106                         order = 2
1107                 }
1108
1109                 "-i" = {
1110                         value = "$disk_ignore_ereg_path$"
1111                         description = "Regular expression to ignore selected path or partition (may be repeated)"
1112                         repeat_key = true
1113                         order = 2
1114                 }
1115
1116                 "-t" = {
1117                         value = "$disk_timeout$"
1118                         description = "Seconds before connection times out (default: 10)"
1119                 }
1120
1121                 "-u" = {
1122                         value = "$disk_units$"
1123                         description = "Choose bytes, kB, MB, GB, TB (default: MB)"
1124                 }
1125
1126                 "-X" = {
1127                         value = "$disk_exclude_type$"
1128                         description = "Ignore all filesystems of indicated type (may be repeated)"
1129                         repeat_key = true
1130                 }
1131         }
1132
1133         vars.disk_wfree = "20%"
1134         vars.disk_cfree = "10%"
1135         vars.disk_megabytes = true
1136         vars.disk_exclude_type = [ "none", "tmpfs", "sysfs", "proc", "devtmpfs", "devfs", "mtmfs", "tracefs", "cgroup", "fuse.gvfsd-fuse", "fuse.gvfs-fuse-daemon", "fdescfs" ]
1137 }
1138
1139 object CheckCommand "disk_smb" {
1140         command = [ PluginDir + "/check_disk_smb" ]
1141
1142         arguments = {
1143                 "-H" = {
1144                         value = "$disk_smb_hostname$"
1145                         description = "NetBIOS name of the server."
1146                 }
1147                 "-s" = {
1148                         value = "$disk_smb_share$"
1149                         description = "Share name to be tested."
1150                 }
1151                 "-W" = {
1152                         value = "$disk_smb_workgroup$"
1153                         description = "Workgroup or Domain used (Defaults to 'WORKGROUP' if omitted)."
1154                 }
1155                 "-a" = {
1156                         value = "$disk_smb_address$"
1157                         description = "IP-address of HOST (only necessary if HOST is in another network)."
1158                 }
1159                 "-u" = {
1160                         value = "$disk_smb_username$"
1161                         description = "Username to log in to server. (Defaults to 'guest' if omitted)."
1162                 }
1163                 "-p" = {
1164                         value = "$disk_smb_password$"
1165                         description = "Password to log in to server. (Defaults to an empty password if omitted)."
1166                 }
1167                 "-w" = {
1168                         value = "$disk_smb_wused$"
1169                         description = "Percent of used space at which a warning will be generated (Default: 85%)."
1170                 }
1171                 "-c" = {
1172                         value = "$disk_smb_cused$"
1173                         description = "Percent of used space at which a critical will be generated (Defaults: 95%)"
1174                 }
1175                 "-P" = {
1176                         value = "$disk_smb_port$"
1177                         description = "Port to be used to connect to. Some Windows boxes use 139, others 445 (Defaults to smbclient default if omitted)."
1178                 }
1179         }
1180
1181         vars.disk_smb_wused = "85%"
1182         vars.disk_smb_cused = "95%"
1183 }
1184
1185 object CheckCommand "users" {
1186         command = [ PluginDir + "/check_users" ]
1187
1188         arguments = {
1189                 "-w" = "$users_wgreater$"
1190                 "-c" = "$users_cgreater$"
1191         }
1192
1193         vars.users_wgreater = 20
1194         vars.users_cgreater = 50
1195 }
1196
1197 object CheckCommand "procs" {
1198         command = [ PluginDir + "/check_procs" ]
1199
1200         arguments = {
1201                 "-w" = {
1202                         value = "$procs_warning$"
1203                         description = "Generate warning state if metric is outside this range" 
1204                 }
1205                 "-c" = {
1206                         value = "$procs_critical$"
1207                         description = "Generate critical state if metric is outside this range" 
1208                 }
1209                 "-m" = {
1210                         value = "$procs_metric$"
1211                         description = "Check thresholds against metric" 
1212                 }
1213                 "-t" = {
1214                         value = "$procs_timeout$"
1215                         description = "Seconds before plugin times out"
1216                 }
1217                 "-T" = {
1218                         set_if = "$procs_traditional$"
1219                         description = "Filter own process the traditional way by PID instead of /proc/pid/exe"
1220                 }
1221                 "-s" = {
1222                         value = "$procs_state$"
1223                         description = "Only scan for processes that have one or more of the status flags you specify"
1224                 }
1225                 "-p" = {
1226                         value = "$procs_ppid$"
1227                         description = "Only scan for children of the parent process ID indicated"
1228                 }
1229                 "-z" = {
1230                         value = "$procs_vsz$"
1231                         description = "Only scan for processes with VSZ higher than indicated"
1232                 }
1233                 "-r" = {
1234                         value = "$procs_rss$"
1235                         description = "Only scan for processes with RSS higher than indicated"
1236                 }
1237                 "-P" = {
1238                         value = "$procs_pcpu$"
1239                         description = "Only scan for processes with PCPU higher than indicated"
1240                 }
1241                 "-u" = {
1242                         value = "$procs_user$"
1243                         description = "Only scan for processes with user name or ID indicated"
1244                 }
1245                 "-a" = {
1246                         value = "$procs_argument$"
1247                         description = "Only scan for processes with args that contain STRING"
1248                 }
1249                 "--ereg-argument-array" = {
1250                         value = "$procs_argument_regex$"
1251                         description = "Only scan for processes with args that contain the regex STRING"
1252                 }
1253                 "-C" = {
1254                         value = "$procs_command$"
1255                         description = "Only scan for exact matches of COMMAND (without path)"
1256                 }
1257                 "-k" = {
1258                         set_if = "$procs_nokthreads$"
1259                         description = "Only scan for non kernel threads"
1260                 }
1261         }
1262
1263         vars.procs_traditional = false
1264         vars.procs_nokthreads = false
1265         vars.procs_warning = 250
1266         vars.procs_critical = 400
1267 }
1268
1269 object CheckCommand "swap" {
1270         command = [ PluginDir + "/check_swap" ]
1271
1272         arguments = {
1273                 "-w" = {{
1274                         if (macro("$swap_integer$")) {
1275                                 return macro("$swap_wfree$")
1276                         } else {
1277                                 return macro("$swap_wfree$%")
1278                         }
1279                 }}
1280                 "-c" = {{
1281                         if (macro("$swap_integer$")) {
1282                                 return macro("$swap_cfree$")
1283                         } else {
1284                                 return macro("$swap_cfree$%")
1285                         }
1286                 }}
1287                 "-a" = {
1288                         set_if = "$swap_allswaps$"
1289                         description = "Conduct comparisons for all swap partitions, one by one"
1290                 }
1291                 "-n" = {
1292                         value = "$swap_noswap$"
1293                         description = "Resulting state when there is no swap regardless of thresholds. Possible values are \"ok\", \"warning\", \"critical\", \"unknown\". Defaults to \"critical\""
1294                 }
1295         }
1296
1297         vars.swap_wfree = 50
1298         vars.swap_cfree = 25
1299         vars.swap_integer = false
1300         vars.swap_allswaps = false
1301 }
1302
1303 object CheckCommand "load" {
1304         command = [ PluginDir + "/check_load" ]
1305
1306         arguments = {
1307                 "-w" = {
1308                         value = "$load_wload1$,$load_wload5$,$load_wload15$"
1309                         description = "Exit with WARNING status if load average exceeds WLOADn"
1310                 }
1311                 "-c" = {
1312                         value = "$load_cload1$,$load_cload5$,$load_cload15$"
1313                         description = "Exit with CRITICAL status if load average exceed CLOADn; the load average format is the same used by 'uptime' and 'w'"
1314                 }
1315                 "-r" = {
1316                         set_if = "$load_percpu$"
1317                         description = "Divide the load averages by the number of CPUs (when possible)"
1318                 }
1319         }
1320
1321         vars.load_wload1 = 5.0
1322         vars.load_wload5 = 4.0
1323         vars.load_wload15 = 3.0
1324
1325         vars.load_cload1 = 10.0
1326         vars.load_cload5 = 6.0
1327         vars.load_cload15 = 4.0
1328
1329         vars.load_percpu = false
1330 }
1331
1332 object CheckCommand "snmp" {
1333         command = [ PluginDir + "/check_snmp" ]
1334
1335         arguments = {
1336                 "-H" = "$snmp_address$"
1337                 "-o" = "$snmp_oid$"
1338                 "-C" = "$snmp_community$"
1339                 "-c" = "$snmp_crit$"
1340                 "-w" = "$snmp_warn$"
1341                 "-s" = "$snmp_string$"
1342                 "-r" = "$snmp_ereg$"
1343                 "-R" = "$snmp_eregi$"
1344                 "-l" = "$snmp_label$"
1345                 "-u" = "$snmp_units$"
1346                 "-t" = "$snmp_timeout$"
1347                 "-p" = "$snmp_port$"
1348                 "-e" = "$snmp_retries$"
1349                 "--invert-search" = {
1350                         set_if = "$snmp_invert_search$"
1351                         description = "Invert search result and return CRITICAL if found"
1352                 }
1353                 "-P" = "$snmp_version$"
1354                 "-m" = "$snmp_miblist$"
1355                 "--rate-multiplier" = "$snmp_rate_multiplier$"
1356                 "--rate" = {
1357                         set_if = "$snmp_rate$"
1358                         description = "Enable rate calculation"
1359                 }
1360                 "-n" = {
1361                         set_if = "$snmp_getnext$"
1362                         description = "Use SNMP GETNEXT instead of SNMP GET"
1363                 }
1364         }
1365
1366         vars.snmp_address = {{
1367                 var addr_v4 = macro("$address$")
1368                 var addr_v6 = macro("$address6$")
1369
1370                 if (addr_v4) {
1371                         return addr_v4
1372                 } else {
1373                         return "udp6:[" + addr_v6 + "]"
1374                 }
1375         }}
1376
1377         vars.snmp_community = "public"
1378         vars.snmp_invert_search = false
1379         vars.snmp_timeout = "10"
1380 }
1381
1382 object CheckCommand "snmpv3" {
1383         import "ipv4-or-ipv6"
1384
1385         command = [ PluginDir + "/check_snmp" ]
1386
1387         arguments = {
1388                 "-H" = {
1389                         value = "$snmpv3_address$"
1390                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
1391                 }
1392                 "-p" = {
1393                         value = "$snmpv3_port$"
1394                         description = "Port number"
1395                 }
1396                 "-n" = {
1397                         set_if = "$snmpv3_getnext$"
1398                         description = "Use SNMP GETNEXT instead of SNMP GET"
1399                 }
1400                 "-P" = {
1401                         value = 3
1402                         description = "SNMP protocol version"
1403                 }
1404                 "-L" = {
1405                         value = "$snmpv3_seclevel$"
1406                         description = "SNMPv3 securityLevel"
1407                 }
1408                 "-a" = {
1409                         value = "$snmpv3_auth_alg$"
1410                         description = "SNMPv3 auth proto"
1411                 }
1412                 "-U" = {
1413                         value = "$snmpv3_user$"
1414                         description = "SNMPv3 username"
1415                 }
1416                 "-A" = {
1417                         value = "$snmpv3_auth_key$"
1418                         description = "SNMPv3 authentication password"
1419                 }
1420                 "-X" = {
1421                         value = "$snmpv3_priv_key$"
1422                         description = "SNMPv3 privacy password"
1423                 }
1424                 "-o" = {
1425                         value = "$snmpv3_oid$"
1426                         description = "Object identifier(s) or SNMP variables whose value you wish to query"
1427                 }
1428                 "-x" = {
1429                         value = "$snmpv3_priv_alg$"
1430                         description = "SNMPv3 priv proto (default DES)"
1431                 }
1432                 "-w" = {
1433                         value = "$snmpv3_warn$"
1434                         description = "Warning threshold range(s)"
1435                 }
1436                 "-c" = {
1437                         value = "$snmpv3_crit$"
1438                         description = "Critical threshold range(s)"
1439                 }
1440                 "-s" = {
1441                         value = "$snmpv3_string$"
1442                         description = "Return OK state (for that OID) if STRING is an exact match"
1443                 }
1444                 "-r" = {
1445                         value = "$snmpv3_ereg$"
1446                         description = "Return OK state (for that OID) if extended regular expression REGEX matches"
1447                 }
1448                 "-R" = {
1449                         value = "$snmpv3_eregi$"
1450                         description = "Return OK state (for that OID) if case-insensitive extended REGEX matches"
1451                 }
1452                 "--invert-search" = {
1453                         set_if = "$snmpv3_invert_search$"
1454                         description = "Invert search result and return CRITICAL if found"
1455                 }
1456                 "-l" = {
1457                         value = "$snmpv3_label$"
1458                         description = "Prefix label for output from plugin"
1459                 }
1460                 "-m" = {
1461                         value = "$snmpv3_miblist$"
1462                         description = "List of SNMP MIBs for translating OIDs between numeric and textual representation"
1463                 }
1464                 "-u" = "$snmpv3_units$"
1465                 "--rate-multiplier" = "$snmpv3_rate_multiplier$"
1466                 "--rate" = {
1467                         set_if = "$snmpv3_rate$"
1468                         description = "Enable rate calculation"
1469                 }
1470                 "-t" = "$snmpv3_timeout$"
1471         }
1472
1473         vars.snmpv3_address = "$check_address$"
1474         vars.snmpv3_auth_alg = "SHA"
1475         vars.snmpv3_priv_alg = "AES"
1476         vars.snmpv3_seclevel = "authPriv"
1477         vars.snmpv3_timeout = "10"
1478 }
1479
1480 object CheckCommand "snmp-uptime" {
1481         import "snmp"
1482
1483         vars.snmp_oid = "1.3.6.1.2.1.1.3.0"
1484 }
1485
1486 object CheckCommand "apt" {
1487         command = [ PluginDir + "/check_apt" ]
1488
1489         arguments = {
1490                 "--extra-opts" = {
1491                         value = "$apt_extra_opts$"
1492                         description = "Read options from an ini file."
1493                 }
1494                 "--upgrade" = {
1495                         value = "$apt_upgrade$"
1496                         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."
1497                 }
1498                 "--dist-upgrade" = {
1499                         value = "$apt_dist_upgrade$"
1500                         description = "Perform a dist-upgrade instead of normal upgrade. Like with -U OPTS can be provided to override the default options."
1501                 }
1502                 "--include" = {
1503                         value = "$apt_include$"
1504                         description = "Include only packages matching REGEXP. Can be specified multiple times the values will be combined together."
1505                 }
1506                 "--exclude" = {
1507                         value = "$apt_exclude$"
1508                         description = "Exclude packages matching REGEXP from the list of packages that would otherwise be included. Can be specified multiple times."
1509                 }
1510                 "--critical" = {
1511                         value = "$apt_critical$"
1512                         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."
1513                 }
1514                 "--timeout" = {
1515                         value = "$apt_timeout$"
1516                         description = "Seconds before plugin times out (default: 10)."
1517                 }
1518                 "--only-critical" = {
1519                         set_if = "$apt_only_critical$"
1520                         description = "Only warn about critical upgrades."
1521                 }
1522         }
1523
1524         timeout = 5m
1525 }
1526
1527 object CheckCommand "dhcp" {
1528         command = [ PluginDir + "/check_dhcp" ]
1529
1530         arguments = {
1531                 "-s" = "$dhcp_serverip$"
1532                 "-r" = "$dhcp_requestedip$"
1533                 "-t" = "$dhcp_timeout$"
1534                 "-i" = "$dhcp_interface$"
1535                 "-m" = "$dhcp_mac$"
1536                 "-u" = {
1537                         set_if = "$dhcp_unicast$"
1538                 }
1539         }
1540
1541         vars.dhcp_unicast = false
1542 }
1543
1544 object CheckCommand "dns" {
1545         import "ipv4-or-ipv6"
1546
1547         command = [ PluginDir + "/check_dns" ]
1548
1549         arguments = {
1550                 "-H" = {
1551                         value = "$dns_lookup$"
1552                         description = "The name or address you want to query."
1553                 }
1554                 "-s" = {
1555                         value = "$dns_server$"
1556                         description = "Optional DNS server you want to use for the lookup."
1557                 }
1558                 "-q" = {
1559                         value = "$dns_query_type$"
1560                         description = "Optional DNS record query type where TYPE =(A, AAAA, SRV, TXT, MX, ANY). The default query type is 'A' (IPv4 host entry)"
1561                 }
1562                 "-a" = {
1563                         value = "$dns_expected_answers$"
1564                         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)."
1565                 }
1566                 "-A" = {
1567                         set_if = "$dns_authoritative$"
1568                 }
1569                 "-w" = {
1570                         value = "$dns_wtime$"
1571                         description = "Return warning if elapsed time exceeds value."
1572                 }
1573                 "-c" = {
1574                         value = "$dns_ctime$"
1575                         description = "Return critical if elapsed time exceeds value."
1576                 }
1577                 "-t" = {
1578                         value = "$dns_timeout$"
1579                         description = "Seconds before connection times out. Defaults to 10."
1580                 }
1581         }
1582
1583         vars.dns_lookup = "$host.name$"
1584         vars.dns_query_type = "A"
1585         vars.dns_timeout = 10
1586 }
1587
1588 object CheckCommand "dig" {
1589         import "ipv4-or-ipv6"
1590
1591         command = [ PluginDir + "/check_dig" ]
1592
1593         arguments = {
1594                 "-H" = "$dig_server$"
1595                 "-p" = "$dig_port$"
1596                 "-l" = {
1597                         value = "$dig_lookup$"
1598                         required = true
1599                 }
1600                 "-T" = "$dig_record_type$"
1601                 "-a" = "$dig_expected_address$"
1602                 "-A" = "$dig_arguments$"
1603                 "-r" = "$dig_retries$"
1604                 "-w" = "$dig_warning$"
1605                 "-c" = "$dig_critical$"
1606                 "-t" = "$dig_timeout$"
1607                 "-4" = {
1608                         set_if = "$dig_ipv4$"
1609                         description = "Force dig to only use IPv4 query transport"
1610                 }
1611                 "-6" = {
1612                         set_if = "$dig_ipv6$"
1613                         description = "Force dig to only use IPv6 query transport"
1614                 }
1615         }
1616
1617         vars.dig_server = "$check_address$"
1618         vars.check_ipv4 = "$dig_ipv4$"
1619         vars.check_ipv6 = "$dig_ipv6$"
1620 }
1621
1622 object CheckCommand "nscp" {
1623         import "ipv4-or-ipv6"
1624
1625         command = [ PluginDir + "/check_nt" ]
1626
1627         arguments = {
1628                 "-H" = "$nscp_address$"
1629                 "-p" = "$nscp_port$"
1630                 "-s" = "$nscp_password$"
1631                 "-v" = {
1632                         value = "$nscp_variable$"
1633                         required = true
1634                 }
1635                 "-l" = {
1636                         value = "$nscp_params$"
1637                         repeat_key = false
1638                 }
1639                 "-w" = "$nscp_warn$"
1640                 "-c" = "$nscp_crit$"
1641                 "-t" = "$nscp_timeout$"
1642                 "-d" = {
1643                         value = "SHOWALL"
1644                         description = "Use with SERVICESTATE to see working services or PROCSTATE for running processes"
1645                         set_if = "$nscp_showall$"
1646                 }
1647         }
1648
1649         vars.nscp_address = "$check_address$"
1650         vars.nscp_port = 12489
1651         vars.nscp_showall = false
1652 }
1653
1654 object CheckCommand "by_ssh" {
1655         import "ipv4-or-ipv6"
1656
1657         command = [ PluginDir + "/check_by_ssh" ]
1658
1659         arguments = {
1660                 "-H" = "$by_ssh_address$"
1661                 "-p" = "$by_ssh_port$"
1662                 "-C" = {{
1663                         var command = macro("$by_ssh_command$")
1664                         var arguments = macro("$by_ssh_arguments$")
1665
1666                         if (typeof(command) == String && !arguments) {
1667                                 return command
1668                         }
1669
1670                         var escaped_args = []
1671                         for (arg in resolve_arguments(command, arguments)) {
1672                                 escaped_args.add(escape_shell_arg(arg))
1673                         }
1674                         return escaped_args.join(" ")
1675                 }}
1676                 "-l" = "$by_ssh_logname$"
1677                 "-i" = "$by_ssh_identity$"
1678                 "-q" = {
1679                         set_if = "$by_ssh_quiet$"
1680                 }
1681                 "-w" = "$by_ssh_warn$"
1682                 "-c" = "$by_ssh_crit$"
1683                 "-t" = "$by_ssh_timeout$"
1684                 "-o" = {
1685                         value = "$by_ssh_options$"
1686                         description = "Provide ssh options (may be repeated)"
1687                 }
1688                 "-4" = {
1689                         set_if = "$by_ssh_ipv4$"
1690                         description = "Use IPv4 only"
1691                 }
1692                 "-6" = {
1693                         set_if = "$by_ssh_ipv6$"
1694                         description = "Use IPv6 only"
1695                 }
1696         }
1697
1698         vars.by_ssh_address = "$check_address$"
1699         vars.by_ssh_quiet = false
1700         vars.check_ipv4 = "$by_ssh_ipv4$"
1701         vars.check_ipv6 = "$by_ssh_ipv6$"
1702 }
1703
1704 object CheckCommand "ups" {
1705         import "ipv4-or-ipv6"
1706
1707         command = [ PluginDir + "/check_ups" ]
1708
1709         arguments = {
1710                 "-H" = {
1711                         value = "$ups_address$"
1712                         description = "Address of the upsd server"
1713                         required = true
1714                 }
1715                 "-u" = {
1716                         value = "$ups_name$"
1717                         description = "Name of the UPS to monitor"
1718                         required = true
1719                 }
1720                 "-p" = {
1721                         value = "$ups_port$"
1722                         description = "Port number (default: 3493)"
1723                 }
1724                 "-v" = {
1725                         value = "$ups_variable$"
1726                         description = "Variable to monitor, valid strings are LINE, TEMP, BATTPCT or LOADPCT"
1727                 }
1728                 "-w" = {
1729                         value = "$ups_warning$"
1730                         description = "Warning threshold for the selected variable"
1731                 }
1732                 "-c" = {
1733                         value = "$ups_critical$"
1734                         description = "Critical threshold for the selected variable"
1735                 }
1736                 "-T" = {
1737                         set_if = "$ups_celsius$"
1738                         description = "Display temperature in degrees Celsius instead of Fahrenheit"
1739                 }
1740                 "-t" = {
1741                         value = "$ups_timeout$"
1742                         description = "Seconds before the connection times out (default: 10)"
1743                 }
1744         }
1745
1746         vars.ups_address = "$check_address$"
1747         vars.ups_name = "ups"
1748 }
1749
1750 object CheckCommand "nrpe" {
1751         import "ipv4-or-ipv6"
1752
1753         command = [ PluginDir + "/check_nrpe" ]
1754
1755         arguments = {
1756                 "-H" = "$nrpe_address$"
1757                 "-p" = "$nrpe_port$"
1758                 "-c" = "$nrpe_command$"
1759                 "-n" = {
1760                         set_if = "$nrpe_no_ssl$"
1761                         description = "Do not use SSL."
1762                 }
1763                 "-u" = {
1764                         set_if = "$nrpe_timeout_unknown$"
1765                         description = "Make socket timeouts return an UNKNOWN state instead of CRITICAL"
1766                 }
1767                 "-t" = "$nrpe_timeout$"
1768                 "-a" = {
1769                         value = "$nrpe_arguments$"
1770                         repeat_key = false
1771                         order = 1
1772                 }
1773                 "-4" = {
1774                         set_if = "$nrpe_ipv4$"
1775                         description = "Use IPv4 connection"
1776                 }
1777                 "-6" = {
1778                         set_if = "$nrpe_ipv6$"
1779                         description = "Use IPv6 connection"
1780                 }
1781                 "-2" = {
1782                         set_if = "$nrpe_version_2$"
1783                         description = "Use this if you want to connect to NRPE v2"
1784                 }
1785         }
1786
1787         vars.nrpe_address = "$check_address$"
1788         vars.nrpe_no_ssl = false
1789         vars.nrpe_timeout_unknown = false
1790         vars.check_ipv4 = "$nrpe_ipv4$"
1791         vars.check_ipv6 = "$nrpe_ipv6$"
1792         vars.nrpe_version_2 = false
1793         timeout = 5m
1794 }
1795
1796 object CheckCommand "hpjd" {
1797         import "ipv4-or-ipv6"
1798
1799         command = [ PluginDir + "/check_hpjd" ]
1800
1801         arguments = {
1802                 "-H" = "$hpjd_address$"
1803                 "-C" = "$hpjd_community$"
1804                 "-p" = "$hpjd_port$"
1805         }
1806
1807         vars.hpjd_address = "$check_address$"
1808 }
1809
1810 object CheckCommand "icmp" {
1811         command = [ PluginDir + "/check_icmp" ]
1812
1813         arguments = {
1814                 "-H" = {
1815                         value = "$icmp_address$"
1816                         repeat_key = false
1817                         order = 1
1818                 }
1819                 "-w" = "$icmp_wrta$,$icmp_wpl$%"
1820                 "-c" = "$icmp_crta$,$icmp_cpl$%"
1821                 "-s" = "$icmp_source$"
1822                 "-n" = "$icmp_packets$"
1823                 "-i" = "$icmp_packet_interval$"
1824                 "-I" = "$icmp_target_interval$"
1825                 "-m" = "$icmp_hosts_alive$"
1826                 "-b" = "$icmp_data_bytes$"
1827                 "-t" = "$icmp_timeout$"
1828                 "-l" = "$icmp_ttl$"
1829         }
1830
1831         vars.icmp_address = "$address$"
1832         vars.icmp_wrta = 100
1833         vars.icmp_wpl = 5
1834         vars.icmp_crta = 200
1835         vars.icmp_cpl = 15
1836 }
1837
1838 object CheckCommand "ldap" {
1839         import "ipv4-or-ipv6"
1840
1841         command = [ PluginDir + "/check_ldap" ]
1842
1843         arguments = {
1844                 "-H" = {
1845                         value = "$ldap_address$"
1846                         description = "Host name, IP Address, or unix socket (must be an absolute path)"
1847                 }
1848                 "-p" = {
1849                         value = "$ldap_port$"
1850                         description = "Port number (default: 389)"
1851                 }
1852                 "-a" = {
1853                         value = "$ldap_attr$"
1854                         description = "ldap attribute to search (default: \"(objectclass=*)\""
1855                 }
1856                 "-b" = {
1857                         value = "$ldap_base$"
1858                         required = true
1859                         description = "ldap base (eg. ou=my unit, o=my org, c=at"
1860                 }
1861                 "-D" = {
1862                         value = "$ldap_bind$"
1863                         description = "ldap bind DN (if required)"
1864                 }
1865                 "-P" = {
1866                         value = "$ldap_pass$"
1867                         description = "ldap password (if required)"
1868                 }
1869                 "-T" = {
1870                         set_if = "$ldap_starttls$"
1871                         description = "use starttls mechanism introduced in protocol version 3"
1872                 }
1873                 "-S" = {
1874                         set_if = "$ldap_ssl$"
1875                         description = "use ldaps (ldap v2 ssl method). this also sets the default port to 636"
1876                 }
1877                 "-2" = {
1878                         set_if = "$ldap_v2$"
1879                         description = "Use LDAP protocol version 2"
1880                 }
1881                 "-3" = {
1882                         set_if = "$ldap_v3$"
1883                         description = "Use LDAP protocol version 3"
1884                 }
1885                 "-w" = {
1886                         value = "$ldap_warning$"
1887                         description = "Response time to result in warning status (seconds)"
1888                 }
1889                 "-c" = {
1890                         value = "$ldap_critical$"
1891                         description = "Response time to result in critical status (seconds)"
1892                 }
1893                 "-W" = {
1894                         value = "$ldap_warning_entries$"
1895                         description = "Number of found entries to result in warning status (optional)"
1896                 }
1897                 "-C" = {
1898                         value = "$ldap_critical_entries$"
1899                         description = "Number of found entries to result in critical status (optional)"
1900                 }
1901                 "-t" = {
1902                         value = "$ldap_timeout$"
1903                         description = "Seconds before connection times out (default: 10)"
1904                 }
1905                 "-v" = {
1906                         set_if = "$ldap_verbose$"
1907                         description = "Show details for command-line debugging"
1908                 }
1909         }
1910
1911         vars.ldap_address = "$check_address$"
1912         vars.ldap_v2 = true
1913         vars.ldap_v3 = false
1914         vars.ldap_timeout = 10s
1915         vars.ldap_verbose = false
1916 }
1917
1918 object CheckCommand "clamd" {
1919         command = [ PluginDir + "/check_clamd" ]
1920
1921         arguments = {
1922                 "-H" = {
1923                         value = "$clamd_address$"
1924                         description = "The host's address or unix socket (must be an absolute path)."
1925                         required = true
1926                 }
1927                 "-p" = {
1928                         value = "$clamd_port$"
1929                         description = "Port number (default: none)."
1930                 }
1931                 "-e" = {
1932                         value = "$clamd_expect$"
1933                         description = "String to expect in server response (may be repeated)."
1934                         repeat_key = true
1935                 }
1936                 "-A" = {
1937                         set_if = "$clamd_all$"
1938                         description = "All expect strings need to occur in server response. Default is any."
1939                 }
1940                 "-E_send" = {
1941                         key = "-E"
1942                         order = 1
1943                         set_if = "$clamd_escape_send$"
1944                         description = "Enable usage of \n, \r, \t or \\ in send string. Default is nothing."
1945                 }
1946                 "-s" = {
1947                         order = 2
1948                         value = "$clamd_send$"
1949                         description = "String to send to the server."
1950                 }
1951                 "-E_quit" = {
1952                         key = "-E"
1953                         order = 3
1954                         set_if = "$clamd_escape_quit$"
1955                         description = "Can use \n, \r, \t or \\ in quit string. Default is \r\n added to end of quit."
1956                 }
1957                 "-q" = {
1958                         order = 4
1959                         value = "$clamd_quit$"
1960                         description = "String to send server to initiate a clean close of the connection."
1961                 }
1962                 "-r" = {
1963                         value = "$clamd_refuse$"
1964                         description = "Accept TCP refusals with states ok, warn, crit. Defaults to crit."
1965                 }
1966                 "-M" = {
1967                         value = "$clamd_mismatch$"
1968                         description = "Accept expected string mismatches with states ok, warn, crit. Defaults to warn."
1969                 }
1970                 "-j" = {
1971                         set_if = "$clamd_jail$"
1972                         description = "Hide output from TCP socket."
1973                 }
1974                 "-m" = {
1975                         value = "$clamd_maxbytes$"
1976                         description = "Close connection once more than this number of bytes are received."
1977                 }
1978                 "-d" = {
1979                         value = "$clamd_delay$"
1980                         description = "Seconds to wait between sending string and polling for response."
1981                 }
1982                 "-D" = {
1983                         value = "$clamd_certificate$"
1984                         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."
1985                 }
1986                 "-S" = {
1987                         set_if = "$clamd_ssl$"
1988                         description = "Use SSL for the connection."
1989                 }
1990                 "-w" = {
1991                         value = "$clamd_wtime$"
1992                         description = "Response time to result in warning status (seconds)."
1993                 }
1994                 "-c" = {
1995                         value = "$clamd_ctime$"
1996                         description = "Response time to result in critical status (seconds)."
1997                 }
1998                 "-t" = {
1999                         value = "$clamd_timeout$"
2000                         description = "Seconds before connection times out. Defaults to 10."
2001                 }
2002                 "-4" = {
2003                         set_if = "$clamd_ipv4$"
2004                         description = "Use IPv4 only"
2005                 }
2006                 "-6" = {
2007                         set_if = "$clamd_ipv6$"
2008                         description = "Use IPv6 only"
2009                 }
2010         }
2011
2012         vars.clamd_ssl = false
2013         vars.clamd_refuse = "crit"
2014         vars.clamd_mismatch = "warn"
2015         vars.clamd_timeout = 10
2016         vars.check_ipv4 = "$clamd_ipv4$"
2017         vars.check_ipv6 = "$clamd_ipv6$"
2018 }
2019
2020 object CheckCommand "mailq" {
2021         command = [ PluginDir + "/check_mailq" ]
2022
2023         arguments = {
2024                 "-w" = {
2025                         value = "$mailq_warning$"
2026                         description = "Min. number of messages in queue to generate warning"
2027                         required = true
2028                 }
2029                 "-c" = {
2030                         value = "$mailq_critical$"
2031                         description = "Min. number of messages in queue to generate critical alert ( w < c )"
2032                         required = true
2033                 }
2034                 "-W" = {
2035                         value = "$mailq_domain_warning$"
2036                         description = "Min. number of messages for same domain in queue to generate warning"
2037                 }
2038                 "-C" = {
2039                         value = "$mailq_domain_critical$"
2040                         description = "Min. number of messages for same domain in queue to generate critical alert ( W < C )"
2041                 }
2042                 "-t" = {
2043                         value = "$mailq_timeout$"
2044                         description = "Plugin timeout in seconds (default = 15)"
2045                 }
2046                 "-M" = {
2047                         value = "$mailq_servertype$"
2048                         description = "[ sendmail | qmail | postfix | exim | nullmailer ] (default = autodetect)"
2049                 }
2050                 "-s" = {
2051                         set_if = "$mailq_sudo$"
2052                         description = "Use sudo for mailq command"
2053                 }
2054         }
2055 }
2056
2057 object CheckCommand "pgsql" {
2058         import "ipv4-or-ipv6"
2059
2060         command = [ PluginDir + "/check_pgsql" ]
2061
2062         arguments = {
2063                 "-H" = "$pgsql_hostname$"
2064                 "-P" = "$pgsql_port$"
2065                 "-d" = "$pgsql_database$"
2066                 "-l" = "$pgsql_username$"
2067                 "-p" = "$pgsql_password$"
2068                 "-o" = "$pgsql_options$"
2069                 "-w" = "$pgsql_warning$"
2070                 "-c" = "$pgsql_critical$"
2071                 "-t" = "$pgsql_timeout$"
2072                 "-q" = "$pgsql_query$"
2073                 "-W" = "$pgsql_query_warning$"
2074                 "-C" = "$pgsql_query_critical$"
2075         }
2076
2077         vars.pgsql_hostname = "$check_address$"
2078 }
2079
2080 object CheckCommand "mysql" {
2081         import "ipv4-or-ipv6"
2082
2083         command = [ PluginDir + "/check_mysql" ]
2084
2085         arguments = {
2086                 "-H" = "$mysql_hostname$"
2087                 "-P" = "$mysql_port$"
2088                 "-n" = {
2089                         set_if = "$mysql_ignore_auth$"
2090                 }
2091                 "-s" = "$mysql_socket$"
2092                 "-d" = "$mysql_database$"
2093                 "-f" = "$mysql_file$"
2094                 "-g" = "$mysql_group$"
2095                 "-u" = "$mysql_username$"
2096                 "-p" = "$mysql_password$"
2097                 "-S" = {
2098                         set_if = "$mysql_check_slave$"
2099                 }
2100                 "-w" = "$mysql_warning$"
2101                 "-c" = "$mysql_critical$"
2102                 "-l" = {
2103                         set_if = "$mysql_ssl$"
2104                 }
2105                 "-C" = "$mysql_cacert$"
2106                 "-a" = "$mysql_cert$"
2107                 "-k" = "$mysql_key$"
2108                 "-D" = "$mysql_cadir$"
2109                 "-L" = "$mysql_ciphers$"
2110         }
2111
2112         vars.mysql_hostname = "$check_address$"
2113 }
2114
2115 object CheckCommand "negate" {
2116         command = [ PluginDir + "/negate" ]
2117
2118         arguments = {
2119                 "-t" = "$negate_timeout$"
2120                 "-T" = "$negate_timeout_result$"
2121                 "-o" = "$negate_ok$"
2122                 "-w" = "$negate_warning$"
2123                 "-c" = "$negate_critical$"
2124                 "-s" = {
2125                         set_if = "$negate_substitute$"
2126                 }
2127                 "--wrapped-plugin" = {
2128                         value = {{
2129                                 var command = macro("$negate_command$")
2130                                 var arguments = macro("$negate_arguments$")
2131
2132                                 if (typeof(command) == String && !arguments) {
2133                                         return command
2134                                 }
2135
2136                                 var escaped_args = []
2137                                 for (arg in resolve_arguments(command, arguments)) {
2138                                         escaped_args.add(arg)
2139                                 }
2140                                 return escaped_args.join(" ")
2141                         }}
2142                         skip_key = true
2143                         order = 1
2144                 }
2145         }
2146
2147         vars.negate_timeout_result = "UNKNOWN"
2148 }
2149
2150 object CheckCommand "file_age" {
2151         command = [ PluginDir + "/check_file_age" ]
2152
2153         arguments = {
2154                 "-w" = {
2155                         value = "$file_age_warning_time$"
2156                         description = "File must be no more than this many seconds old (default: 240s)"
2157                 }
2158                 "-c" = {
2159                         value = "$file_age_critical_time$"
2160                         description = "File must be no more than this many seconds old (default: 600s)"
2161                 }
2162                 "-W" = {
2163                         value = "$file_age_warning_size$"
2164                         description = "File must be at least this many bytes long"
2165                 }
2166                 "-C" = {
2167                         value = "$file_age_critical_size$"
2168                         description = "File must be at least this many bytes long (default: 0B)"
2169                 }
2170                 "-i" = {
2171                         set_if = "$file_age_ignoremissing$"
2172                         description = "return OK if the file does not exist"
2173                 }
2174                 "-f" = {
2175                         value = "$file_age_file$"
2176                         description = "File to monitor"
2177                 }
2178         }
2179
2180         vars.file_age_ignoremissing = false
2181 }
2182
2183 object CheckCommand "smart" {
2184         command = [ PluginDir + "/check_ide_smart" ]
2185
2186         arguments = {
2187                 "-d" = {
2188                         value = "$smart_device$"
2189                         description = "Name of a local hard drive to monitor"
2190                         required = true
2191                 }
2192         }
2193 }
2194
2195 object CheckCommand "breeze" {
2196         import "ipv4-or-ipv6"
2197
2198         command = [ PluginDir + "/check_breeze" ]
2199
2200         arguments = {
2201                 "-H" = {
2202                         value = "$breeze_hostname$"
2203                         description = "Name or IP address of host to check"
2204                         required = true
2205                 }
2206                 "-C" = {
2207                         value = "$breeze_community$"
2208                         description = "SNMPv1 community (default public)"
2209                 }
2210                 "-w" = {
2211                         value = "$breeze_warning$"
2212                         description = "Percentage strength below which a WARNING status will result"
2213                         required = true
2214                 }
2215                 "-c" = {
2216                         value = "$breeze_critical$"
2217                         description = "Percentage strength below which a CRITICAL status will result"
2218                         required = true
2219                 }
2220         }
2221
2222         vars.breeze_hostname = "$check_address$"
2223         vars.breeze_warning = "50"
2224         vars.breeze_critical = "20"
2225 }
2226
2227 object CheckCommand "flexlm" {
2228         command = [ PluginDir + "/check_flexlm" ]
2229
2230         arguments = {
2231                 "-F" = {
2232                         value = "$flexlm_licensefile$"
2233                         description = "Name of license file (usually license.dat)"
2234                         required = true
2235                 }
2236                 "-t" = {
2237                         value = "$flexlm_timeout$"
2238                         description = "Plugin time out in seconds (default = 15)"
2239                 }
2240         }
2241 }
2242
2243 object CheckCommand "game" {
2244         import "ipv4-or-ipv6"
2245
2246         command = [ PluginDir + "/check_game" ]
2247
2248         arguments = {
2249                 "-P" = {
2250                         value = "$game_port$"
2251                         description = "Port to connect to"
2252                 }
2253                 "-t" = {
2254                         value = "$game_timeout$"
2255                         description = "Seconds before connection times out (default: 10)"
2256                 }
2257                 "-g" = {
2258                         value = "$game_gamefield$"
2259                         description = "Field number in raw qstat output that contains game name"
2260                 }
2261                 "-m" = {
2262                         value = "$game_mapfield$"
2263                         description = "Field number in raw qstat output that contains map name"
2264                 }
2265                 "-p" = {
2266                         value = "$game_pingfield$"
2267                         description = "Field number in raw qstat output that contains ping time"
2268                 }
2269                 "-G" = {
2270                         value = "$game_gametime$"
2271                         description = "Field number in raw qstat output that contains game time"
2272                 }
2273                 "-H" = {
2274                         value = "$game_hostname$"
2275                         description = "Name of the host running the game"
2276                 }
2277                 "game" = {
2278                         value = "$game_game$"
2279                         description = "Name of the game"
2280                         order = 1
2281                         skip_key = true
2282                 }
2283                 "ipaddress" = {
2284                         value = "$game_ipaddress$"
2285                         description = "Ipaddress of the game server to query"
2286                         order = 2
2287                         skip_key = true
2288                 }
2289         }
2290 }
2291
2292 object CheckCommand "mysql_query" {
2293         import "ipv4-or-ipv6"
2294
2295         command = [ PluginDir + "/check_mysql_query" ]
2296
2297         arguments = {
2298                 "-H" = "$mysql_query_hostname$"
2299                 "-P" = "$mysql_query_port$"
2300                 "-u" = "$mysql_query_username$"
2301                 "-p" = "$mysql_query_password$"
2302                 "-d" = "$mysql_query_database$"
2303                 "-f" = "$mysql_query_file$"
2304                 "-g" = "$mysql_query_group$"
2305                 "-q" = "$mysql_query_execute$"
2306                 "-w" = "$mysql_query_warning$"
2307                 "-c" = "$mysql_query_critical$"
2308         }
2309
2310         vars.mysql_query_hostname = "$check_address$"
2311 }
2312
2313 object CheckCommand "radius" {
2314         import "ipv4-or-ipv6"
2315
2316         command = [
2317                 PluginDir + "/check_radius",
2318         ]
2319
2320         arguments = {
2321                 "-H" = "$radius_address$",
2322                 "-F" = "$radius_config_file$",
2323                 "-u" = "$radius_username$",
2324                 "-p" = "$radius_password$",
2325                 "-P" = {
2326                         value = "$radius_port$",
2327                 },
2328                 "-n" = {
2329                         value = "$radius_nas_id$",
2330                         description = "NAS identifier"
2331                 }
2332                 "-N" = {
2333                         value = "$radius_nas_address$",
2334                         description = "NAS IP Address"
2335                 },
2336                 "-e" = {
2337                         value = "$radius_expect$",
2338                         description = "Response string to expect from the server"
2339                 },
2340                 "-r" = {
2341                         value = "$radius_retries$",
2342                         description = "Number of times to retry a failed connection"
2343                 },
2344                 "-t" = {
2345                         value = "$radius_timeout$",
2346                         description = "Seconds before connection times out (default: 10) Optional :<timeout state> can be a state integer (0,1,2,3) or a state STRING"
2347                 },
2348         }
2349
2350         vars.radius_address = "$check_address$"
2351 }