Home » Postfix » Configure Postfix with multiple instances on centos

Configure Postfix with multiple instances on centos

This tutorial will tell you that how to configure Postfix with multiple instances.

Prerequisites.
Centos 6.x
Postfix 2.6

Step 1. Install postfix through below command.

#yum install postfix

Step 2. Then runs below command to enalbe postfix in multiple instances mode.

#postmulti -e init

The above command will append the below lines in main.cf

multi_instance_wrapper = ${command_directory}/postmulti -p –
multi_instance_enable = yes

Step 3. Create Secondary instance

#postmulti -I postfix-secondary -e create

or

#postmulti -i postfix-secondary -G postfix -e create

This will add below line in mail.cf

multi_instance_directories = /etc/postfix-secondary

Step 4. Enable the secondary instance.

#postmulti -i postfix-secondary -e enable

Step 5. Assign separate IP address for each instance.

#vi /etc/postfix/main.cf
inet_interfaces = localhost, 192.168.0.1
#vi /etc/postfix-secondary/main.cf
inet_interfaces = localhost, 192.168.0.2

Step 6. Restart Postfix to apply the changes.

To remove an instance.

postmulti -i instancename -p stop
postmulti -i instancename -e disable
postmulti -i instancename -e destroy

To interact with particular instance with option -c
#postconf -c /etc/postfix-secondary -e “inet_interfaces = 192.168.01”

Other useful commands.

#postmulti -i instancename -p start
#postmulti -i instancename -p stop
#postmulti -i instancename -p status

About

I am founder and webmaster of www.linuxpcfix.com and working as a Sr. Linux Administrator (Expertise on Linux/Unix & Cloud Server) and have been in the industry from last 7 years.

4 thoughts on “Configure Postfix with multiple instances on centos

  1. harish says:

    hi
    i refer the procedure which you mentioned but my email going through connecting IP address.i want to configure the postfix on multiple ip address.please help me

    1. Gsingh says:

      If you have any issue please contact us at admin@linuxpcfix.com

  2. Raghvendra says:

    hi
    i refer the procedure which you mentioned but my email going through connecting IP address.i want to configure the postfix on multiple ip address.please help me

    1. Gsingh says:

      are all the instances working properly?

Leave a Reply

Your email address will not be published. Required fields are marked *

*
*

Time limit is exhausted. Please reload the CAPTCHA.

Categorized Tag Cloud