source: server/mail/postfix.xml@ 1895c55

11.1 11.2 11.3 12.0 12.1 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 1895c55 was 1895c55, checked in by Bruce Dubbs <bdubbs@…>, 2 years ago

Package updates.
Update to gdb-11.2.
Update to cups-filters-1.28.11.
Update to postfix-3.6.4.

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