Module: check_mk
Branch: master
Commit: 0083522aba86ef8ec355a5585194e8e41c210a0e
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=0083522aba86ef…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Wed Dec 3 19:00:30 2014 +0100
#1617 FIX lnx_if: Deal with data provided by cluster host
---
.werks/1617 | 9 +++++++++
ChangeLog | 1 +
checks/lnx_if | 7 ++++++-
3 files changed, 16 insertions(+), 1 deletion(-)
diff --git a/.werks/1617 b/.werks/1617
new file mode 100644
index 0000000..724d0c3
--- /dev/null
+++ b/.werks/1617
@@ -0,0 +1,9 @@
+Title: lnx_if: Deal with data provided by cluster host
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.2.5i7
+Date: 1417629588
+Class: fix
+
+
diff --git a/ChangeLog b/ChangeLog
index ca48adb..a93428a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -75,6 +75,7 @@
* 1609 FIX: zpool_status: fix problem when the zpool has a separate log or cache device...
* 1566 FIX: 3ware_disks: consider VERIFYING state as OK now...
* 1612 FIX: job: Fixed wrong reported start time for running jobs
+ * 1617 FIX: lnx_if: Deal with data provided by cluster host
Multisite:
* 1508 Allow input of plugin output and perfdata when faking check results...
diff --git a/checks/lnx_if b/checks/lnx_if
index 1e36aff..15e2e93 100644
--- a/checks/lnx_if
+++ b/checks/lnx_if
@@ -53,14 +53,19 @@ def if_lnx_convert_to_if64(info):
current_nic = None
index = 0
for line in info:
+ # Be careful! On clustered hosts we have more than one perf-counters section
+ # and ethtool section. This needs to be handled. Sadly we have no section
+ # headers. Try to detect it by data format.
if line[0].startswith('['):
current_nic = line[0][1:-1]
index += 1
nic_info[current_nic]['index'] = index
- elif current_nic == None: # still in perf-counters subsection
+ elif len(line) == 2 and len(line[1].split()) >= 16:
+ # This looks like a perf-counter line
nic = line[0]
nic_info[nic] = { "counters": map(int, line[1].split()) }
else:
+ # ethtool data line
nic_info[current_nic][line[0].strip()] = ":".join(line[1:]).strip()
# if index is 0 we either have found no nics or no information
Module: check_mk
Branch: master
Commit: d59176f1d458b918a9d08ca2ed596d265f74d93b
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=d59176f1d458b9…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Dec 3 18:45:26 2014 +0100
#1622 FIX megaraid_bbu: handle case isSOHGood and consider it as critical
Thanks to Jukka Santala, who wrote:
"Discovered (the hard way) that when MegaRAID BBU batteries degrade too low,
disabling WriteBack cache, the firmware doesn't turn on "battery pack needs
replacing" flag. Instead <tt>isSOHGood</tt> seems to be only reliable way
to detect this condition. In this patch I've ranked it as critical, as it
is fairly equivalent to battery pack missing. Unfortunately it's generally
too late when this goes on, so it would be nice to have little warning.
The current agents do not query "Absolute State of charge" off the controller,
and on the DELL 12G RAID-controllers this statistics doesn't even exist;
they also have different design capacity. Because of these limitations I've
resolved to just listing the "Full Charge Capacity" in the check status. I
considered having the passed on perfdata for graphing, but as they're only
updated on battery re-learn, it's limited usability. This patch is against
latest innovation versions, and has been tested again various DELL 9G,
11G and 12G servers with 5/i, 6/i, H700 and H710P RAID-controllers."
---
.werks/1622 | 24 ++++++++++++++++++++++++
ChangeLog | 1 +
checks/megaraid_bbu | 4 +++-
3 files changed, 28 insertions(+), 1 deletion(-)
diff --git a/.werks/1622 b/.werks/1622
new file mode 100644
index 0000000..e07e28a
--- /dev/null
+++ b/.werks/1622
@@ -0,0 +1,24 @@
+Title: megaraid_bbu: handle case isSOHGood and consider it as critical
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.2.5i7
+Date: 1417628636
+Class: fix
+
+Thanks to Jukka Santala, who wrote:
+
+"Discovered (the hard way) that when MegaRAID BBU batteries degrade too low,
+disabling WriteBack cache, the firmware doesn't turn on "battery pack needs
+replacing" flag. Instead <tt>isSOHGood</tt> seems to be only reliable way
+to detect this condition. In this patch I've ranked it as critical, as it
+is fairly equivalent to battery pack missing. Unfortunately it's generally
+too late when this goes on, so it would be nice to have little warning.
+The current agents do not query "Absolute State of charge" off the controller,
+and on the DELL 12G RAID-controllers this statistics doesn't even exist;
+they also have different design capacity. Because of these limitations I've
+resolved to just listing the "Full Charge Capacity" in the check status. I
+considered having the passed on perfdata for graphing, but as they're only
+updated on battery re-learn, it's limited usability. This patch is against
+latest innovation versions, and has been tested again various DELL 9G,
+11G and 12G servers with 5/i, 6/i, H700 and H710P RAID-controllers."
diff --git a/ChangeLog b/ChangeLog
index 9c93ad7..d7a9062 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -75,6 +75,7 @@
* 1566 FIX: 3ware_disks: consider VERIFYING state as OK now...
* 1612 FIX: job: Fixed wrong reported start time for running jobs
* 1571 FIX: check_mk_agent.linux: fix output of lnx_if on Ubuntu 8.04 (on older kernels), repairs tcp_conn_stats...
+ * 1622 FIX: megaraid_bbu: handle case isSOHGood and consider it as critical...
Multisite:
* 1508 Allow input of plugin output and perfdata when faking check results...
diff --git a/checks/megaraid_bbu b/checks/megaraid_bbu
index 76ae5d1..baa07cc 100644
--- a/checks/megaraid_bbu
+++ b/checks/megaraid_bbu
@@ -44,6 +44,7 @@ megaraid_bbu_refvalues = {
'Over Temperature' : ('No', 2),
'Over Charged' : ('No', 1),
'Voltage' : ('OK', 2), # nolearn
+ 'isSOHGood' : ('Yes', 2),
}
@@ -85,7 +86,8 @@ def check_megaraid_bbu(item, _no_params, info):
if 'Relative State of Charge' not in controller:
charge = ", No charge information reported for this controller"
else:
- charge = ", Charge is %s" % controller['Relative State of Charge']
+ charge = ", Charge is %s, Capacity is %s" % \
+ (controller['Relative State of Charge'], controller['Full Charge Capacity'])
# verify defined important parameters to current level
for varname, (refvalue, refstate) in megaraid_bbu_refvalues.items():
Module: check_mk
Branch: master
Commit: f9fce9a6e88406a81c321f5c24ce5487d084e866
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=f9fce9a6e88406…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Dec 3 18:40:23 2014 +0100
#1571 FIX check_mk_agent.linux: fix output of lnx_if on Ubuntu 8.04 (on older kernels), repairs tcp_conn_stats
Problem on some older kernels is, that <tt>/sys/class/net/$eth/address</tt> does
not contain a newline (or does not exist at all). We now always output an
additional newline. This does not harm and fixes the problem.
Without the fix the next section <tt>tcp_conn_stats</tt> is not correctly
detected and is missing.
---
.werks/1571 | 14 ++++++++++++++
ChangeLog | 3 ++-
agents/check_mk_agent.linux | 2 +-
3 files changed, 17 insertions(+), 2 deletions(-)
diff --git a/.werks/1571 b/.werks/1571
new file mode 100644
index 0000000..67eb6d8
--- /dev/null
+++ b/.werks/1571
@@ -0,0 +1,14 @@
+Title: check_mk_agent.linux: fix output of lnx_if on Ubuntu 8.04 (on older kernels), repairs tcp_conn_stats
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.2.5i7
+Date: 1417628312
+Class: fix
+
+Problem on some older kernels is, that <tt>/sys/class/net/$eth/address</tt> does
+not contain a newline (or does not exist at all). We now always output an
+additional newline. This does not harm and fixes the problem.
+
+Without the fix the next section <tt>tcp_conn_stats</tt> is not correctly
+detected and is missing.
diff --git a/ChangeLog b/ChangeLog
index 29c21be..9c93ad7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -38,8 +38,8 @@
* 1611 mssql.vbs: Supporting SQL-Server 2014 now
* 1568 f5_bigip_cluster_v11: new check for F5 cluster status for firmware version 11
* 1450 checkpoint_connections, checkpoint_packets: new checks to monitor Checkpoint firewalls
- * 1451 users: new check to monitor number of users logged in on a linux system...
* 1569 check_mk_agent.openbsd: add sections for mem and lnx_if (memory and network interfaces)...
+ * 1451 users: new check to monitor number of users logged in on a linux system...
* 1478 FIX: kernel.util, statgrab_cpu: fix computation of utilization...
* 1480 FIX: brocade_vdx_status: disable check on some devices that do not support it...
* 1485 FIX: dell_om_disks, dell_om_esmlog, dell_om_mem, dell_om_processors, dell_om_sensors: detect more devices...
@@ -74,6 +74,7 @@
* 1609 FIX: zpool_status: fix problem when the zpool has a separate log or cache device...
* 1566 FIX: 3ware_disks: consider VERIFYING state as OK now...
* 1612 FIX: job: Fixed wrong reported start time for running jobs
+ * 1571 FIX: check_mk_agent.linux: fix output of lnx_if on Ubuntu 8.04 (on older kernels), repairs tcp_conn_stats...
Multisite:
* 1508 Allow input of plugin output and perfdata when faking check results...
diff --git a/agents/check_mk_agent.linux b/agents/check_mk_agent.linux
index 48d6847..b301727 100755
--- a/agents/check_mk_agent.linux
+++ b/agents/check_mk_agent.linux
@@ -217,7 +217,7 @@ then
do
echo "[$eth]"
ethtool $eth | egrep '(Speed|Duplex|Link detected|Auto-negotiation):'
- echo -en "\tAddress: " ; cat /sys/class/net/$eth/address
+ echo -en "\tAddress: " ; cat /sys/class/net/$eth/address ; echo
done
fi
Module: check_mk
Branch: master
Commit: 3372d088e876a5a3c9427d4b09f1da4f64c3efb1
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=3372d088e876a5…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Dec 3 18:31:37 2014 +0100
#1570 FIX Fix notification of check_http active checks with Nagios core
When using Nagios as the core and a check command that contains single
quotes then the notification would not work. This is because the variables
are enclosed in single quotes in <tt>check_mk_templates.cfg</tt>. That file
has been changed so that for the check command macros double quotes are
being used. Check_MK itself does never use double quotes in its strings
so this is less likely to cause problems.
The Check_MK Micro Core does not have this problem. Everything works
fine here.
---
.werks/1570 | 17 +++++++++++++++++
ChangeLog | 1 +
check_mk_templates.cfg | 4 ++--
3 files changed, 20 insertions(+), 2 deletions(-)
diff --git a/.werks/1570 b/.werks/1570
new file mode 100644
index 0000000..85618f4
--- /dev/null
+++ b/.werks/1570
@@ -0,0 +1,17 @@
+Title: Fix notification of check_http active checks with Nagios core
+Level: 1
+Component: notifications
+Compatible: compat
+Version: 1.2.5i7
+Date: 1417627787
+Class: fix
+
+When using Nagios as the core and a check command that contains single
+quotes then the notification would not work. This is because the variables
+are enclosed in single quotes in <tt>check_mk_templates.cfg</tt>. That file
+has been changed so that for the check command macros double quotes are
+being used. Check_MK itself does never use double quotes in its strings
+so this is less likely to cause problems.
+
+The Check_MK Micro Core does not have this problem. Everything works
+fine here.
diff --git a/ChangeLog b/ChangeLog
index c69126e..c546fba 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -152,6 +152,7 @@
* 1582 FIX: Fixed missing graphs in mails when sending notifications to non-contacts...
* 1583 FIX: Can use contact groups without hosts/services assigned in RBN rules now...
* 1606 FIX: Moved notify.log to var/log/notify.log in OMD environments...
+ * 1570 FIX: Fix notification of check_http active checks with Nagios core...
BI:
* 1435 FIX: Saving BI aggregations: No longer reports 'Request-URI Too Large'...
diff --git a/check_mk_templates.cfg b/check_mk_templates.cfg
index 47bc763..77029b5 100644
--- a/check_mk_templates.cfg
+++ b/check_mk_templates.cfg
@@ -371,7 +371,7 @@ define command {
NOTIFY_LASTHOSTUP='$LASTHOSTUP$' \
NOTIFY_HOSTSTATE='$HOSTSTATE$' \
NOTIFY_HOSTSTATEID='$HOSTSTATEID$' \
- NOTIFY_HOSTCHECKCOMMAND='$HOSTCHECKCOMMAND$' \
+ NOTIFY_HOSTCHECKCOMMAND="$HOSTCHECKCOMMAND$" \
NOTIFY_HOSTOUTPUT='$HOSTOUTPUT$' \
NOTIFY_HOSTPERFDATA='$HOSTPERFDATA$' \
NOTIFY_LONGHOSTOUTPUT='$LONGHOSTOUTPUT$' \
@@ -386,7 +386,7 @@ define command {
NOTIFY_SERVICEOUTPUT='$SERVICEOUTPUT$' \
NOTIFY_LONGSERVICEOUTPUT='$LONGSERVICEOUTPUT$' \
NOTIFY_SERVICEPERFDATA='$SERVICEPERFDATA$' \
- NOTIFY_SERVICECHECKCOMMAND='$SERVICECHECKCOMMAND$' \
+ NOTIFY_SERVICECHECKCOMMAND="$SERVICECHECKCOMMAND$" \
NOTIFY_DATE='$DATE$' \
NOTIFY_SHORTDATETIME='$SHORTDATETIME$' \
NOTIFY_LONGDATETIME='$LONGDATETIME$' \