Created
August 27, 2015 09:48
-
-
Save AndrewRose/9a725ce7706e771303b8 to your computer and use it in GitHub Desktop.
megacli has been superseded by storcli .. below is a quick and dirty method of monitoring your megaraid.. drop into /etc/cron.d/hourly for instance and be sure to have a mail server running and update with your email address.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
storcli64 /c0 show events type=sincereboot filter=warning,critical,fatal > /etc/storcli/status.tmp | |
if ! diff -q /etc/storcli/status /etc/storcli/status.tmp > /dev/null ; then | |
cat /etc/storcli/status.tmp | mail -s "RAID Problem on hostname!" user@example.com,anotheruser@example.com | |
mv /etc/storcli/status.tmp /etc/storcli/status | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment