Module: check_mk
Branch: master
Commit: b353501ead5c199c7e9a761bdf9c26decfc4848b
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=b353501ead5c19…
Author: Goetz Golla <gg(a)mathias-kettner.de>
Date: Fri Oct 24 12:29:19 2014 +0200
#1447 domino_transactions: new check to monitor the number of transactions per minute on
Lotus Domino servers
---
.werks/1447 | 9 ++++++
ChangeLog | 1 +
checkman/domino_transactions | 24 ++++++++++++++
checks/domino_transactions | 58 ++++++++++++++++++++++++++++++++++
web/plugins/wato/check_parameters.py | 14 ++++++++
5 files changed, 106 insertions(+)
diff --git a/.werks/1447 b/.werks/1447
new file mode 100644
index 0000000..3b88448
--- /dev/null
+++ b/.werks/1447
@@ -0,0 +1,9 @@
+Title: domino_transactions: new check to monitor the number of transactions per minute on
Lotus Domino servers
+Level: 1
+Component: checks
+Compatible: compat
+Version: 1.2.5i6
+Date: 1414146516
+Class: feature
+
+
diff --git a/ChangeLog b/ChangeLog
index e8d89ac..715cb48 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -76,6 +76,7 @@
* 1188 veeam_client: Check now also outputs ReadSize and TransferedSize...
* 0663 domino_info: new check to extract informational data about a Lotus Domino
Server
* 0664 domino_users: new check to monitor the number of users on a Domino Notes
server
+ * 1447 domino_transactions: new check to monitor the number of transactions per
minute on Lotus Domino servers
* 1051 FIX: tcp_conn_stats: fix missing performance data...
* 1142 FIX: winperf_ts_sessions: fix computation, check has never really worked
* 1090 FIX: zfsget: fixed exception which happened on incomplete zfs entries
diff --git a/checkman/domino_transactions b/checkman/domino_transactions
new file mode 100644
index 0000000..e492821
--- /dev/null
+++ b/checkman/domino_transactions
@@ -0,0 +1,24 @@
+title: IBM Lotus Domino: Number of Transactions
+agents: snmp
+catalog: app/lotusnotes
+license: GPL
+distribution: check_mk
+description:
+
+ This check uses snmp to extract the average number of transactions per
+ minute on a Lotus Domino Server. Warning and critical upper limits can be
+ set.
+
+perfdata:
+ The number of transactions per minute
+
+[parameters]
+parameters(tuple): parameters is a tuple of two values
+
+ {warn}: (int) The warning level
+
+ {crit}: (int) The critical level
+
+[configuration]
+domino_transactions_default_levels (tuple): This variable is preset to { (30000,35000) }
+
diff --git a/checks/domino_transactions b/checks/domino_transactions
new file mode 100644
index 0000000..77e25ea
--- /dev/null
+++ b/checks/domino_transactions
@@ -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.
+
+domino_transactions_default_levels = ( 30000, 35000 )
+
+def inventory_domino_transactions(info):
+ if info:
+ yield None, 'domino_transactions_default_levels'
+
+def check_domino_transactions(_no_item, params, info):
+ if info:
+ reading = int(info[0][0])
+ warn, crit = params
+ infotext = "Transactions per minute (avg): %s" % reading
+ levels = " (Warn/Crit at %s/%s)" % ( warn, crit )
+ perfdata = [ ( "transactions", reading, warn, crit ) ]
+ state = 0
+ if reading >= crit:
+ state = 2
+ infotext += levels
+ elif reading >= warn:
+ state = 1
+ infotext += levels
+ yield state, infotext, perfdata
+
+
+check_info["domino_transactions"] = {
+ "check_function" : check_domino_transactions,
+ "inventory_function" : inventory_domino_transactions,
+ "service_description" : "Domino Server Transactions",
+ "has_perfdata" : True,
+ "snmp_scan_function" : lambda oid: oid(".1.3.6.1.2.1.1.2.0")
== ".1.3.6.1.4.1.311.1.1.3.1.2",
+ "snmp_info" : (".1.3.6.1.4.1.334.72.1.1.6.3",
[2]),
+ "group" : "domino_transactions"
+}
diff --git a/web/plugins/wato/check_parameters.py b/web/plugins/wato/check_parameters.py
index 14ecc9c..6cc3199 100644
--- a/web/plugins/wato/check_parameters.py
+++ b/web/plugins/wato/check_parameters.py
@@ -6880,3 +6880,17 @@ register_check_parameters(
),
None, None
)
+
+register_check_parameters(
+ subgroup_applications,
+ "domino_transactions",
+ _("Lotus Domino Transactions"),
+ Tuple(
+ title = _("Number of Transactions per Minute on a Lotus Domino
Server"),
+ elements = [
+ Integer(title = _("warning if above"), default_value = 30000 ),
+ Integer(title = _("critical if above"), default_value = 35000 ),
+ ]
+ ),
+ None, None
+)