Skip to content

xraystyle/raid_check

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 

Repository files navigation

raid_check is a small Ruby script that uses the 'mail' gem to send email notifications in the event of an error or  warning appearing in a 3ware RAID controller log.

If you use tw_cli to manage your RAID arrays, this should work for you.

Make sure you install the 'mail' gem, found here:
https://github.com/mikel/mail

Edit the script near the top to add the correct credentials for your mail server and email addresses.

A bit of info when running this as a cron:

You will need to make sure your cron scripts are running with the environment properly configured. You need to list the GEM_HOME path at the very least in your crontab or the 'mail' gem won't work. It's also a good idea to set $PATH in the crontab to whatever it normally is for that user account. 

EXAMPLE:

....
# at 5 a.m every week with:
# 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/
# 
# For more information see the manual pages of crontab(5) and cron(8)
# 
GEM_HOME = /var/lib/gems/1.9.1
PATH = /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
...

etc.

About

A small Ruby script that sends email notifications in the event of a RAID error on a 3ware controller

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages