Module: check_mk
Branch: master
Commit: d1797f0e2f526c3d6c0802bfb08efacd22bedb21
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=d1797f0e2f526c…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Sat Feb 21 09:27:22 2015 +0100
#2031 FIX brocade_mlx_temp: make configurable via new WATO rule, add Perf-O-Meter, add
default levels
This check has been converted to be consistent with all other temperature checks. Please
redo
the service discovery.
---
.werks/2031 | 10 ++++++++++
ChangeLog | 2 ++
checks/brocade_mlx_temp | 25 ++++++++++++++-----------
3 files changed, 26 insertions(+), 11 deletions(-)
diff --git a/.werks/2031 b/.werks/2031
new file mode 100644
index 0000000..f34d729
--- /dev/null
+++ b/.werks/2031
@@ -0,0 +1,10 @@
+Title: brocade_mlx_temp: make configurable via new WATO rule, add Perf-O-Meter, add
default levels
+Level: 1
+Component: checks
+Compatible: incomp
+Version: 1.2.7i1
+Date: 1424507184
+Class: fix
+
+This check has been converted to be consistent with all other temperature checks. Please
redo
+the service discovery.
diff --git a/ChangeLog b/ChangeLog
index 286b2e4..5ee6e7d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -177,6 +177,8 @@
* 2028 FIX: hyperv_vms: new plugin that allows spaces in VM names...
* 2030 FIX: netapp_api_temp: add Perf-O-Meter, make configurable via WATO...
NOTE: Please refer to the migration notes!
+ * 2031 FIX: brocade_mlx_temp: make configurable via new WATO rule, add Perf-O-Meter,
add default levels...
+ NOTE: Please refer to the migration notes!
Multisite:
* 1758 Improved exception hander: Shows details without additional debug request,
added mailto link for error report...
diff --git a/checks/brocade_mlx_temp b/checks/brocade_mlx_temp
index f6792e5..32d6fb8 100644
--- a/checks/brocade_mlx_temp
+++ b/checks/brocade_mlx_temp
@@ -24,8 +24,9 @@
# to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
# Boston, MA 02110-1301 USA.
-brocade_mlx_temperature_default_levels = (105, 110)
-
+factory_settings["brocade_mlx_temperature_default_levels"] = {
+ "levels" : (105, 110)
+}
def parse_brocade_mlx_temp(info):
parsed = {}
@@ -42,7 +43,7 @@ def parse_brocade_mlx_temp(info):
def inventory_brocade_mlx_temp(parsed):
for item in parsed:
- yield item, "brocade_mlx_temperature_default_levels"
+ yield item, {}
def check_brocade_mlx_temp(item, params, parsed):
@@ -51,12 +52,14 @@ def check_brocade_mlx_temp(item, params, parsed):
check_info["brocade_mlx_temp"] = {
- "parse_function" : parse_brocade_mlx_temp,
- "check_function" : check_brocade_mlx_temp,
- "inventory_function" : inventory_brocade_mlx_temp,
- "service_description" : "Temperature %s",
- "snmp_info" : ('.1.3.6.1.4.1.1991.1.1.2.13.1.1', [ 3, 4
]), # descr, temperature
- "snmp_scan_function" : lambda oid:
oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.1991.1."),
- "has_perfdata" : True,
- "group" : "hw_temperature",
+ "parse_function" : parse_brocade_mlx_temp,
+ "check_function" : check_brocade_mlx_temp,
+ "inventory_function" : inventory_brocade_mlx_temp,
+ "service_description" : "Temperature %s",
+ "snmp_info" : ('.1.3.6.1.4.1.1991.1.1.2.13.1.1', [ 3,
4 ]), # descr, temperature
+ "snmp_scan_function" : lambda oid:
oid(".1.3.6.1.2.1.1.2.0").startswith(".1.3.6.1.4.1.1991.1."),
+ "has_perfdata" : True,
+ "default_levels_variable" :
"brocade_mlx_temperature_default_levels",
+ "group" : "temperature",
+ "includes" : [ "temperature.include" ],
}