From: Thomas Niedermeier Date: Tue, 21 Feb 2017 12:33:54 +0000 (+0100) Subject: ITL: Add SMART attributes monitoring plugin check configuration X-Git-Tag: v2.7.0~218^2~5 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=06fa96f83de6f3818e3127234610f42fd4862925;p=icinga2 ITL: Add SMART attributes monitoring plugin check configuration refs #5019 Signed-off-by: Michael Friedrich --- diff --git a/doc/10-icinga-template-library.md b/doc/10-icinga-template-library.md index 83dc89421..d2e278cf0 100644 --- a/doc/10-icinga-template-library.md +++ b/doc/10-icinga-template-library.md @@ -2227,6 +2227,15 @@ hpasm_privprotocol | **Optional.** The private protocol for SNMPv3 (des\|aes\|a hpasm_servertype | **Optional.** The type of the server: proliant (default) or bladesystem. hpasm_eval-nics | **Optional.** Check network interfaces (and groups). Try it and report me whyt you think about it. I need to build up some know how on this subject. If you get an error and think, it is not justified for your configuration, please tell me about it. (alwasy send the output of "snmpwalk -On .... 1.3.6.1.4.1.232" and a description how you setup your nics and why it is correct opposed to the plugins error message. +#### smart-attributes + +The plugin [check_smart_attributes](https://github.com/thomas-krenn/check_smart_attributes) is a plugin to monitor the SMART values of SSDs and HDDs. + +Name | Description +--------------------------------|----------------------------------------------------------------------- +smart_attributes_config_path | **Required.** Path to the smart attributes config file (e.g. check_smartdb.json). +smart_attributes_device | **Required.** Insert the device name (e.g. /dev/sda) to monitor. + ### IcingaCLI diff --git a/itl/plugins-contrib.d/smart-attributes.conf b/itl/plugins-contrib.d/smart-attributes.conf new file mode 100644 index 000000000..25e3333dd --- /dev/null +++ b/itl/plugins-contrib.d/smart-attributes.conf @@ -0,0 +1,24 @@ +/* + * Icinga2 CheckCommand definition for the SMART Attributes Monitoring Plugin + */ + +object CheckCommand "smart-attributes" { + import "plugin-check-command" + + command = [ PluginDir + "/check_smart_attributes" ] + + arguments = { + "-dbj" = { + required = true + value = "$smart_attributes_config_path$" + description = "Path to the smart attributes config file (e.g. check_smartdb.json)" + } + "-d" = { + required = true + value = "$smart_attributes_device$" + description = "Insert the device name (e.g. /dev/sda) to monitor" + } + } + + vars.smart_attributes_config_path = SysconfDir + "/icinga2/plugins-config/check_smartdb.json" +}