Operating System - Linux
1821801 Members
3109 Online
109637 Solutions
New Discussion юеВ

Send mail from linux to external smtp server

 
mjsunil
Advisor

Send mail from linux to external smtp server

Hi,I want to add a cron job to monitor the system and then send mail to external smtp if the threshold value is reached.I want to know if there is any module or program like ABmailer for windows is available in linux to send mail to external smtp from through the script.
Cheers! - mjs
5 REPLIES 5
Alexander Chuzhoy
Honored Contributor

Re: Send mail from linux to external smtp server

simple command that you can add to the script:

echo hello |mail -s test mail@mailserver.com

where test is the subject
hello is the message body and
mail@mailserver.com is the destination mail address
mjsunil
Advisor

Re: Send mail from linux to external smtp server

Thks Alexander, I dont want to configure sendmail or any mail server in the linux box. Will "mail" work without the sendmail mail?
thks -mjs
Alexander Chuzhoy
Honored Contributor

Re: Send mail from linux to external smtp server

The dns suppose to recognize the destination domain.You don't have to configure sendmail for this.
mjsunil
Advisor

Re: Send mail from linux to external smtp server

Hi,
I dont have dns server running in my local machine
rgds - mjs
Alexander Chuzhoy
Honored Contributor

Re: Send mail from linux to external smtp server

The station doesn't necessary have to be a dns server it can manage find as DNS client.What I mean is that the station has to understand what address has MX record of certain domain.