Postfix Mail Server Installation Guide

Question: What are the recommended steps to install Postfix mail Server?

Answer:

For CentOS/Fedora/RHE
Install the postfix mail server using the following command
$ yum install postfix

To configure postfix to run on server boot,  use the following command
$ chkconfig postfix on

To run the postfix mail server service, use the following command 
$ service postfix start

To install  dovecot IMAP/pop3 server, use the following commands
$ yum install dovecot

In case you want to use MySQL for accounts storage user following the command. (Remember MySQL should already be installed and configured)
$ yum install dovecot-mysql (Not required for HC9 or HC10).

To configure Dovecot to run on server boot,  use the following command
$ chkconfig dovecot on

To run the dovecot  service use the following command 
$ service dovecot start

In case you want to use SMTP-AUTH, use the following command
$ yum install cyrus-sasl 

=================== ============================

For Debian/Ubuntu 

Install the postfix mail server using the following command
 $ apt-get install postfix
 
 In case you want to use MySQL for accounts storage, use the following command. (Remember MySQL should already be installed and configured)
 $ apt-get install postfix-mysql (Not required for HC9 or HC10). 
 
 To configure postfix to run on server boot,  use the following command
 $ update-rc.d postfix defaults
 
 To run the postfix mail server service, run the following command
 $ service postfix start
 
 To install  dovecot imap/pop3 server, use following commands
 $ apt-get install dovecot-common
 $ apt-get install dovecot-imapd
 $ apt-get install dovecot-pop3d
 
 To configure Dovecot to run on server boot  use the following command
 $ update-rc.d dovecot defaults
 
 To run the dovecot  service use the following command
 $ service dovecot start
 
 In case you want to use SMTP-AUTH, use the following command
 $ apt-get install sasl2-bin