checkraid - a simple raid checker for nagios
$Revision: 98 $
checkraid [options]
-c controller
optional. select controller: adaptec, 3ware, lsi, lsi-storcli, zfs, md. Defaults to adaptec.
-v,--verbose
optional. display matched controller utility output
-t,--target target
optional. select controller target, e.g. md127 for md, myzpool for zfs, 2 for adaptec raid controller 2..
-T,--timeout timeout
optional. set timeout for this check, defaults to 15s.
This script uses oem tools to check the raid status.
It works with
exit 0
OK (no errors, everything is fine)
exit 1
WARNING ('rebuilding' state)
exit 2
ERROR ('degraded' and 'offline' states)
exit 3
UNKNOWN (controller not found, unknown status or usage errors)
Move the script anywhere you like, then add it to your snmpd.conf:
exec checkraid /path/to/checkraid [options]
or to your nrpe.conf:
command[check_raid]=sudo /usr/sbin/checkraid [options]