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