[icinga-checkins] icinga.org: icinga2/master: Add check_iostat to ITL

git at icinga.org git at icinga.org
Fri Feb 19 12:19:04 CET 2016


Module: icinga2
Branch: master
Commit: b7d55fcf48a8e2e1b23fb3312d488b3ea043453a
URL:    https://git.icinga.org/?p=icinga2.git;a=commit;h=b7d55fcf48a8e2e1b23fb3312d488b3ea043453a

Author: Thomas Widhalm <thomas.widhalm at netways.de>
Date:   Sat Dec  5 20:37:23 2015 +0100

Add check_iostat to ITL

fixes #10777

Signed-off-by: Jean Flach <jean-marcel.flach at netways.de>

---

 doc/7-icinga-template-library.md            |   16 ++++++++++++++++
 itl/plugins-contrib.d/operating-system.conf |   27 +++++++++++++++++++++++++++
 2 files changed, 43 insertions(+)

diff --git a/doc/7-icinga-template-library.md b/doc/7-icinga-template-library.md
index c83b4c7..99fee3e 100644
--- a/doc/7-icinga-template-library.md
+++ b/doc/7-icinga-template-library.md
@@ -2174,6 +2174,22 @@ Name                       | Description
 ---------------------------|-------------
 running\_kernel\_use\_sudo | Whether to run the plugin with `sudo`. Defaults to false except on Ubuntu where it defaults to true.
 
+#### <a id="plugins-contrib-command-iostat"></a> iostat
+
+The plugin [check_iostat](https://github.com/dnsmichi/icinga-plugins/blob/master/scripts/check_iostat) is used to monitor I/O with `iostat` on a linux host. The default thresholds are rather high so you can use a grapher for baselining before setting your own.
+
+Custom attributes passed as [command parameters](3-monitoring-basics.md#command-passing-parameters):
+
+Name           | Description
+---------------|-----------------------------------------------------------------------------------------------------------------------
+iostat\_disk   | **Required.** The device to monitor without path. e.g. sda or vda. (default: sda)
+iostat\_wtps   | **Required.** Warning threshold for tps (default: 100)
+iostat\_wread  | **Required.** Warning threshold for KB/s reads (default: 100)
+iostat\_wwrite | **Required.** Warning threshold for KB/s writes (default: 100)
+iostat\_ctps   | **Required.** Critical threshold for tps (default: 200)
+iostat\_cread  | **Required.** Critical threshold for KB/s reads (default: 200)
+iostat\_cwrite | **Required.** Critical threshold for KB/s writes (default: 200)
+
 #### <a id="plugin-contrib-command-yum"></a> yum
 
 The plugin `yum` is used to check the YUM package management system for package updates. To differentiate between security and normal updates it requires the YUM security plugin installed. It is provied by `Christoph Anton Mitterer` on [https://github.com](https://github.com/calestyo/check_yum).
diff --git a/itl/plugins-contrib.d/operating-system.conf b/itl/plugins-contrib.d/operating-system.conf
index 96fed28..a209b54 100644
--- a/itl/plugins-contrib.d/operating-system.conf
+++ b/itl/plugins-contrib.d/operating-system.conf
@@ -126,3 +126,30 @@ object CheckCommand "yum" {
 
 	timeout = 5m
 }
+
+object CheckCommand "iostat" {
+	import "plugin-check-command"
+	command = [ PluginContribDir + "/check_iostat" ]
+	arguments = {
+		"-d" = {
+			value = "$iostat_disk$"
+			description = "Device to check without path. e.g. sda"
+		}
+		"-w" = {
+			value ="$iostat_wtps$,$iostat_wread$,$iostat_wwrite$"
+			description = "warning threshold for tps, KB_read/s and KB_written/s"
+		}
+		"-c" = {
+			value ="$iostat_ctps$,$iostat_cread$,$iostat_cwrite$"
+			description = "warning threshold for tps, KB_read/s and KB_written/s"
+		}
+	}
+
+	vars.iostat_disk = "sda"
+	vars.iostat_wtps = 100
+	vars.iostat_wread = 100
+	vars.iostat_wwrite = 100
+	vars.iostat_ctps = 200
+	vars.iostat_cread = 200
+	vars.iostat_cwrite = 200
+}



More information about the icinga-checkins mailing list