O'Reilly logo

Postfix: The Definitive Guide by Kyle D. Dent

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Installation

After you have successfully compiled Postfix, you are ready to install it. You will have to be the root user in order to perform the installation steps.

You need to create a dedicated account that will own the Postfix queue and most of its processes. The account should not permit logins and does not need a shell or a home directory. Use your normal administrative tools to create an account. You can set the password to * and its home directory and shell to invalid paths (something like /bin/false or /dev/null). By convention the username should be postfix. The entry in /etc/passwd should resemble the following:

postfix:*:1001:1001:postfix:/no/where:/bin/false

You must also create a dedicated group that is not used by any user account, including the postfix account you just created. By convention the group name is postdrop. On most systems you create groups be editing the /etc/group. Add a line like the following:

postdrop:*:1007:

Remember that Postfix is a replacement for Sendmail, and in order to maintain compatibility it installs its own sendmail binary in place of your existing one. You may want to rename the existing one to save it from being overwritten. Depending on your platform your existing sendmail is commonly in /usr/sbin/sendmail or /usr/lib/sendmail. You should be able to determine the exact location of your sendmail by executing:

# whereis sendmail

This may list a number of files. You are looking for the binary that has no extension. Once you have found it, rename ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required