|
CentOS Linux Server Guide |
Postfix Mail System - Step by Step GuidePart 1: Install Postfix with Mysql Support and remove Sendmail |
|||||||||||||
|
Installing of Postfix, Postfixadmin, Dovecot and Squirrelmail is not an easy task. There are some customization works you need to be done in order to get it works. I hope the following guide step by step instruction will be handy for you :)
My mail server system information: hostname : example.centos.local IP address: 192.168.139.128 Netmask : 255.255.255.0 Gateway : 192.168.139.2
There are 2 domains that I will setup for this guide. There are domain name : abc.local user mailbox : alex@abc.local
domain name : xyz.local user mailbox : yasmin@xyz.local
The postfix admin login we will be using is post@example.local, where example.local will not be created in Postfixadmin's virtual domain. This is to show you that, the email system we setup later is solely running on Postfixadmin's virtual domain
Note:
Step 0: Install prerequisite packagesIf you cannot install the packages in one line, then try to install them one by one.
Step1: Backup the current Sendmail configurationCentOS Linux default MTA is Sendmail. Since we are swtching to new MTA-Postfix. It is advisable to backup current sendmail config and bin to new location before we proceed.
First, I will create new folder call backup. Next, I backup all the files and record the sendmail path to a text.
Step2 Add in CentosPlus repos for postfix
Postfix installation by CentOS default repo does not
support mysql addon. We need to use the specified postfix that enable
the mysql support. Also, we want to avoid any disruptive update on our
customised postfix package, you need to add in exclude=postfix-*
for base and updates repo.
Step5: Install postfix from centosplus repo
The default package of posftfix does not work with Virtual Domains and Virtual Users. If you have installed it earlier, you must remove it. Use "rpm -e" or "yum remove" to remove it.
If you are not install postfix yet, the run the following command will only download and install te postfix from centosplus.
Step6: verify the postfix package installedNow, let us check the packages information been installed. Good, that is the package that we need.
Step7: verify the postfix package support the mysql
Before proceeding with the Postfix
configuration, make sure that the postfix version you have has MySQL
support. run
Step8 : Install system-switch-mail, mysql, system-switch-mail,dovecot, squirrelmailNow, let us download all the packages we need.
Step9: Switching default Sendmail to Postfix Linux mail systemThe system-switch-mail tool is the Mail Transpot Agent Switcher that enable you to switch within various Mail Trainsport Agent that installed at your system. If your system is using Sendmail by default, we need switch to postfix.
Step10: verify the setting of our new MTABefore we proceed further configuration, lets us verify on the default MTA setting. If everything is correct, you should see the highlighted text changed to sendmail.postfix
We also going to check if our mailq, sendmail and aliases has the correct configured with postfix
Step10: Remove Sendmail packagesMy previous post suggest that although both mail server packages (Sendmail and Postfix) are compatible with each other. I strongly suggest you remove Sendmail packages to only allow one mail system in the sever. Due to CentOS Linux needs minimum one mail server installed. You must make sure that you installed Postfix first then remove Sendmail! Else, you will faced with some libraries dependencies issues.
To remove Sendmail packages, please use rpm -e command
|
|||||||||||||
|
Back to Step by Step Guide on CentOS Linux Postfix Mail Server |
|
Copyright 2011 http://www.1a-centosserver.com All Rights Reserved All trademarks are the property of their respective owners. Contact Us | Terms of Use | Privacy Policy |