Outlook

Use Mailgun with Exim on cPanel/WHM to Solve SPAM email Issue

My regular transnational/marketing email provider, Mandrill will be only available for paid MailChimp customer starting 27th April 2016. As I never exceed 12,000 FREE emails per month, I think there is no point to use any paid transnational services. Upon searching, I find out that Mailgun provides 10,000 FREE emails per month which should be sufficient for my use. Upon testing, the function provided by Mailgun is sufficient for my needs.

I mainly use this services because my websites utilize phpmail or sendmail function & also to send server generated message. This kind of email function many throw many emails into SPAM folder of the intended recipients. The situation become worsened if the intended recipients are using hotmail/livemail/outlook, which has stricter filtering. The recipient may not receive the email at all. Not even in Junk folder.

This is a big issue if you are running an e-commerce and even bigger issue for newsletter/mailing list website like Interspire Email Marketer.

To solve this issue, we can use transnational email or bulk email service such as Mailgun with Exim on cPanel/WHM server.

To integrate Mailgun with Exim on cPanel/WHM, we have to add proper settings as below. If you migrating from Mandrill, make sure all settings from Mandrill removed.

 

1. Login to WHM with a root access & browse to

 

WHM → Service Configuration → Exim Configuration Manager → Advanced Editor

 

4. Search for – “Section: AUTH” & add the following code. Change youremail@yourdomain : password with your email & Mailgun Password

mailgun_login:
driver = plaintext
public_name = LOGIN
hide client_send = : youremail@yourdomain : password

 

5. Search for – “Section: ROUTERSTART” & add the following code.

mailgun:
driver = manualroute
domains = ! +local_domains
transport = mailgun_transport
route_list = "* smtp.mailgun.org::587 byname"
host_find_failed = defer
no_more

 

6. Search for – “Section: TRANSPORTSTART” & add the following code.

mailgun_transport:
driver = smtp
hosts = smtp.mailgun.org
hosts_require_auth = smtp.mailgun.org
hosts_require_tls = smtp.mailgun.org

 

7. Save the new configuration.

8. Send a test email & you should see the email header should have something with *mailgun.*


Use Mandrill with Exim on cPanel/WHM to Solve SPAM email Issue

If you are using phpmail or sendmail function in your website, you may notice that, some of the email may end up in SPAM folder of the intended recipients. The situation become worsen if the intended recipients are using hotmail/livemail/outlook, which has stricter filtering. The recipient may not receive the email at all. Not even in Junk folder.

This is a big issue if you are running an e-commerce and even bigger issue for newsletter/mailing list website like Interspire Email Marketer.

To solve this issue, we can use transactional email or bulk email service such as Mandrill with Exim on cPanel/WHM server.

To integrate Mandrill with Exim on cPanel/WHM, we have to add proper settings as below.

 

1. Login to WHM with a root access & browse to

WHM → Service Configuration → Exim Configuration Manager → Basic Editor

 

2. In “Mail → Smarthost support”, add the following

*: smtp.mandrillapp.com

 

3. Browse to

WHM → Service Configuration → Exim Configuration Manager → Advanced Editor

 

4. Search for – “Section: AUTH” & add the following code. Change youremail@yourdomain : api-key with your email & Mandrill API Key

auth_login:
driver = plaintext
public_name = LOGIN
hide client_send = : youremail@yourdomain : api-key

 

5. Search for – “Section: PREROUTERS” & add the following code.

smart_route:
driver = manualroute
domains = ! +local_domains
ignore_target_hosts = 127.0.0.0/8
transport = auth_relay
route_list = * smtp.mandrillapp.com
no_more

 

6. Search for – “Section: TRANSPORTSTART” & add the following code.

auth_relay:
driver = smtp
port = 587
hosts_require_auth = $host_address
hosts_require_tls = $host_address

 

7. Save the new configuration.

8. Send a test email & you should see the email header should have something with *mandrill.com