source: server/mail/postfix.xml@ be98f1e0

11.0 ken/refactor-virt lazarus qt5new trunk
Last change on this file since be98f1e0 was be98f1e0, checked in by Douglas R. Reno <renodr@…>, 4 months ago

Update to postfix-3.6.1

  • Property mode set to 100644
File size: 21.6 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY postfix-download-http " ">
8 <!ENTITY postfix-download-ftp "ftp://ftp.porcupine.org/mirrors/postfix-release/official/postfix-&postfix-version;.tar.gz">
9 <!ENTITY postfix-md5sum "85d1c2b06a469ba6cc61946c7042e40e">
10 <!ENTITY postfix-size "4.5 MB">
11 <!ENTITY postfix-buildsize "203 MB">
12 <!ENTITY postfix-time "0.2 SBU (Using parallelism=4)">
13]>
14
15<sect1 id="postfix" xreflabel="Postfix-&postfix-version;">
16 <?dbhtml filename="postfix.html"?>
17
18 <sect1info>
19 <date>$Date$</date>
20 </sect1info>
21
22 <title>Postfix-&postfix-version;</title>
23
24 <indexterm zone="postfix">
25 <primary sortas="a-Postfix">Postfix</primary>
26 </indexterm>
27
28 <sect2 role="package">
29 <title>Introduction to Postfix</title>
30
31 <para>
32 The <application>Postfix</application> package contains a Mail Transport
33 Agent (MTA). This is useful for sending email to other users of your host
34 machine. It can also be configured to be a central mail server for your
35 domain, a mail relay agent or simply a mail delivery agent to your local
36 Internet Service Provider.
37 </para>
38
39 &lfs101_checked;
40
41 <bridgehead renderas="sect3">Package Information</bridgehead>
42 <itemizedlist spacing="compact">
43 <listitem>
44 <para>
45 Download (HTTP): <ulink url="&postfix-download-http;"/>
46 </para>
47 </listitem>
48 <listitem>
49 <para>
50 Download (FTP): <ulink url="&postfix-download-ftp;"/>
51 </para>
52 </listitem>
53 <listitem>
54 <para>
55 Download MD5 sum: &postfix-md5sum;
56 </para>
57 </listitem>
58 <listitem>
59 <para>
60 Download size: &postfix-size;
61 </para>
62 </listitem>
63 <listitem>
64 <para>
65 Estimated disk space required: &postfix-buildsize;
66 </para>
67 </listitem>
68 <listitem>
69 <para>
70 Estimated build time: &postfix-time;
71 </para>
72 </listitem>
73 </itemizedlist>
74<!--
75 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
76 <itemizedlist spacing="compact">
77 <listitem>
78 <para>
79 Required patch:
80 <ulink url="&patch-root;/postfix-&postfix-version;-glibc230_fix-1.patch"/>
81 </para>
82 </listitem>
83 </itemizedlist>
84-->
85 <bridgehead renderas="sect3">Postfix Dependencies</bridgehead>
86
87 <bridgehead renderas="sect4">Recommended</bridgehead>
88 <para role="recommended">
89 <xref linkend="db"/>,
90 <xref linkend="cyrus-sasl"/>, and
91 <xref linkend="libnsl"/>
92 </para>
93
94 <bridgehead renderas="sect4">Optional</bridgehead>
95 <para role="optional">
96 <xref linkend="icu"/> for Email Address Internationalization (SMTPUTF8) support,
97 <xref linkend="mariadb"/> or <ulink url="http://www.mysql.com/">MySQL</ulink>,
98 <xref linkend="openldap"/>,
99 <xref linkend="pcre"/>,
100 <xref linkend="postgresql"/>,
101 <xref linkend="sqlite"/>, and
102 <ulink url="http://cr.yp.to/cdb.html">CDB</ulink> or
103 <ulink url="http://www.corpit.ru/mjt/tinycdb.html">TinyCDB</ulink>
104 </para>
105
106 <para>
107 Note that <application>SQLite</application>,
108 <application>MySQL</application>, <application>PostgreSQL</application>
109 and <application>CDB</application> are only useful if there is a known
110 need for them.
111 </para>
112
113 <para condition="html" role="usernotes">
114 User Notes: <ulink url="&blfs-wiki;/postfix"/>
115 </para>
116 </sect2>
117
118 <sect2 role="installation">
119 <title>Installation of Postfix</title>
120
121 <sect3>
122 <title>Adding Users and Groups</title>
123
124 <para>
125 Before you compile the program, you need to create users and groups that
126 will be expected to be in place during the installation. Add the users
127 and groups with the following commands issued by the
128 <systemitem class="username">root</systemitem> user:
129 </para>
130
131<screen role="root"><userinput>groupadd -g 32 postfix &amp;&amp;
132groupadd -g 33 postdrop &amp;&amp;
133useradd -c "Postfix Daemon User" -d /var/spool/postfix -g postfix \
134 -s /bin/false -u 32 postfix &amp;&amp;
135chown -v postfix:postfix /var/mail</userinput></screen>
136 </sect3>
137
138 <sect3>
139 <title>Configuring the Build</title>
140
141 <para>
142 The README files are formatted to be read with a pager like
143 <application>Less</application> or <application>More</application>.
144 If you want to use a text editor, make them legible with the
145 following sed:
146 </para>
147
148<screen><userinput>sed -i 's/.\x08//g' README_FILES/*</userinput></screen>
149<!--
150 <para>
151 Apply a patch to allow <application>Postfix</application> to compile
152 on <application>Glibc-2.30</application> where some macros were
153 dropped:
154 </para>
155
156<screen><userinput>patch -Np1 -i ../postfix-&postfix-version;-glibc230_fix-1.patch</userinput></screen>
157-->
158 <para>
159 The <application>Postfix</application> source tree does not contain a
160 <filename>configure</filename> script, rather the makefile in the
161 top-level directory contains a <option>makefiles</option> target that
162 regenerates all the other makefiles in the build tree. If you wish to
163 use additional software such as a database back-end for virtual users,
164 or TLS/SSL authentication, you will need to regenerate the makefiles
165 using one or more of the appropriate <envar>CCARGS</envar> and
166 <envar>AUXLIBS</envar> settings listed below.
167 </para>
168
169 <para>
170 For more details read the readme files.
171 </para>
172<!-- We reverted to Berkeley DB-5.3.28 and that is handled
173 <para>
174 The current version of <xref linkend="db"/> is not recognised by a
175 hard-coded test for known versions. To build with this version use the
176 following sed:
177 </para>
178
179<screen><userinput>sed -i 's/DB_VERSION_MAJOR == 6 .*||/DB_VERSION_MAJOR &gt; 4 ||/' \
180 src/util/dict_db.c</userinput></screen>
181-->
182 <sect4>
183 <title>Cyrus-SASL</title>
184
185 <para>
186 To use <application>Cyrus-SASL</application> with
187 <application>Postfix</application>, use the following arguments:
188 </para>
189
190<screen><literal>CCARGS='-DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl'
191AUXLIBS='-lsasl2'</literal></screen>
192
193 </sect4>
194
195 <sect4>
196 <title>OpenLDAP</title>
197
198 <para>
199 To use <application>OpenLDAP</application> with
200 <application>Postfix</application>, use the following arguments:
201 </para>
202
203<screen><literal>CCARGS='-DHAS_LDAP'
204AUXLIBS='-lldap -llber'</literal></screen>
205
206 </sect4>
207
208 <sect4>
209 <title>Sqlite</title>
210
211 <para>
212 To use <application>Sqlite</application> with
213 <application>Postfix</application>, use the following arguments:
214 </para>
215
216<screen><literal>CCARGS='-DHAS_SQLITE'
217AUXLIBS='-lsqlite3 -lpthread'</literal></screen>
218
219 </sect4>
220
221 <sect4>
222 <title>MySQL</title>
223
224 <para>
225 To use <application>MySQL</application> with
226 <application>Postfix</application>, use the following arguments:
227 </para>
228
229<screen><literal>CCARGS='-DHAS_MYSQL -I/usr/include/mysql'
230AUXLIBS='-lmysqlclient -lz -lm'</literal></screen>
231
232 </sect4>
233
234 <sect4>
235 <title>PostgreSQL</title>
236
237 <para>
238 To use <application>PostgreSQL</application> with
239 <application>Postfix</application>, use the following arguments:
240 </para>
241
242<screen><literal>CCARGS='-DHAS_PGSQL -I/usr/include/postgresql'
243AUXLIBS='-lpq -lz -lm'</literal></screen>
244
245 </sect4>
246
247 <sect4>
248 <title>CDB/TinyCDB</title>
249
250 <para>
251 To use <application>CDB</application> or
252 <application>TinyCDB</application> with
253 <application>Postfix</application>, use the following arguments:
254 </para>
255
256<screen><literal>CCARGS='-DHAS_CDB'
257AUXLIBS='<replaceable>&lt;/path/to/CDB&gt;</replaceable>/libcdb.a'</literal></screen>
258
259 </sect4>
260
261 <sect4>
262 <title>StartTLS Authentication</title>
263
264 <para>
265 To use <application>OpenSSL</application> with
266 <application>Postfix</application>, use the following arguments:
267 </para>
268
269<screen><literal>CCARGS='-DUSE_TLS -I/usr/include/openssl/'
270AUXLIBS='-lssl -lcrypto'</literal></screen>
271 </sect4>
272
273 </sect3>
274
275 <sect3>
276 <title>Installing Postfix</title>
277
278 <para>
279 If you have <application>Cyrus SASL</application> and
280 <application>OpenSSL</application> installed, install
281 <application>Postfix</application> by running the following commands:
282 </para>
283
284<screen><userinput>make CCARGS="-DUSE_TLS -I/usr/include/openssl/ \
285 -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" \
286 AUXLIBS="-lssl -lcrypto -lsasl2" \
287 makefiles &amp;&amp;
288make</userinput></screen>
289
290 <!-- There is a testsuite, but it fails a lot. It seems to need
291 the host to be specifically setup for the tests.
292 Run with `make tests' and `make root_tests' -->
293 <para>
294 This package does not come with a useful test suite.
295 </para>
296
297 <para>
298 Now, as the <systemitem class="username">root</systemitem> user:
299 </para>
300
301<!-- dev note: sh postfix-install -non-interactive install_root=<DESTDIR> ... -->
302
303<screen role="root"><userinput>sh postfix-install -non-interactive \
304 daemon_directory=/usr/lib/postfix \
305 manpage_directory=/usr/share/man \
306 html_directory=/usr/share/doc/postfix-&postfix-version;/html \
307 readme_directory=/usr/share/doc/postfix-&postfix-version;/readme</userinput></screen>
308
309 </sect3>
310
311 </sect2>
312
313 <sect2 role="commands">
314 <title>Command Explanations</title>
315
316 <para>
317 <command>make makefiles</command>: This command rebuilds the makefiles
318 throughout the source tree to use the options contained in the
319 <envar>CCARGS</envar> and <envar>AUXLIBS</envar> variables.
320 </para>
321
322 <para>
323 <command>sh postfix-install -non-interactive</command>: This keeps the
324 install script from asking any questions, thereby accepting default
325 destination directories in all but the few cases. If the
326 <option>html_directory</option> and <option>readme_directory</option>
327 options are not set then the documentation will not be installed.
328 </para>
329
330 <para>
331 <option>CCARGS="-DNO_EAI ..."</option>: this will turn off SMTPUTF8
332 support, for example if the rest of your email address infrastructure
333 cannot handle UTF-8 email addresses and message header values.
334 </para>
335
336 </sect2>
337
338 <sect2 role="configuration">
339 <title>Configuring Postfix</title>
340
341 <sect3 id="postfix-config">
342 <title>Config Files</title>
343
344 <para>
345 <filename>/etc/aliases</filename>,
346 <filename>/etc/postfix/main.cf</filename>, and
347 <filename>/etc/postfix/master.cf</filename>
348 </para>
349
350 <indexterm zone="postfix postfix-config">
351 <primary sortas="e-etc-aliases">/etc/aliases</primary>
352 </indexterm>
353
354 <indexterm zone="postfix postfix-config">
355 <primary sortas="e-etc-postfix-star">/etc/postfix/*</primary>
356 </indexterm>
357
358 </sect3>
359
360 <sect3>
361 <title>Configuration Information</title>
362
363 <para>
364 Create (or append to an existing) <filename>/etc/aliases</filename>
365 with the following command. Change
366 <replaceable>&lt;LOGIN&gt;</replaceable> to your non-root login
367 identity so mail addressed to
368 <systemitem class="username">root</systemitem> can be forwarded to you.
369 As the <systemitem class="username">root</systemitem> user:
370 </para>
371
372<screen role="root"><userinput>cat &gt;&gt; /etc/aliases &lt;&lt; "EOF"
373<literal># Begin /etc/aliases
374
375MAILER-DAEMON: postmaster
376postmaster: root
377
378root: <replaceable>&lt;LOGIN&gt;</replaceable>
379# End /etc/aliases</literal>
380EOF</userinput></screen>
381
382 <para>
383 To protect an existing <filename>/etc/aliases</filename> file,
384 the above command appends these aliases to it if it exists. This file
385 should be checked and duplicate aliases removed, if present.
386 </para>
387
388 <note>
389 <para>
390 The <filename>/etc/postfix/main.cf</filename> and
391 <filename>/etc/postfix/master.cf</filename> files must be personalized
392 for your system. The <filename>main.cf</filename> file needs your
393 fully qualified hostname. You will find that
394 <filename>main.cf</filename> is self documenting, so load it into your
395 editor to make the changes you need for your situation.
396 </para>
397 </note>
398
399 <note>
400 <para>
401 <application>Postfix</application> can also be set up to
402 run in a chroot jail. See the file in the source
403 <filename>examples/chroot-setup/LINUX2</filename> for details.
404 </para>
405 </note>
406
407 <para>
408 If you have an existing configuration, you can run the
409 <command>postfix</command> utility to add any necessary definitions to
410 your existing files. As the
411 <systemitem class="username">root</systemitem> user:
412 </para>
413
414<screen role="root"><userinput>/usr/sbin/postfix upgrade-configuration</userinput></screen>
415
416 <para>
417 Before starting <application>Postfix</application>, you should check
418 that your configuration and file permissions will work properly. Run the
419 following commands as the <systemitem class="username">root</systemitem>
420 user to check and start your <application>Postfix</application> server:
421 </para>
422
423<screen role="root"><userinput>/usr/sbin/postfix check &amp;&amp;
424/usr/sbin/postfix start</userinput></screen>
425
426 </sect3>
427
428 <sect3 id="postfix-init">
429 <title><phrase revision="sysv">Boot Script</phrase>
430 <phrase revision="systemd">Systemd Unit</phrase></title>
431
432 <para>
433 To automate the running of Postfix at startup, install the
434 <phrase revision="sysv"><filename>/etc/rc.d/init.d/postfix</filename>
435 init script</phrase>
436 <phrase revision="systemd"><filename>postfix.service</filename>
437 unit</phrase> included in the
438 <xref linkend="bootscripts" revision="sysv"/>
439 <xref linkend="systemd-units" revision="systemd"/> package:
440 </para>
441
442 <indexterm zone="postfix postfix-init">
443 <primary sortas="f-postfix">postfix</primary>
444 </indexterm>
445
446<screen role="root"><userinput>make install-postfix</userinput></screen>
447
448 </sect3>
449
450 </sect2>
451
452 <sect2 role="content">
453 <title>Contents</title>
454
455 <segmentedlist>
456 <segtitle>Installed Programs</segtitle>
457 <segtitle>Installed Libraries</segtitle>
458 <segtitle>Installed Directories</segtitle>
459
460 <seglistitem>
461 <seg>
462 mailq (symlink), newaliases (symlink), postalias, postcat, postconf,
463 postdrop, postfix, postkick, postlock, postlog, postmap, postmulti,
464 postqueue, postsuper, and sendmail
465 </seg>
466 <seg>
467 None
468 </seg>
469 <seg>
470 /{etc,usr/lib}/postfix,
471 /usr/share/doc/postfix-&postfix-version; and
472 /var/{lib,spool}/postfix
473 </seg>
474 </seglistitem>
475 </segmentedlist>
476
477 <variablelist>
478 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
479 <?dbfo list-presentation="list"?>
480 <?dbhtml list-presentation="table"?>
481
482 <varlistentry id="mailq">
483 <term><command>mailq</command></term>
484 <listitem>
485 <para>
486 A symlink to <filename>sendmail</filename>
487 </para>
488 <indexterm zone="postfix mailq">
489 <primary sortas="b-mailq">mailq</primary>
490 </indexterm>
491 </listitem>
492 </varlistentry>
493
494 <varlistentry id="newaliases">
495 <term><command>newaliases</command></term>
496 <listitem>
497 <para>
498 A symlink to <filename>sendmail</filename>
499 </para>
500 <indexterm zone="postfix newaliases">
501 <primary sortas="b-newaliases">newaliases</primary>
502 </indexterm>
503 </listitem>
504 </varlistentry>
505
506 <varlistentry id="postalias">
507 <term><command>postalias</command></term>
508 <listitem>
509 <para>
510 is a utility for <application>Postfix</application> alias database
511 maintenance
512 </para>
513 <indexterm zone="postfix postalias">
514 <primary sortas="b-postalias">postalias</primary>
515 </indexterm>
516 </listitem>
517 </varlistentry>
518
519 <varlistentry id="postcat">
520 <term><command>postcat</command></term>
521 <listitem>
522 <para>
523 Prints the contents of files from the
524 <application>Postfix</application> queue in human readable format
525 </para>
526 <indexterm zone="postfix postcat">
527 <primary sortas="b-postcat">postcat</primary>
528 </indexterm>
529 </listitem>
530 </varlistentry>
531
532 <varlistentry id="postconf">
533 <term><command>postconf</command></term>
534 <listitem>
535 <para>
536 Displays or changes the value of
537 <application>Postfix</application> configuration parameters
538 </para>
539 <indexterm zone="postfix postconf">
540 <primary sortas="b-postconf">postconf</primary>
541 </indexterm>
542 </listitem>
543 </varlistentry>
544
545 <varlistentry id="postdrop">
546 <term><command>postdrop</command></term>
547 <listitem>
548 <para>
549 Creates a file in the maildrop directory and copies its standard
550 input to the file
551 </para>
552 <indexterm zone="postfix postdrop">
553 <primary sortas="b-postdrop">postdrop</primary>
554 </indexterm>
555 </listitem>
556 </varlistentry>
557
558 <varlistentry id="postfix-bin">
559 <term><command>postfix</command></term>
560 <listitem>
561 <para>
562 is the <application>Postfix</application> control program
563 </para>
564 <indexterm zone="postfix postfix-bin">
565 <primary sortas="b-postfix">postfix</primary>
566 </indexterm>
567 </listitem>
568 </varlistentry>
569
570 <varlistentry id="postkick">
571 <term><command>postkick</command></term>
572 <listitem>
573 <para>
574 Sends requests to the specified service over a local transport
575 channel
576 </para>
577 <indexterm zone="postfix postkick">
578 <primary sortas="b-postkick">postkick</primary>
579 </indexterm>
580 </listitem>
581 </varlistentry>
582
583 <varlistentry id="postlock">
584 <term><command>postlock</command></term>
585 <listitem>
586 <para>
587 Locks a mail folder for exclusive use, and executes commands passed
588 to it
589 </para>
590 <indexterm zone="postfix postlock">
591 <primary sortas="b-postlock">postlock</primary>
592 </indexterm>
593 </listitem>
594 </varlistentry>
595
596 <varlistentry id="postlog">
597 <term><command>postlog</command></term>
598 <listitem>
599 <para>
600 A <application>Postfix</application>-compatible logging interface
601 for use in, for example, shell scripts
602 </para>
603 <indexterm zone="postfix postlog">
604 <primary sortas="b-postlog">postlog</primary>
605 </indexterm>
606 </listitem>
607 </varlistentry>
608
609 <varlistentry id="postmap">
610 <term><command>postmap</command></term>
611 <listitem>
612 <para>
613 Creates or queries one or more Postfix lookup tables, or updates an
614 existing one
615 </para>
616 <indexterm zone="postfix postmap">
617 <primary sortas="b-postmap">postmap</primary>
618 </indexterm>
619 </listitem>
620 </varlistentry>
621
622 <varlistentry id="postmulti">
623 <term><command>postmulti</command></term>
624 <listitem>
625 <para>
626 is the <application>Postfix</application> multi-instance manager.
627 It allows a system administrator to manage multiple
628 <application>Postfix</application> instances on a single host
629 </para>
630 <indexterm zone="postfix postmulti">
631 <primary sortas="b-postmulti">postmulti</primary>
632 </indexterm>
633 </listitem>
634 </varlistentry>
635
636 <varlistentry id="postqueue">
637 <term><command>postqueue</command></term>
638 <listitem>
639 <para>
640 The <application>Postfix</application> user interface for
641 queue management
642 </para>
643 <indexterm zone="postfix postqueue">
644 <primary sortas="b-postqueue">postqueue</primary>
645 </indexterm>
646 </listitem>
647 </varlistentry>
648
649 <varlistentry id="postsuper">
650 <term><command>postsuper</command></term>
651 <listitem>
652 <para>
653 The <application>Postfix</application> user interface for
654 superuser queue management
655 </para>
656 <indexterm zone="postfix postsuper">
657 <primary sortas="b-postsuper">postsuper</primary>
658 </indexterm>
659 </listitem>
660 </varlistentry>
661
662 <varlistentry id="sendmail-postfix">
663 <term><command>sendmail</command></term>
664 <listitem>
665 <para>
666 is the <application>Postfix</application> to
667 <application>Sendmail</application> compatibility interface
668 </para>
669 <indexterm zone="postfix sendmail-postfix">
670 <primary sortas="b-sendmail">sendmail</primary>
671 </indexterm>
672 </listitem>
673 </varlistentry>
674
675 </variablelist>
676
677 </sect2>
678
679</sect1>
Note: See TracBrowser for help on using the repository browser.