Email Alerting with Debian
From blog.peacon.co.uk
Email alterting can easily be added to a Debian install using logcheck and a simple MTA such as ssmtp.
Logcheck watches the various system logs and will email an alerts as entries are made. Since most entries are informational, the system uses a set of filter definitions (essentially grep filters) to avoid emailing the raft of normal entries.
Logcheck
Installation is simple:
#apt-get install logcheck
ssmtp
Debian includes an MTA on the standard installation, but it is too complex for just the basic email requirements of logcheck when using an internal SMTP relay. It can be simply replaced with ssmtp:
#apt-get install ssmtp