How to change the mail server IP for sending emails, if your server ip address is blacklisted in TOP-LEVEL email providers ?
Sometimes the emails that we have sent being rejected by top level email providers because of the server IP blacklisted. In this situation where we are not able to sent or our messages that we have already sent is reached to the spam folder of others, the first step is check your IP is in any Blacklist. Here is the link to check IP black list http://mxtoolbox.com/blacklists.aspx . If your server IP address is not in this listed blacklist then the issue related to any other not related to your server IP.
If it is in Blacklist, (I) You must to take necessary actions/steps to remove IP address from there. (II) Here we have an alternative method to use another IP address for your Mail server. Here I’m explaining how to use an alternative IP address for Mail servers in a WHM/cPanel based servers.
Step I: Add new IP address to your server.
Via WHM : Home » IP Functions » Add a New IP Address
Step II: Add IP to Mail server
SSH to server
[root@server]# vi /etc/mailips (And add the new IP address as mentioned below: )
*: xxx.xxx.xxx.xxx
~
~
:wq
step III: Add a RDNS entry, It may help DC to find you
[root@server]# vi /etc/mail_reverse_dns
xxx.xxx.xxx.xxx: HOSTNAME
~
~
:wq
Step IV: (Not necessary)
Change file attribute of /etc/mailips
[root@server]# chattr +i /etc/mailips
[root@server]# lsattr /etc/mailips
----i-------- /etc/mailips
Step V:
Final step; Re-build exim config file to reflect the changes then restart Exim service.
[root@server]# /scripts/buildeximconf
[root@server]# service exim restart
Then login to WHM panel and follow the steps pasted below for using our new IP address to send emails
Login to WHM (https:IPAddress:2087) >> Home >> Service Configuration >> Exim Configuration Manager >> In Basic editor section select Domain and IP's >> turn on "Reference /etc/mailips for outgoing SMTP connections" section >> SAVE
Please refer the attached image for more details.
That’s it 🙂
Related Links:
Quick way to remove all emails from the mail queue – Exim command line option
How to count emails in mail queue with mail senders’ name – Exim command
Check spamming on server having EXIM
Hello Arun, Great Post! Actually we have followed the accurate steps and IPs has been successfully changed but with Yahoo it is still showing the same error:
Error: “421 4.7.0 [TS01] Messages from x.x.x.x temporarily deferred due to user complaints – 4.16.55.1” when sending email to Yahoo
What can we do in this case?
Thanks