Jump to content

How to send mails from different Static/Dedicated IP in Postfix - CWP Linux Centos

Featured Replies

Posted
comment_81

This topic is about the mail sending from different dedicated/static IP in CWP Postfix and Linux server using postfix MTA. Suppose you've two or more dedicated static IP and you want to host websites in One Ip and use the second Ip to send Emails only for this you need to make changes to Postfix config like Below

Step 1

Edit postfix master config  /etc/postfix/master.conf 

nano /etc/postfix/master.conf

Step 2

Find this lines and add this config : 

Quote

smtp      unix  -       -       n       -       -       smtp

and 

Quote

relay     unix  -       -       n       -       -       smtp

and below this two lines add this config : 

  -o smtp_bind_address=124.12.12.12

replace the ip with your second IP or the Ip you want to send email from

so the config will look like

smtp      unix  -       -       n       -       -       smtp
  -o smtp_bind_address=124.12.12.12 

relay     unix  -       -       n       -       -       smtp
  -o smtp_bind_address=124.12.12.12
  -o fallback_relay=

Step 3 : 

Restart postfix service : 

systemctl restart postfix

 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now