Module: check_mk
Branch: master
Commit: 4ade92b6105e9bdcce68e5dbe8879d43d9b56035
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=4ade92b6105e9b…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Mon May 11 11:32:08 2015 +0200
#2268 FIX db2_tablespaces: no longer throws exception in checks when complete db2 instance
vanishes
---
.werks/2268 | 9 +++++++++
ChangeLog | 1 +
checks/db2_tablespaces | 2 ++
3 files changed, 12 insertions(+)
diff --git a/.werks/2268 b/.werks/2268
new file mode 100644
index 0000000..869e176
--- /dev/null
+++ b/.werks/2268
@@ -0,0 +1,9 @@
+Title: db2_tablespaces: no longer throws exception in checks when complete db2 instance
vanishes
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.2.7i1
+Date: 1431336655
+Class: fix
+
+
diff --git a/ChangeLog b/ChangeLog
index 1ff75a4..15bf44d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -359,6 +359,7 @@
* 2265 FIX: db2_version: improved check output when version information is
missing...
* 2266 FIX: windows agent: fixed invalid agent output if system memory exceeds 2TB
RAM...
* 2267 FIX: mk_db2.aix agent plugin: no longer throws an error when a db2 profile is
not set up properly...
+ * 2268 FIX: db2_tablespaces: no longer throws exception in checks when complete db2
instance vanishes
Multisite:
* 1758 Improved exception hander: Shows details without additional debug request,
added mailto link for error report...
diff --git a/checks/db2_tablespaces b/checks/db2_tablespaces
index 6947da4..73f7a5a 100644
--- a/checks/db2_tablespaces
+++ b/checks/db2_tablespaces
@@ -62,6 +62,8 @@ def check_db2_tablespaces(item, params, parsed):
return
db = parsed.get(instance)
+ if not db:
+ return
db_tables = dict(map(lambda x: (x[0], x[1:]), db[1:]))
tablespace = db_tables.get(tbsname)
if not tablespace: