]> granicus.if.org Git - icinga2/commitdiff
Add a check command for check_breeze
authorDirk Goetz <dirk.goetz@netways.de>
Thu, 19 Nov 2015 11:26:06 +0000 (12:26 +0100)
committerMichael Friedrich <michael.friedrich@netways.de>
Wed, 3 Aug 2016 09:32:41 +0000 (11:32 +0200)
Add a check command for check_flexlm
Add a check command for check_game

refs #6225

doc/7-icinga-template-library.md
itl/command-plugins.conf

index 1434c65fac89cc78144afc6000fccd06fdeee017..bad493ba40c89ec62674a76e2da51aa2d206fca9 100644 (file)
@@ -112,6 +112,20 @@ apt_critical            | **Optional.** If the full package information of any o
 apt_timeout             | **Optional.** Seconds before plugin times out (default: 10).
 
 
+### <a id="plugin-check-command-breeze"></a> breeze
+
+Check command object for the `check_breeze` plugin.
+
+Custom attributes passed as [command parameters](3-monitoring-basics.md#command-passing-parameters):
+
+Name             | Description
+-----------------|---------------------------------
+breeze_hostname  | **Required.** Name or IP address of host to check. Defaults to "$address$" if the host's `address` attribute is set, "$address6$" otherwise.
+breeze_community | **Optional.** SNMPv1 community. Defaults to "public".
+breeze_warning   | **Required.** Percentage strength below which a WARNING status will result. Defaults to 50.
+breeze_critical  | **Required.** Percentage strength below which a WARNING status will result. Defaults to 20.
+
+
 ### <a id="plugin-check-command-by-ssh"></a> by_ssh
 
 Check command object for the `check_by_ssh` plugin.
@@ -311,6 +325,18 @@ file_age_critical_size | **Optional.** File must be at least this many bytes lon
 file_age_ignoremissing | **Optional.** Return OK if the file does not exist. Defaults to false.
 
 
+### <a id="plugin-check-command-flexlm"></a> flexlm
+
+Check command object for the `check_flexlm` plugin. Requires the command `lmstat` installed.
+
+Custom attributes passed as [command parameters](3-monitoring-basics.md#command-passing-parameters):
+
+Name               | Description
+-------------------|----------------------------------------------------------
+flexlm_licensefile | **Required.** Name of license file (usually license.dat).
+flexlm_timeout     | **Optional.** Plugin time out in seconds. Defaults to 15.
+
+
 ### <a id="plugin-check-command-fping4"></a> fping4
 
 Check command object for the `check_fping` plugin.
@@ -383,6 +409,25 @@ ftp_ipv4           | **Optional.** Use IPv4 connection. Defaults to false.
 ftp_ipv6           | **Optional.** Use IPv6 connection. Defaults to false.
 
 
+### <a id="plugin-check-command-game"></a> game
+
+Check command object for the `check_game` plugin. Requires the command `qstat` (if installed from packages typically named `quakestat`) which also allows to provide some default configuration.
+
+Custom attributes passed as [command parameters](3-monitoring-basics.md#command-passing-parameters):
+
+Name               | Description
+-------------------|--------------
+game_game | **Required.** Name of the game.
+game_ipaddress | **Required.** Ipaddress of the game server to query.
+game_timeout | **Optional.** Seconds before connection times out. Defaults to 10.
+game_port | **Optional.** Port to connect to.
+game_gamefield | **Optional.** Field number in raw qstat output that contains game name.
+game_mapfield  | **Optional.** Field number in raw qstat output that contains map name.
+game_pingfield | **Optional.** Field number in raw qstat output that contains ping time.
+game_gametime  | **Optional.** Field number in raw qstat output that contains game time.
+game_hostname  | **Optional.** Name of the host running the game.
+
+
 ### <a id="plugin-check-command-hostalive"></a> hostalive
 
 Check command object for the `check_ping` plugin with host check default values. This variant
index cae729c03e0a33d71d1011d3f388ddc05edce0c8..9d703ae6985f209976ca06355fa65753bf617120 100644 (file)
@@ -2153,3 +2153,104 @@ object CheckCommand "smart" {
                }
        }
 }
+
+object CheckCommand "breeze" {
+       import "plugin-check-command"
+       import "ipv4-or-ipv6"
+
+       command = [ PluginDir + "/check_breeze" ]
+
+       arguments = {
+               "-H" = {
+                       value = "$breeze_hostname$"
+                       description = "Name or IP address of host to check"
+                       required = true
+               }
+               "-C" = {
+                       value = "$breeze_community$"
+                       description = "SNMPv1 community (default public)"
+               }
+               "-w" = {
+                       value = "$breeze_warning$"
+                       description = "Percentage strength below which a WARNING status will result"
+                       required = true
+               }
+               "-c" = {
+                       value = "$breeze_critical$"
+                       description = "Percentage strength below which a CRITICAL status will result"
+                       required = true
+               }
+       }
+
+       vars.breeze_hostname = "$check_address$"
+       vars.breeze_warning = "50"
+       vars.breeze_critical = "20"
+}
+
+object CheckCommand "flexlm" {
+       import "plugin-check-command"
+
+       command = [ PluginDir + "/check_flexlm" ]
+
+       arguments = {
+               "-F" = {
+                       value = "$flexlm_licensefile$"
+                       description = "Name of license file (usually license.dat)"
+                       required = true
+               }
+               "-t" = {
+                       value = "$flexlm_timeout$"
+                       description = "Plugin time out in seconds (default = 15)"
+               }
+       }
+}
+
+object CheckCommand "game" {
+       import "plugin-check-command"
+       import "ipv4-or-ipv6"
+
+       command = [ PluginDir + "/check_game" ]
+
+       arguments = {
+               "-P" = {
+                       value = "$game_port$"
+                       description = "Port to connect to"
+               }
+               "-t" = {
+                       value = "$game_timeout$"
+                       description = "Seconds before connection times out (default: 10)"
+               }
+               "-g" = {
+                       value = "$game_gamefield$"
+                       description = "Field number in raw qstat output that contains game name"
+               }
+               "-m" = {
+                       value = "$game_mapfield$"
+                       description = "Field number in raw qstat output that contains map name"
+               }
+               "-p" = {
+                       value = "$game_pingfield$"
+                       description = "Field number in raw qstat output that contains ping time"
+               }
+               "-G" = {
+                       value = "$game_gametime$"
+                       description = "Field number in raw qstat output that contains game time"
+               }
+               "-H" = {
+                       value = "$game_hostname$"
+                       description = "Name of the host running the game"
+               }
+               "game" = {
+                       value = "$game_game$"
+                       description = "Name of the game"
+                       order = 1
+                       skip_key = true
+               }
+               "ipaddress" = {
+                       value = "$game_ipaddress$"
+                       description = "Ipaddress of the game server to query"
+                       order = 2
+                       skip_key = true
+               }
+       }
+}