summaryrefslogtreecommitdiffstats
path: root/contrib/check_adptraid.sh
diff options
context:
space:
mode:
authorHolger Weiss <holger@zedat.fu-berlin.de>2013-09-02 11:16:24 (GMT)
committerHolger Weiss <holger@zedat.fu-berlin.de>2013-09-02 11:16:24 (GMT)
commitb15adb7762b6caaecaa83637abfcf5fdb4802092 (patch)
tree64eddbe2aa1a7f98a140be0f7973f05d7a781ae0 /contrib/check_adptraid.sh
parentc4d5882b9e1d07c7b61091062b7d085fa5f00284 (diff)
downloadmonitoring-plugins-b15adb7762b6caaecaa83637abfcf5fdb4802092.tar.gz
Remove "contrib" plugins
These days, sites such as "Nagios Exchange" are a much better place for publishing plugins not maintained by the Plugins Development Team.
Diffstat (limited to 'contrib/check_adptraid.sh')
-rw-r--r--contrib/check_adptraid.sh75
1 files changed, 0 insertions, 75 deletions
diff --git a/contrib/check_adptraid.sh b/contrib/check_adptraid.sh
deleted file mode 100644
index e3c47be..0000000
--- a/contrib/check_adptraid.sh
+++ /dev/null
@@ -1,75 +0,0 @@
1#! /bin/sh
2#
3# Modified check_sensors to check the alarm status of an Adaptec 3200S RAID
4# controller.
5#
6# Scott Lambert -- lambert@lambertfam.org
7#
8# Tested on FreeBSD 4.7 with the adptfbsd_323.tgz package installed. This
9# package installs all it's programs into /usr/dpt.
10#
11
12PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin
13
14PROGNAME=`basename $0`
15PROGPATH=`echo $0 | sed -e 's,[\\/][^\\/][^\\/]*$,,'`
16REVISION=`echo '$Revision: 302 $' | sed -e 's/[^0-9.]//g'`
17
18. $PROGPATH/utils.sh
19
20RAIDUTIL_CMD="/usr/dpt/raidutil -A ?"
21
22print_usage() {
23 echo "Usage: $PROGNAME"
24}
25
26print_help() {
27 print_revision $PROGNAME $REVISION
28 echo ""
29 print_usage
30 echo ""
31 echo "This plugin checks alarm status of Adaptec 3200S RAID controller."
32 echo ""
33 support
34 exit 0
35}
36
37case "$1" in
38 --help)
39 print_help
40 exit 0
41 ;;
42 -h)
43 print_help
44 exit 0
45 ;;
46 --version)
47 print_revision $PROGNAME $REVISION
48 exit 0
49 ;;
50 -V)
51 print_revision $PROGNAME $REVISION
52 exit 0
53 ;;
54 *)
55 raidutiloutput=`$RAIDUTIL_CMD 2>&1`
56 status=$?
57 if test "$1" = "-v" -o "$1" = "--verbose"; then
58 echo ${raidutiloutput}
59 fi
60 if test ${status} -eq 127; then
61 echo "RAIDUTIL UNKNOWN - command not found (did you install raidutil?)"
62 exit -1
63 elif test ${status} -ne 0 ; then
64 echo "WARNING - raidutil returned state $status"
65 exit 1
66 fi
67 if echo ${raidutiloutput} | egrep On > /dev/null; then
68 echo RAID CRITICAL - RAID alarm detected!
69 exit 2
70 else
71 echo raid ok
72 exit 0
73 fi
74 ;;
75esac