Change Exim’s main sending IP

I know an easy way. Login to your server via SSH.
From console edit the exim.conf file:

vim /etc/exim.conf

Go to this lines

remote_smtp:
driver = smtp
interface = ${if exists {/etc/mailips}{${lookup{$sender_address_domain}lsearch*{/etc/mailips}{$value}{}}}{}}

and change them to:

remote_smtp:
driver = smtp
interface = Your-Second-VPS-IP-Address

Save the file and restart the Exim.
If you would like, when finished sending email, you can change the setting back to the original settings in exim.conf file.
This can be used, if for some reason, your server has been compromised via FTP or whatever, and you need to get mail sent out. I would make sure you have someone scan the server first before implementing this, because the new IP can be blacklisted just as wuickly as the first if the spammy goodness is not addressed.

g33kadmin

I am a g33k, Linux blogger, developer, student and Tech Writer for Liquidweb.com/kb. My passion for all things tech drives my hunt for all the coolz. I often need a vacation after I get back from vacation....

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.