This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
computing:storage:lsi:megaraid_monitor [2013/03/02 13:32] gcooper |
computing:storage:lsi:megaraid_monitor [2018/11/01 10:55] (current) gcooper |
||
---|---|---|---|
Line 1: | Line 1: | ||
====== Monitoring LSI SAS RAID Controllers on Linux ====== | ====== Monitoring LSI SAS RAID Controllers on Linux ====== | ||
- | See also **[[computing: | + | See also **[[computing: |
**Cheat Sheet**: http:// | **Cheat Sheet**: http:// | ||
Line 20: | Line 20: | ||
< | < | ||
- | vim / | + | vi / |
root=admin@yourdomain.com | root=admin@yourdomain.com | ||
Line 41: | Line 41: | ||
==== Install the MegaCLI Utility ==== | ==== Install the MegaCLI Utility ==== | ||
- | See **[[computing: | + | See also **[[computing: |
- | ==== CRON ==== | + | ==== cron ==== |
- | I added this to my ''/ | + | Added to ''/ |
< | < | ||
Line 65: | Line 65: | ||
#!/bin/bash | #!/bin/bash | ||
# | # | ||
- | # raid-status-megacli.sh - Gene Cooper <gcooper@sonoracomm.com> | + | # raid-status-megacli.sh - Gene Cooper < |
# | # | ||
# For newer LSI RAID controllers | # For newer LSI RAID controllers | ||
Line 76: | Line 76: | ||
# Subject of e-mail warning | # Subject of e-mail warning | ||
- | SUBJECT='RAID Array Failure on $HOSTNAME' | + | SUBJECT="RAID Array Failure on `hostname`" |
# Recipient of e-mail warnings | # Recipient of e-mail warnings | ||
Line 90: | Line 90: | ||
nice -n 19 ${COMMAND} > $STATUS | nice -n 19 ${COMMAND} > $STATUS | ||
- | # check for error | + | # Comment this section and run manually to test mail sending |
+ | # Check for error | ||
if [ -z " | if [ -z " | ||
exit 0 | exit 0 | ||
fi | fi | ||
- | # send mail | + | # Send mail |
/ | / | ||
Date: $(date) | Date: $(date) |