As ZFS is now officially supported in Ubuntu 16.04, I would like to enable email notifications for my ZFS pool. Below are the steps I have taken so far, however I am now currently stuck:
- Installed msmtp and set it up to work with an external gmail account successfully.
- Uncommented and configured /etc/zfs/zed.d/zed.rc
- Set ZED_NOTIFY_VERBOSE=1
- Ran zpool scrub expecting to receive a notification of the clean scrub, no email is sent
This is the only post that I can find relating to ZFS/ZED configuration, however I was unable to get it to work: http://louwrentius.com/the-zfs-event-daemon-on-linux.html
Update: Both responses from Mumblepins and Martin led to the fix. Below are the full steps needed to get this to work:
- Install msmtp and set it up to work with an external email account (gmail or whatever)
- Install s-nail and msmtp-mta packages to map msmtp to the mail command
- Uncomment and configure /etc/zfs/zed.d/zed.rc (keeping ZED_EMAIL_PROG="mail")
- systemctl enable zed