• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Assigning sender's IP on V 10.4.4

P

PROBUDHAN

Guest
Hello

Our server is running on Plesk V 10.4.4 with CentOS 6

I would like to know how I can assign a specific IP for all our outbound emails instead of using the default virtual shared IP

I edited the senderip file and inserted the IP I want associated with the domain and the mail server but the emails are still originating from the shared IP

Kindly suggest me a way I could send the emails from another IP


Thanks
 
Changing QMail default IP

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 1.1.1.1 and you want to change it to 2.2.2.2. Your gateway is 3.3.3.3 and does not change.

Run

Code:
/sbin/ip route

You see something like

1.2.3.4/1 dev eth0 proto kernel scope link src 1.1.1.1
1.2.3.4/16 dev eth0 scope link
default via 3.3.3.3 dev eth0

To change the default qmail IP from 1.1.1.1 to 2.2.2.2:

Code:
/sbin/ip route change default via 3.3.3.3 dev eth0 src 2.2.2.2

That’s all there is to it. All qmail outgoing mails now leave from IP 2.2.2.2 instead of 1.1.1.1
 
Last edited:
Hi abdi

Thank you so much for your reply

I ran the command you gave and it returned the following

xxx.xxx.0.0/16 dev venet0 scope link metric 1002
default dev venet0 scope link

Could you please guide on what to run next?

btw, I also tried using the IP I want the emails originating from in the bindroute and senderip files, but no help :(

Thanks again!
 
Hi abdi

I can't see a PM link, can I email you instead?

Thanks
 
Hi Abdi

Have sent you an email

Kindly check at your convenience and advise

Regards
 
What OS are you running?

Ie your /sbin/ip route seems not to give complete IP information on your server ...
Is it a VPS or a dedicated server?
 
I followed the smtproutes method mentioned in one of the links above...still no luck
 
Thank you so much abdi for taking the time out to look into it.

If this doesn't resolve, then I am afraid I'll have to change the VPS
 
Last edited by a moderator:
Just to update this thread

I was finally able to change the mailing IP through the sbin/ip route method

/sbin/ip route change default via o.l.d.i.p dev venet0 src n.e.w.i.p


Thanks
 
Yeah finally changed it, thanks :)

However mails to Gmail are still received with an old IPv6 address that I have removed from the server altogether. Even though its been like 8 hrs since I've removed it.

How long do you think it would take Google to receive the new IP. Yahoo is already receiving emails from the new IP

Do I just need to wait or is there something I need to do?
 
Back
Top