smtp relay

Assuming you're installing the yum version of Exim on a CentOS server, you'll need to make two configuration changes. The first is to allow the IP of the mailserver to relay through the smarthost. Open the configuration at /etc/exim/exim.conf, find the line referenced below and edit it by adding the relay server IP 109.201.130.65 at the end as shown below.


add this in server from where your mail will exit

hostlist   relay_from_hosts = 127.0.0.1
eg: hostlist   relay_from_hosts = 127.0.0.1 : 109.201.130.65

domainlist relay_domains = lsearch;/etc/virtual/domains

add domain in the aboe file also


in vetacp


hostlist relay_from_hosts = 127.0.0.1 : 43.225.53.162


these settings needs to be done on mail server from where mail will realy to another server


We might need to make changes on the SPF record. Replace the current server IP address and add the relay IP.
eg: v=spf1 a mx ip4:109.201.130.65 ~all



also


now


550 relay not permitted, authentication required


acl_check_recipient:

  

  # Accept emails from IP 192.227.72.32 without authentication

  accept  hosts = 192.227.72.32 : 192.168.1.10 : 203.0.113.5

  

  # (Other ACL rules follow here)


Step 3: Configure the MTA

On the same page Exim Configuration Editor, click on the Advanced Editor button and search on the page for “Section: POSTMAILCOUNT” and add the below details:

smart_route:
driver = manualroute
domains = ! +local_domains
ignore_target_hosts = 127.0.0.0/8
transport = remote_smtp
route_list = * smtprelay.snel.com::587
no_more

If the “Section: POSTMAILCOUNT” is not available then proceed to next step 4, or else proceed to step 5.

Step 4: IF “Section: POSTMAILCOUNT” is not available

On the Exim Configuration Editor page search for “Section: ROUTERSTART” and add below settings:

smart_route:
driver = manualroute
domains = ! +local_domains
ignore_target_hosts = 127.0.0.0/8
transport = remote_smtp
route_list = * smtprelay.snel.com::587
no_more








Fix Exim to Accept Mail Without Authentication

1️⃣ Modify acl_check_mail to Allow Unauthenticated Mail

In your exim.conf, find this section:

exim

acl_check_mail: deny !authenticated = * condition = ${if inlist {$interface_port}{465 : 587}} message = AUTH_REQUIRED

🔹 Solution: Comment out or remove the deny line:

exim

acl_check_mail: # deny !authenticated = * # condition = ${if inlist {$interface_port}{465 : 587}} # message = AUTH_REQUIRED

This stops Exim from blocking unauthenticated mail.



























Comments

Popular posts from this blog

how to install internet download manger in linux

cpanel exam CPSP Answers

How to install zimbra collaboration suite 8.8.11 on CentOS 7