Re: Change plesk qmail IP address
If you’ve got a Plesk server and some unsavoury character has hosted and spammed from your server, even if you remove them you may find your IP is blocked by many of the blacklists – even though this will only be temporary for 24 or 48 hours, this is still an issue for your remaining clients.
What you need to do it temporarily change the qmail sender IP address, this is very easy to do and as I say, it’s temporary, a server reboot gets everything back to normal.
Let’s say your qmail IP address is 22.214.171.124 and you want to change it to 126.96.36.199. Your gateway is 188.8.131.52 and does not change.
SSH in to your server console and let’s look at your setup:
# /sbin/ip route
184.108.40.206/1 dev eth0 proto kernel scope link src 220.127.116.11 18.104.22.168/16 dev eth0 scope link default via 22.214.171.124 dev eth0
To change the default qmail IP from 126.96.36.199 to 188.8.131.52:
# /sbin/ip route change default via 184.108.40.206 dev eth0 src 220.127.116.11
That’s all there is to it. All qmail outgoing mails now leave from IP 18.104.22.168 instead of 22.214.171.124
Send an email, look at the header, you will see the email came from the new IP address. If you screw up, at worst, simply reboot the server to get the IP settings as before. This works fine on all versions of Plesk that we have used.