[CentOS] When no MTA is installed, How to send an email with a cronjob?

Sun Jul 21 12:07:01 UTC 2013
Fred Smith <fredex at fcshome.stoneham.ma.us>

On Sun, Jul 21, 2013 at 02:12:55PM +0530, Indunil Jayasooriya wrote:
> Hi,
> 
> When no MTA is installed, How to send an email with a cronjob?
> 
> I have below entrty in my cronjob?
> 
> my /etc/cron.d/backup file looks like this.
> 
> MAILTO=myemail at example.com
> 15 11 * * * root /root/scripts/backup.sh
> 
> Can I send this email via SMTP server?
> 
> 
> Hope to hear from you.

There is a tool named SendEmail, which is a perl script that performs the
sending side (not receiving) of SMTP email handling. It's straightforward
to use via commandline, which is exactly what you would want to use from
a cron job:

http://caspian.dotconf.net/menu/Software/SendEmail/

-- 
---- Fred Smith -- fredex at fcshome.stoneham.ma.us -----------------------------
                      The eyes of the Lord are everywhere, 
                    keeping watch on the wicked and the good.
----------------------------- Proverbs 15:3 (niv) -----------------------------