[Pkg-nagios-changes] [pkg-nagios-plugins] 274/413: draft fixing #615133
Jan Wagner
waja at moszumanska.debian.org
Tue Nov 26 23:13:32 UTC 2013
This is an automated email from the git hooks/post-receive script.
waja pushed a commit to branch master
in repository pkg-nagios-plugins.
commit 4e53567e602478961bfcfb6e0c3789424a1ebfaf
Author: Jan Wagner <waja at cyconet.org>
Date: Wed May 18 14:31:08 2011 +0000
draft fixing #615133
---
debian/patches/15_check_sensors_fault.dpatch | 32 ++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)
diff --git a/debian/patches/15_check_sensors_fault.dpatch b/debian/patches/15_check_sensors_fault.dpatch
new file mode 100755
index 0000000..b1f97b1
--- /dev/null
+++ b/debian/patches/15_check_sensors_fault.dpatch
@@ -0,0 +1,32 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 15_check_sensors_fault.dpatch by Jan Wagner <waja at cyconet.org>
+##
+## DP: Report UNKNOWN if sensor is faulty (fixing #615133)
+
+ at DPATCH@
+diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' nagios-plugins-1.4.15~/plugins-scripts/check_sensors.sh nagios-plugins-1.4.15/plugins-scripts/check_sensors.sh
+--- nagios-plugins-1.4.15~/plugins-scripts/check_sensors.sh 2010-07-27 22:47:16.000000000 +0200
++++ nagios-plugins-1.4.15/plugins-scripts/check_sensors.sh 2011-05-17 22:17:38.000000000 +0200
+@@ -10,7 +10,7 @@
+
+
+ print_usage() {
+- echo "Usage: $PROGNAME"
++ echo "Usage: $PROGNAME [--ignore-fault]"
+ }
+
+ print_help() {
+@@ -57,6 +57,13 @@
+ if echo ${sensordata} | egrep ALARM > /dev/null; then
+ echo SENSOR CRITICAL - Sensor alarm detected!
+ exit 2
++ elif echo ${sensordata} | egrep FAULT > /dev/null; then
++ echo SENSOR UNKNOWN - Sensor reported fault
++ if test "$1" != "-i" -a "$1" != "--ignore-fault"; then
++ exit 3
++ else
++ exit 0
++ fi
+ else
+ echo sensor ok
+ exit 0
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-nagios/pkg-nagios-plugins.git
More information about the Pkg-nagios-changes
mailing list