Skip to content

Commit

Permalink
Add a check command definition for check_iostats
Browse files Browse the repository at this point in the history
This should work fine with this plugin https://github.com/dnsmichi/icinga-plugins/blob/master/scripts/check_iostats

fixes #12613

Signed-off-by: Gunnar Beutner <gunnar.beutner@netways.de>
  • Loading branch information
rubber-ant authored and gunnarbeutner committed Sep 29, 2016
1 parent cb86fb8 commit 0c79b96
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 1 deletion.
20 changes: 19 additions & 1 deletion doc/10-icinga-template-library.md
Expand Up @@ -2621,9 +2621,27 @@ 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="plugin-contrib-command-iostats"></a> iostats

The plugin [check_iostats](https://github.com/dnsmichi/icinga-plugins/blob/master/scripts/check_iostats) is used to monitor I/O with `iostats` 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
---------------|-----------------------------------------------------------------------------------------------------------------------
iostats\_disk | **Required.** The device to monitor without path. e.g. sda or vda. (default: sda)
iostats\_warning\_tps | **Required.** Warning threshold for tps (default: 3000)
iostats\_warning\_read | **Required.** Warning threshold for KB/s reads (default: 50000)
iostats\_warning\_write | **Required.** Warning threshold for KB/s writes (default: 10000)
iostats\_warning\_wait | **Required.** Warning threshold for % iowait (default: 50)
iostats\_critical\_tps | **Required.** Critical threshold for tps (default: 5000)
iostats\_critical\_read | **Required.** Critical threshold for KB/s reads (default: 80000)
iostats\_critical\_write | **Required.** Critical threshold for KB/s writes (default: 25000)
iostats\_critical\_wait | **Required.** Critical threshold for % iowait (default: 80)

#### <a id="plugin-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.
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):

Expand Down
38 changes: 38 additions & 0 deletions itl/plugins-contrib.d/operating-system.conf
Expand Up @@ -147,3 +147,41 @@ object CheckCommand "iostat" {
vars.iostat_cread = 200
vars.iostat_cwrite = 200
}

object CheckCommand "iostats" {
import "plugin-check-command"
command = [ PluginContribDir + "/check_iostats" ]
arguments = {
"-d" = {
value = "$iostats_disk$"
description = "Device to check without path. e.g. sda"
}
"-w" = {
value ="$iostats_warning_tps$,$iostats_warning_read$,$iostats_warning_write$"
description = "Sets the WARNING level for tps, KB_read/s and KB_written/s, respectively"
}
"-c" = {
value ="$iostats_critical_tps$,$iostats_critical_read$,$iostats_critical_write$"
description = "Sets the CRITICAL level for tps, KB_read/s and KB_written/s, respectively"
}
"-W" = {
value ="$iostats_warning_wait$"
description = "Sets the WARNING level for iowait"
}

"-C" = {
value ="$iostats_critical_wait$"
description = "Sets the CRITICAL level for iowait"
}
}

vars.iostats_disk = "sda"
vars.iostats_warning_tps = 3000
vars.iostats_warning_read = 50000
vars.iostats_warning_write = 10000
vars.iostats_warning_wait = 50
vars.iostats_critical_tps = 5000
vars.iostats_critical_read = 80000
vars.iostats_critical_write = 25000
vars.iostats_critical_wait = 80
}

0 comments on commit 0c79b96

Please sign in to comment.