Module: check_mk
Branch: master
Commit: 5b05cde3da2adc8a2bd4b76ad5967bce976ab913
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5b05cde3da2adc…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Sep 2 11:16:32 2015 +0200
#2573 FIX Fix influance of service period to the availability of BI aggregates
When computing the availability the influence of the service period of BI
aggregates was simply ignored. This has been fixed.
---
.werks/2573 | 11 +++++++++++
ChangeLog | 1 +
web/htdocs/availability.py | 2 +-
3 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/.werks/2573 b/.werks/2573
new file mode 100644
index 0000000..67ba247
--- /dev/null
+++ b/.werks/2573
@@ -0,0 +1,11 @@
+Title: Fix influance of service period to the availability of BI aggregates
+Level: 2
+Component: bi
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.2.7i3
+Date: 1441185337
+
+When computing the availability the influence of the service period of BI
+aggregates was simply ignored. This has been fixed.
diff --git a/ChangeLog b/ChangeLog
index 8c896b2..e8281ea 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -224,6 +224,7 @@
* 2369 FIX: Fix exception in BI availability via table "Hostname Aggregations"
* 2370 FIX: Fix computation of "in downtime" and "acknownledged" of hosts in BI aggregations...
* 2485 FIX: Fix Icon "BI Aggregations containing this service", also avoid BI compilation without need...
+ * 2573 FIX: Fix influance of service period to the availability of BI aggregates...
Event Console:
* 2411 Check check_mkevents: Now able to look for events matching the host alias...
diff --git a/web/htdocs/availability.py b/web/htdocs/availability.py
index ff7b149..28f8e01 100644
--- a/web/htdocs/availability.py
+++ b/web/htdocs/availability.py
@@ -1355,7 +1355,7 @@ def get_bi_spans(tree, aggr_group, avoptions, timewarp):
"host_name" : aggr_group,
"service_description" : tree['title'],
"in_notification_period" : 1,
- "in_service_period" : True,
+ "in_service_period" : tree_state[0]['in_service_period'],
"in_downtime" : tree_state[0]['in_downtime'],
"in_host_downtime" : 0,
"host_down" : 0,
Module: check_mk
Branch: master
Commit: 453d4e2dd7d59bc178a1cd34aae61708e7d4ce89
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=453d4e2dd7d59b…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Sep 2 10:54:43 2015 +0200
#2542 FIX Fix segmentation fault when filtering for service columns in log table
The crash occurred when you filtered for a text type service column in the
log table while entries did not have service information (host alerts).
---
.werks/2542 | 10 ++++++++++
ChangeLog | 1 +
livestatus/src/StringColumnFilter.cc | 3 +++
3 files changed, 14 insertions(+)
diff --git a/.werks/2542 b/.werks/2542
new file mode 100644
index 0000000..75670d3
--- /dev/null
+++ b/.werks/2542
@@ -0,0 +1,10 @@
+Title: Fix segmentation fault when filtering for service columns in log table
+Level: 2
+Component: livestatus
+Compatible: compat
+Version: 1.2.7i3
+Date: 1441184018
+Class: fix
+
+The crash occurred when you filtered for a text type service column in the
+log table while entries did not have service information (host alerts).
diff --git a/ChangeLog b/ChangeLog
index 990ff03..8c896b2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -235,6 +235,7 @@
Livestatus:
* 2493 FIX: Fixed wrong JSON format when using stats queries together with header columns...
+ * 2542 FIX: Fix segmentation fault when filtering for service columns in log table...
HW/SW-Inventory:
* 2128 mk_inventory.vbs: inventory plugin for Windows now available as vbs script...
diff --git a/livestatus/src/StringColumnFilter.cc b/livestatus/src/StringColumnFilter.cc
index 6a3923e..4dde056 100644
--- a/livestatus/src/StringColumnFilter.cc
+++ b/livestatus/src/StringColumnFilter.cc
@@ -68,6 +68,9 @@ bool StringColumnFilter::accepts(void *data)
{
bool pass = true;
char *act_string = _column->getValue(data);
+ if (!act_string)
+ act_string = ""; // e.g. current_service_perf_data in host entry in log table
+
switch (_opid) {
case OP_EQUAL:
pass = _ref_string == act_string; break;
Module: check_mk
Branch: master
Commit: c07cb1afebb9f21c07d87115314aba0dd2fb7b4b
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=c07cb1afebb9f2…
Author: Simon Betz <si(a)mathias-kettner.de>
Date: Wed Sep 2 07:53:26 2015 +0200
adapted man page
---
checkman/cisco_srst_state | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/checkman/cisco_srst_state b/checkman/cisco_srst_state
index b6dbe7d..1d43842 100644
--- a/checkman/cisco_srst_state
+++ b/checkman/cisco_srst_state
@@ -6,7 +6,7 @@ distribution: check_mk
description:
This check monitors the status of the Cisco Unified SRST feature
of a Cisco device which supports that feature.
- There are two possible states: active (WARN) or inactive (OK).
+ There are two possible states: active (CRIT) or inactive (OK).
Moreover the check displays the time (in minutes) since the SRST feature
switched to active mode.
New checks for the Omnitronics IPR400
Message-ID: <55e5a190.JK5K+K84sntFtwSZ%sh(a)mathias-kettner.de>
User-Agent: Heirloom mailx 12.5 6/20/10
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Module: check_mk
Branch: master
Commit: ba087dc9ed3527785f75898fcfead131720f3945
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=ba087dc9ed3527…
Author: Sebastian Herbord <sh(a)mathias-kettner.de>
Date: Tue Sep 1 15:00:50 2015 +0200
#2563 ipr400_temp, ipr400_in_voltage: New checks for the Omnitronics IPR400
---
.werks/2563 | 9 +++++++
ChangeLog | 1 +
checkman/ipr400_in_voltage | 10 ++++++++
checkman/ipr400_temp | 10 ++++++++
checks/ipr400_in_voltage | 58 ++++++++++++++++++++++++++++++++++++++++++++
checks/ipr400_temp | 45 ++++++++++++++++++++++++++++++++++
6 files changed, 133 insertions(+)
diff --git a/.werks/2563 b/.werks/2563
new file mode 100644
index 0000000..6e51780
--- /dev/null
+++ b/.werks/2563
@@ -0,0 +1,9 @@
+Title: ipr400_temp, ipr400_in_voltage: New checks for the Omnitronics IPR400
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.2.7i3
+Date: 1441112436
+Class: feature
+
+
diff --git a/ChangeLog b/ChangeLog
index 55a4275..990ff03 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -69,6 +69,7 @@
* 2424 esx_vsphere_counters: improved handling when data is missing...
* 1288 cisco_vpn_tunnel: Added Metrics for trafic, please beware:...
* 2425 agent_hp_msa: New special agent to monitor "HP MSA Storage" devices...
+ * 2563 ipr400_temp, ipr400_in_voltage: New checks for the Omnitronics IPR400
* 2315 FIX: windows agent: BOM replacement, fixed incorrect byte offset...
* 2316 FIX: windows agent: fix garbled output of cached agent plugins...
* 2358 FIX: check_mk_agent.solaris: more correct computation of zfs used space...
diff --git a/checkman/ipr400_in_voltage b/checkman/ipr400_in_voltage
new file mode 100644
index 0000000..021424b
--- /dev/null
+++ b/checkman/ipr400_in_voltage
@@ -0,0 +1,10 @@
+title: Omnitronics IPR400 VoIP Device: Input Voltage
+agents: snmp
+catalog: hw/phone
+license: GPL
+distribution: check_mk
+description:
+ The check monitors the input voltage on Omnitronics IPR400 VoIP devices.
+
+inventory:
+ Creates exactly one service
diff --git a/checkman/ipr400_temp b/checkman/ipr400_temp
new file mode 100644
index 0000000..0ec3b0b
--- /dev/null
+++ b/checkman/ipr400_temp
@@ -0,0 +1,10 @@
+title: Omnitronics IPR400 VoIP Device: Temperature
+agents: snmp
+catalog: hw/phone
+license: GPL
+distribution: check_mk
+description:
+ The check monitors the temperature on Omnitronics IPR400 VoIP devices.
+
+inventory:
+ Creates exactly one service
diff --git a/checks/ipr400_in_voltage b/checks/ipr400_in_voltage
new file mode 100644
index 0000000..5eb878f
--- /dev/null
+++ b/checks/ipr400_in_voltage
@@ -0,0 +1,58 @@
+#!/usr/bin/python
+# -*- encoding: utf-8; py-indent-offset: 4 -*-
+# +------------------------------------------------------------------+
+# | ____ _ _ __ __ _ __ |
+# | / ___| |__ ___ ___| | __ | \/ | |/ / |
+# | | | | '_ \ / _ \/ __| |/ / | |\/| | ' / |
+# | | |___| | | | __/ (__| < | | | | . \ |
+# | \____|_| |_|\___|\___|_|\_\___|_| |_|_|\_\ |
+# | |
+# | Copyright Mathias Kettner 2014 mk(a)mathias-kettner.de |
+# +------------------------------------------------------------------+
+#
+# This file is part of Check_MK.
+# The official homepage is at http://mathias-kettner.de/check_mk.
+#
+# check_mk is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation in version 2. check_mk is distributed
+# in the hope that it will be useful, but WITHOUT ANY WARRANTY; with-
+# out even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE. See the GNU General Public License for more de-
+# ails. You should have received a copy of the GNU General Public
+# License along with GNU Make; see the file COPYING. If not, write
+# to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+# Boston, MA 02110-1301 USA.
+
+
+ipr400_in_voltage_default_levels = (12.0, 11.5) # 11.5-13.8V is the operational voltage according
+ # to the manual
+
+def inventory_ipr400_in_voltage(info):
+ if len(info) > 0:
+ yield "1", "ipr400_in_voltage_default_levels"
+
+def check_ipr400_in_voltage(item, params, info):
+ warn, crit = params
+ power = int(info[0][0]) / 1000.0 # appears to be in mV
+ perfdata = [ ( "in_voltage", power, warn, crit ) ]
+ infotext = "in voltage: %.1fV" % power
+ limitstext = "(warn/crit below %.1fV/%.1fV)" % (warn, crit)
+
+ if power <= crit:
+ return 2, infotext + ", " + limitstext, perfdata
+ elif power <= warn:
+ return 1, infotext + ", " + limitstext, perfdata
+ else:
+ return 0, infotext, perfdata
+
+check_info["ipr400_in_voltage"] = {
+ "check_function" : check_ipr400_in_voltage,
+ "inventory_function" : inventory_ipr400_in_voltage,
+ "service_description" : "IN Voltage %s",
+ "has_perfdata" : True,
+ "group" : "evolt",
+ "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.1.0").lower().startswith("ipr voip device ipr400"),
+ "snmp_info" : ( ".1.3.6.1.4.1.27053.1.4.5.10", [ "0" ] ),
+}
+
diff --git a/checks/ipr400_temp b/checks/ipr400_temp
new file mode 100644
index 0000000..3c6593a
--- /dev/null
+++ b/checks/ipr400_temp
@@ -0,0 +1,45 @@
+#!/usr/bin/python
+# -*- encoding: utf-8; py-indent-offset: 4 -*-
+# +------------------------------------------------------------------+
+# | ____ _ _ __ __ _ __ |
+# | / ___| |__ ___ ___| | __ | \/ | |/ / |
+# | | | | '_ \ / _ \/ __| |/ / | |\/| | ' / |
+# | | |___| | | | __/ (__| < | | | | . \ |
+# | \____|_| |_|\___|\___|_|\_\___|_| |_|_|\_\ |
+# | |
+# | Copyright Mathias Kettner 2014 mk(a)mathias-kettner.de |
+# +------------------------------------------------------------------+
+#
+# This file is part of Check_MK.
+# The official homepage is at http://mathias-kettner.de/check_mk.
+#
+# check_mk is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation in version 2. check_mk is distributed
+# in the hope that it will be useful, but WITHOUT ANY WARRANTY; with-
+# out even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE. See the GNU General Public License for more de-
+# ails. You should have received a copy of the GNU General Public
+# License along with GNU Make; see the file COPYING. If not, write
+# to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+# Boston, MA 02110-1301 USA.
+
+
+def inventory_ipr400_temp(info):
+ if len(info) > 0:
+ yield "Ambient", None
+
+def check_ipr400_temp(item, params, info):
+ return check_temperature(int(info[0][0]), params)
+
+check_info["ipr400_temp"] = {
+ "check_function" : check_ipr400_temp,
+ "inventory_function" : inventory_ipr400_temp,
+ "service_description" : "Temperature %s ",
+ "has_perfdata" : True,
+ "group" : "temperature",
+ "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.1.0").lower().startswith("ipr voip device ipr400"),
+ "snmp_info" : ( ".1.3.6.1.4.1.27053.1.4.5", [ 9 ] ),
+ "includes" : [ "temperature.include" ],
+}
+