source: server/mail/postfix.xml@ 8d8e269

10.0 10.1 11.0 11.1 6.0 6.1 6.2 6.2.0 6.2.0-rc1 6.2.0-rc2 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 krejzi/svn lazarus nosym perl-modules qt5new systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/test-20220226
Last change on this file since 8d8e269 was 8d8e269, checked in by Igor Živković <igor@…>, 18 years ago

Removed redundant PCRE make variables for Postfix installation, reported
by Stefan Morrell.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@2829 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 10.8 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
3 "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7<!ENTITY postfix-download-http "http://www.mirrorspace.org/postfix/official/postfix-&postfix-version;.tar.gz">
8<!ENTITY postfix-download-ftp "ftp://ftp.porcupine.org/mirrors/postfix-release/official/postfix-&postfix-version;.tar.gz">
9<!ENTITY postfix-size "1.9 MB">
10<!ENTITY postfix-buildsize "81 MB">
11<!ENTITY postfix-time "0.29 SBU">
12
13]>
14
15<sect1 id="postfix" xreflabel="Postfix-&postfix-version;">
16<sect1info>
17<othername>$LastChangedBy$</othername>
18<date>$Date$</date>
19</sect1info>
20<?dbhtml filename="postfix.html"?>
21<title>Postfix-&postfix-version;</title>
22
23<sect2>
24<title>Introduction to Postfix</title>
25
26<para>The <application>Postfix</application> package contains a Mail
27Transport Agent (<acronym>MTA</acronym>). This is useful for sending email
28to other users of your host machine. It can also be configured to be a
29central mail server for your domain, a mail relay agent or simply a mail
30delivery agent to your local Internet Service Provider
31(<acronym>ISP</acronym>).</para>
32
33<sect3><title>Package information</title>
34<itemizedlist spacing='compact'>
35<listitem><para>Download (HTTP): <ulink
36url="&postfix-download-http;"/></para></listitem>
37<listitem><para>Download (FTP): <ulink
38url="&postfix-download-ftp;"/></para></listitem>
39<listitem><para>Download size: &postfix-size;</para></listitem>
40<listitem><para>Estimated Disk space required:
41&postfix-buildsize;</para></listitem>
42<listitem><para>Estimated build time:
43&postfix-time;</para></listitem></itemizedlist>
44</sect3>
45
46<sect3><title><application>Postfix</application> dependencies</title>
47<sect4><title>Required</title>
48<para><xref linkend="db"/></para></sect4>
49<sect4><title>Optional</title>
50<para>
51<xref linkend="pcre"/>,
52<xref linkend="mysql"/>,
53<xref linkend="postgresql"/>,
54<xref linkend="openldap"/> and
55<xref linkend="cyrus-sasl"/>
56</para></sect4>
57</sect3>
58
59</sect2>
60
61<sect2>
62<title>Installation of <application>Postfix</application></title>
63
64<para>Before you compile the program, you need to create users and groups that
65will be expected to be in place when the install script executes. Add the
66users and groups with the following commands:</para>
67
68<screen><userinput><command>groupadd postfix &amp;&amp;
69groupadd postdrop &amp;&amp;
70groupadd -g 65534 nogroup &amp;&amp;
71useradd -c postfix -d /dev/null -g postfix -s /bin/false postfix &amp;&amp;
72useradd -c nobody -d /home -g nogroup -s /bin/bash -u 65534 nobody &amp;&amp;
73chown postfix:postfix /var/mail</command></userinput></screen>
74
75<para>Install <application>Postfix</application> by running the following commands:</para>
76
77<screen><userinput><command>make &amp;&amp;
78sh postfix-install daemon_directory=/usr/sbin \
79 manpage_directory=/usr/share/man \
80 sample_directory=/usr/share/doc/postfix \
81 -non-interactive</command></userinput></screen>
82
83<para>The final installation step is to install the program's documentation with
84the following commands:</para>
85
86<screen><userinput><command>install -d /usr/share/doc/postfix &amp;&amp;
87cp -rf html/* /usr/share/doc/postfix</command></userinput></screen>
88
89</sect2>
90
91<sect2>
92<title>Command explanations</title>
93
94<para><command>sh postfix-install ... -non-interactive</command> : This keeps
95the install script from asking any questions, thereby accepting default
96destination directories in all but the three cases explicitly mention.</para>
97
98<para><option>CCARGS="$CCARGS -DHAS_MYSQL -I/usr/include/mysql"
99AUXLIBS="$AUXLIBS -L/usr/lib/mysql -lmysqlclient -lz -lm"</option> :
100These <command>make</command> variables add
101<application>My<acronym>SQL</acronym></application> support to
102<application>Postfix</application>.</para>
103
104<para><option>CCARGS="$CCARGS -DHAS_PGSQL -I/usr/include/postgresql/server"
105AUXLIBS="$AUXLIBS -lpq"</option>: These <command>make</command> variables add
106<application>Postgre<acronym>SQL</acronym></application> support to
107<application>Postfix</application>.</para>
108
109<para><option>CCARGS="$CCARGS -DHAS_LDAP" AUXLIBS="$AUXLIBS -lldap -llber"</option> : These
110<command>make</command> variables add
111<application>Open<acronym>LDAP</acronym></application> support to
112<application>Postfix</application>.</para>
113
114<para><option>CCARGS="$CCARGS -DUSE_SASL_AUTH" AUXLIBS="$AUXLIBS -lsasl"</option> : These
115<command>make</command> variables add <application>Cyrus
116<acronym>SASL</acronym></application> support to
117<application>Postfix</application>.</para>
118
119</sect2>
120
121<sect2>
122<title>Configuring <application>Postfix</application></title>
123
124<sect3><title>Config files</title>
125<para><filename>/etc/aliases</filename>,
126<filename>/etc/postfix/main.cf</filename> and
127<filename>/etc/postfix/master.cf</filename></para>
128</sect3>
129
130<sect3><title>Configuration Information</title>
131
132<screen><userinput><command>cat &gt;&gt; /etc/aliases &lt;&lt; "EOF"</command>
133# Begin /etc/aliases
134
135MAILER-DAEMON: postmaster
136postmaster: root
137
138root: LOGIN
139# End /etc/aliases
140<command>EOF</command></userinput></screen>
141
142<note><para>To protect an existing <filename>/etc/aliases</filename> file, the
143above command appends these aliases to it if it exists. This file should be
144checked and duplicate aliases removed, if present.</para></note>
145
146<para>The <filename>/etc/aliases</filename> file that was just created or
147appended, the <filename>main.cf</filename> and the
148<filename>master.cf</filename> must be personalized for your system. The
149<filename>aliases</filename> file needs your non-root login identity so mail
150addressed to root can be forwarded to you at the user level. The
151<filename>main.cf</filename> file needs your fully qualified hostname. All of
152these edits can be done with sed commands entered into the console with
153appropriate substitutions of your non-root login name for
154<replaceable>[user]</replaceable> and your fully qualified hostname for
155<replaceable>[localhost.localdomain]</replaceable>. You will find the
156<filename>main.cf</filename> file is self documenting, so load it into your
157editor to make the changes you need for your situation.</para>
158
159<screen><userinput><command>sed -i "s/LOGIN/<replaceable>[user]</replaceable>/" /etc/aliases &amp;&amp;
160sed -i "s/#myhostname = host.domain.tld/myhostname = \
161 <replaceable>[localhost.localdomain]</replaceable>/" /etc/postfix/main.cf &amp;&amp;
162/usr/bin/newaliases &amp;&amp;
163/usr/sbin/postfix start</command></userinput></screen></sect3>
164
165<sect3><title>Postfix init.d script</title>
166
167<para>To automate the running of Postfix at startup, install the <filename>/etc/rc.d/init.d/postfix</filename>
168init script included in the <xref linkend="intro-important-bootscripts"/> package.</para>
169
170<screen><userinput><command>make install-postfix</command></userinput></screen>
171
172</sect3>
173
174</sect2>
175
176<sect2>
177<title>Contents</title>
178
179<para>The <application>Postfix</application> package contains
180<command>bounce</command>, <command>cleanup</command>,
181<command>error</command>, <command>flush</command>,
182<command>lmtp</command>, <command>local</command>,
183<command>mailq</command>, <command>master</command>,
184<command>newaliases</command>, <command>nqmgr</command>,
185<command>pickup</command>, <command>pipe</command>,
186<command>postalias</command>, <command>postcat</command>,
187<command>postconf</command>, <command>postdrop</command>,
188<command>postfix</command>, <command>postkick</command>,
189<command>postlock</command>, <command>postlog</command>,
190<command>postmap</command>, <command>postqueue</command>,
191<command>postsuper</command>, <command>qmgr</command>,
192<command>qmqpd</command>, <command>sendmail</command>,
193<command>showq</command>, <command>smtp</command>,
194<command>smtpd</command>, <command>spawn</command>,
195<command>trivial-rewrite</command>, and <command>virtual</command>.</para>
196
197</sect2>
198
199<sect2><title>Description</title>
200
201<sect3><title>postfix</title>
202<para><command>postfix</command> is the program that starts and stops the mail delivery system.</para></sect3>
203
204<sect3><title>master</title>
205<para><command>master</command> is the resident process that runs
206<filename>bounce</filename>, <filename>cleanup</filename>,
207<filename>error</filename>, <filename>flush</filename>,
208<filename>lmtp</filename>, <filename>local</filename>,
209<filename>nqmgr</filename>, <filename>pickup</filename>,
210<filename>pipe</filename>, <filename>qmgr</filename>,
211<filename>qmqpd</filename>, <filename>showq</filename>,
212<filename>smtp</filename>, <filename>smtpd</filename>,
213<filename>spawn</filename>, <filename>trivial-rewrite</filename> and
214<filename>virtual</filename> on demand. These programs are not designed to
215work as user commands.</para></sect3>
216
217<sect3><title>postqueue</title>
218<para><command>postqueue</command> implements the
219<application>Postfix</application> user interface for
220queue management. It implements all the operations that are traditionally
221available via the <command>sendmail</command> command.</para></sect3>
222
223<sect3><title>sendmail</title>
224<para><command>sendmail</command> implements the
225<application>Postfix</application> to
226<application>Sendmail</application> compatibility interface.
227<filename class="symlink">mailq</filename> and <filename
228class="symlink">newaliases</filename> are symlinks to
229<command>sendmail</command>.</para></sect3>
230
231<sect3><title>showq</title>
232<para><command>showq</command> will emulate the <filename
233class="symlink">mailq</filename> command when the
234<application>Postfix</application> mail system is
235not running.</para></sect3>
236
237<sect3><title>postsuper</title>
238<para><command>postsuper</command> does maintenance jobs on the
239<application>Postfix</application> queue.</para></sect3>
240
241<sect3><title>postalias</title>
242<para><command>postalias</command> creates, queries or updates
243<application>Postfix</application> alias
244databases.</para></sect3>
245
246<sect3><title>postcat</title>
247<para><command>postcat</command> prints the contents of a
248<application>Postfix</application> queue file in human-readable
249form.</para></sect3>
250
251<sect3><title>postconf</title>
252<para><command>postconf</command> prints or changes the value of configuration
253parameters.</para></sect3>
254
255<sect3><title>postdrop</title>
256<para><command>postdrop</command> creates a file in the maildrop directory and
257copies its standard input to the file.</para></sect3>
258
259<sect3><title>postkick</title>
260<para><command>postkick</command> makes the mail system private
261<acronym>IPC</acronym> accessible for use in shell
262scripts.</para></sect3>
263
264<sect3><title>postlock</title>
265<para><command>postlock</command> locks a file for exclusive access and
266executes a command on that file.</para></sect3>
267
268<sect3><title>postlog</title>
269<para><command>postlog</command> implements a logging interface for use in
270shell scripts.</para></sect3>
271
272<sect3><title>postmap</title>
273<para><command>postmap</command> creates, queries or updates
274<application>Postfix</application> lookup tables.</para></sect3>
275
276</sect2>
277
278</sect1>
279
Note: See TracBrowser for help on using the repository browser.