Email/Notification

http://wiki.hetzner.de/index.php/Softwareraid/en

This contacts you in case something goes wrong.

http://blog.ioflood.com/2015/04/21/setting-up-software-raid-mdadm-status-alert-emails-for-failed-drives-in-centos-ubuntu-and-debian/

http://www.tldp.org/HOWTO/Software-RAID-HOWTO-6.html#ss6.3

Set up SSL Certificate
You will need to set up a hostname (such as a subdomain, ) and an ssl certificate for that domain before you can send mail over SMTP.

https://www.digitalocean.com/community/tutorials/how-to-secure-nginx-with-let-s-encrypt-on-centos-7

Once you are done, link your certifiate to the postfix one:

sudo ln -s /etc/ssl/certs/ca-bundle.crt /etc/postfix/cacert.pem

Set up Postfix
You will need an SMTP server to send mail. This doesn't handle recieving mail. Setting it up is similar to setting up a SMTP mail client on your phone or with Thunderbird.

Install the postfix SMTP Server (usually already installed on RHEL):

sudo yum install postfix mailx

Setup with Amazon SES
Amazon SES does put you in a sandbox by default to reduce spam.

But you can verify the email addresses that are supposed to recieve it, which is great for just simple status reports from the server.

http://docs.aws.amazon.com/ses/latest/DeveloperGuide/postfix.html

Using SASL
You'll need to set up SASL support to use an SES account:

yum install cyrus-sasl-plain service postfix restart Now everything works fine for me:

[root@host postfix]# echo &quot;SES test&quot; | mail -s &quot;SES test `date +%s`&quot; -r &quot;me@domain.com&quot; recipient@domain.com http://www.iredmail.org/forum/topic6582-iredmail-support-amazon-ec2-with-iredmail-and-amazon-ses.html

Setup With Gmail
Edit the postfix configuration file, and configure it with, for example, the Gmail SMTP servers:

relayhost = [smtp.gmail.com]:587 smtp_sasl_auth_enable = yes smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd smtp_sasl_security_options = noanonymous smtp_tls_CAfile = /etc/postfix/cacert.pem smtp_use_tls = yes Next, configure your email account, in this case Gmail:

[smtp.gmail.com]:587   USERNAME@gmail.com:PASSWORD Generate the hashed password db:

cd /etc/postfix sudo postmap sasl_passwd And now you're ready to send mail using Postfix. Here's an example command:

echo &quot;This is the message text.&quot; | mail -s &quot;the message subject&quot; recipient@gmail.com
 * Easyengine - Ubuntu Postfix Gmail SMTP
 * StackExchange UNIX - How to install postfix for sending mails to admin only

Set up Systemd Notification

 * Spiceworks - Avoid sysadmin paranoia with the right IT monitoring alerts
 * Northern Lights Labs