• 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

Issue SMTP error while using NAT address

trumbaut

New Pleskian
I recently started using a floating IP address for my droplet at Digital Ocean, following the instructions at Default Plesk page is shown for a domain assigned on a floating IP address from DigitalOcean. However, after changing subscriptions to the new floating IP (which works fine for the assigned websites), sending mails for these domains fail. For example:

1A8D8401DC 1414 Thu Feb 15 21:12:11 [email protected]
(delivery temporarily suspended: connect to alt2.gmail-smtp-in.l.google.com[64.233.187.26]:25: Connection timed out)
[email protected]


I checked Plesk Help Center which did not help. Within /etc/postfix/master.cf, the right NAT address was set (although I wonder if the floating/public IP address should be mentioned here):

plesk-10.XXX.YYY.ZZZ- unix - n n - - smtp -o smtp_bind_address=10.XXX.YYY.ZZZ -o smtp_bind_address6= -o smtp_address_preference=ipv4

On the "Server-Wide Mail Settings" page, the "Outgoing mail mode" was set to "Send from domain IP addresses". After changing this setting to "Send from the specified IP addresses: <old static IP address>" mails were able to be sent again. However, I would like a solution where Postfix uses my floating IP address as external adresses instead of the old static IP address.

Is this a bug? Or can it be fixed in an other way?

Technical details:
  • Plesk version: Plesk Onyx v17.5.3_build1705170317.16 os_CentOS 7
  • OS: CentOS Linux 7.4.1708 (Core
  • MTA: Postfix 2.10.1-6.el7
 
Are you sure this will work for a NAT address? Which "src" address should be mentioned in that case: the internal address (10.XXX.YYY.ZZZ) or the public one (EEE.FFFF.GGG.HHH)?

At this moment, an "ip route" command only has details about the primary IP address (AAA.BBB.CCC.DDD) which I want to avoid using, and the internal address (10.XXX.YYY.ZZZ):

Code:
default via AAA.BBB.CCC.1 dev eth0
10.XXX.YYY.0/16 dev eth0 proto kernel scope link src 10.XXX.YYY.ZZZ
AAA.BBB.CCC.0/24 dev eth0 proto kernel scope link src AAA.BBB.CCC.DDD
169.254.0.0/16 dev eth0 scope link metric 1002
 
Yep, your default route is going to be the public address you don't want to use. Edit the "src" on this entry and insert your floating IP.
 
Back
Top