Module: check_mk
Branch: master
Commit: 4513d494030ef11185bf0f845b33b0d46baea8c5
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=4513d494030ef1…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Fri Oct 31 14:40:42 2014 +0100
Small fixes for climaventa checks
---
checkman/climaveneta_fan | 12 ++++++------
checkman/climaveneta_temp | 6 +++---
checks/climaveneta_fan | 17 ++++++++++-------
modules/catalog.py | 1 +
4 files changed, 20 insertions(+), 16 deletions(-)
diff --git a/checkman/climaveneta_fan b/checkman/climaveneta_fan
index 2c2011f..31978da 100644
--- a/checkman/climaveneta_fan
+++ b/checkman/climaveneta_fan
@@ -1,19 +1,19 @@
-title: Climaveneta Fan
+title: Climaveneta: Fans
agents: snmp
catalog: hw/environment/climaveneta
license: GPL
-distribution:
+distribution: check_mk
description:
- This check monitors the Fan speeds on Climaveneta mc01_o4cv devices.
+ This check monitors the fan speeds on Climaveneta mc01_o4cv devices.
item:
- The id of the Fan (1 or 2)
+ The id of the fan (1 or 2)
perfdata:
- the current Fan speed in rpm
+ the current fan speed in RPM
inventory:
- one service for each Fan
+ For each fan one service is created
[parameters]
lower_warning (int): Warning if speed is beneath
diff --git a/checkman/climaveneta_temp b/checkman/climaveneta_temp
index 2f71548..36bcef7 100644
--- a/checkman/climaveneta_temp
+++ b/checkman/climaveneta_temp
@@ -1,11 +1,11 @@
-title: Climaveneta Temperature
+title: Climaveneta: Temperature sensors
agents: snmp
catalog: hw/environment/climaveneta
license: GPL
-distribution:
+distribution: check_mk
description:
This check monitors the temperature of sensors attached
- to climaveneta mc01_o4cv device.
+ to Climaveneta mc01_o4cv device.
item:
The item is the sensor description of the sensor as string.
diff --git a/checks/climaveneta_fan b/checks/climaveneta_fan
index d3fac3e..63d6672 100644
--- a/checks/climaveneta_fan
+++ b/checks/climaveneta_fan
@@ -24,28 +24,31 @@
# to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
# Boston, MA 02110-1301 USA.
+
factory_settings["climaveneta_fan_default_levels"] = {
"lower" : ( 200, 100 ),
"upper" : ( 700, 800 ),
}
+
def inventory_climaveneta_fan(info):
if len(info[0]) == 2:
return [ (1, {}), (2, {}) ]
+
def check_climaveneta_fan(item, params, info):
- item = item-1
- rpm = int(info[0][item])
+ rpm = int(info[0][item - 1])
l_warn, l_crit = params['lower']
u_warn, u_crit = params['upper']
perfdata = [("rpm", rpm )]
- message = "Speed at %d rpm" % rpm
+ message = "Speed at %d RPM" % rpm
if rpm <= l_crit or rpm >= u_crit:
return 2, message, perfdata
- if rpm <= l_warn or rpm >= u_warn:
- return 1, messagae, perfdata
- return 0, message, perfdata
-
+ elif rpm <= l_warn or rpm >= u_warn:
+ return 1, message, perfdata
+ else:
+ return 0, message, perfdata
+
check_info["climaveneta_fan"] = {
"check_function" : check_climaveneta_fan,
diff --git a/modules/catalog.py b/modules/catalog.py
index 4efae9f..c62e5d7 100644
--- a/modules/catalog.py
+++ b/modules/catalog.py
@@ -40,6 +40,7 @@ manpage_catalog_titles = {
"stulz" : "STULZ",
"wut" : "Wiesemann & Theis",
"wagner" : "WAGNER Group",
+ "climaventa" : "Climaventa",
"other" : "Other devices",
"network" : "Networking (Switches, Routers, etc.)",
"alcatel" : "Alcatel",