2
0
mirror of https://github.com/vdukhovni/postfix synced 2025-08-31 14:17:41 +00:00

postfix-3.3-20171221

This commit is contained in:
Wietse Venema
2017-12-21 00:00:00 -05:00
committed by Viktor Dukhovni
parent 17d5f8949c
commit 0caa1bf9cc
7 changed files with 103 additions and 61 deletions

View File

@@ -23198,9 +23198,16 @@ Apologies for any names omitted.
20171218
Workaround: reportedly, FreeBSD 11.1 res_query(3) can return
-1 while h_errno==0. The DNS client now logs a warning and
sets h_errno to TRY_AGAIN. File: dns/dns_lookup.c.
Workaround: reportedly, some res_query(3) implementation
can return -1 with h_errno==0. Instead of terminating with
a panic, the DNS client now logs a warning and sets h_errno
to TRY_AGAIN. File: dns/dns_lookup.c.
Cleanup: allow XCLIENT before STARTTLS, when TLS is required.
File: smtpd/smtpd.c.
20171219
Feature: preliminary support to run Postfix in the foreground.
This requires that multi-instance support is disabled.
Files: conf/postfix-script, postfix/postfix.c.

View File

@@ -117,7 +117,7 @@ stop_msg)
echo "Stop postfix"
;;
start)
start|start-fg)
$daemon_directory/master -t 2>/dev/null || {
$FATAL the Postfix mail system is already running
@@ -135,11 +135,28 @@ start)
$daemon_directory/postfix-script check-warn
fi
$INFO starting the Postfix mail system
# NOTE: wait in foreground process to get the initialization status.
$daemon_directory/master -w || {
$FATAL "mail system startup failed"
exit 1
}
case $1 in
start)
# NOTE: wait in foreground process to get the initialization status.
$daemon_directory/master -w || {
$FATAL "mail system startup failed"
exit 1
}
;;
start-fg)
# Foreground start-up is incompatible with multi-instance mode.
# We can't use "exec $daemon_directory/master" here: that would
# break process group management, and "postfix stop" would kill
# too many processes.
case $instances in
"") $daemon_directory/master
;;
*) $FATAL "start-fg does not support multi_instance_directories"
exit 1
;;
esac
;;
esac
;;
drain)

View File

@@ -36,92 +36,97 @@ POSTFIX(1) POSTFIX(1)
<b>start</b> Start the Postfix mail system. This also runs the configuration
check described above.
<b>start-fg</b>
Like <b>start</b>, but keep the master daemon running in the fore-
ground. This requires that multi-instance support is disabled
(i.e. the <a href="postconf.5.html#multi_instance_directories">multi_instance_directories</a> parameter value is empty).
<b>stop</b> Stop the Postfix mail system in an orderly fashion. If possible,
running processes are allowed to terminate at their earliest
running processes are allowed to terminate at their earliest
convenience.
Note: in order to refresh the Postfix mail system after a con-
figuration change, do not use the <b>start</b> and <b>stop</b> commands in
Note: in order to refresh the Postfix mail system after a con-
figuration change, do not use the <b>start</b> and <b>stop</b> commands in
succession. Use the <b>reload</b> command instead.
<b>abort</b> Stop the Postfix mail system abruptly. Running processes are
<b>abort</b> Stop the Postfix mail system abruptly. Running processes are
signaled to stop immediately.
<b>flush</b> Force delivery: attempt to deliver every message in the deferred
mail queue. Normally, attempts to deliver delayed mail happen at
regular intervals, the interval doubling after each failed
regular intervals, the interval doubling after each failed
attempt.
Warning: flushing undeliverable mail frequently will result in
Warning: flushing undeliverable mail frequently will result in
poor delivery performance of all other mail.
<b>reload</b> Re-read configuration files. Running processes terminate at
<b>reload</b> Re-read configuration files. Running processes terminate at
their earliest convenience.
<b>status</b> Indicate if the Postfix mail system is currently running.
<b>set-permissions</b> [<i>name</i>=<i>value ...</i>]
Set the ownership and permissions of Postfix related files and
Set the ownership and permissions of Postfix related files and
directories, as specified in the <b>postfix-files</b> file.
Specify <i>name</i>=<i>value</i> to override and update specific <a href="postconf.5.html">main.cf</a> con-
figuration parameters. Use this, for example, to change the
<b><a href="postconf.5.html#mail_owner">mail_owner</a></b> or <b><a href="postconf.5.html#setgid_group">setgid_group</a></b> setting for an already installed
Specify <i>name</i>=<i>value</i> to override and update specific <a href="postconf.5.html">main.cf</a> con-
figuration parameters. Use this, for example, to change the
<b><a href="postconf.5.html#mail_owner">mail_owner</a></b> or <b><a href="postconf.5.html#setgid_group">setgid_group</a></b> setting for an already installed
Postfix system.
This feature is available in Postfix 2.1 and later. With Post-
fix 2.0 and earlier, use "<b>$<a href="postconf.5.html#config_directory">config_directory</a>/post-install</b>
This feature is available in Postfix 2.1 and later. With Post-
fix 2.0 and earlier, use "<b>$<a href="postconf.5.html#config_directory">config_directory</a>/post-install</b>
<b>set-permissions</b>".
<b>tls</b> <i>subcommand</i>
Enable opportunistic TLS in the Postfix SMTP client or server,
and manage Postfix SMTP server TLS private keys and certifi-
Enable opportunistic TLS in the Postfix SMTP client or server,
and manage Postfix SMTP server TLS private keys and certifi-
cates. See <a href="postfix-tls.1.html">postfix-tls(1)</a> for documentation.
This feature is available in Postfix 3.1 and later.
<b>upgrade-configuration</b> [<i>name</i>=<i>value ...</i>]
Update the <a href="postconf.5.html"><b>main.cf</b></a> and <a href="master.5.html"><b>master.cf</b></a> files with information that
Postfix needs in order to run: add or update services, and add
Update the <a href="postconf.5.html"><b>main.cf</b></a> and <a href="master.5.html"><b>master.cf</b></a> files with information that
Postfix needs in order to run: add or update services, and add
or update configuration parameter settings.
Specify <i>name</i>=<i>value</i> to override and update specific <a href="postconf.5.html">main.cf</a> con-
Specify <i>name</i>=<i>value</i> to override and update specific <a href="postconf.5.html">main.cf</a> con-
figuration parameters.
This feature is available in Postfix 2.1 and later. With Post-
fix 2.0 and earlier, use "<b>$<a href="postconf.5.html#config_directory">config_directory</a>/post-install</b>
This feature is available in Postfix 2.1 and later. With Post-
fix 2.0 and earlier, use "<b>$<a href="postconf.5.html#config_directory">config_directory</a>/post-install</b>
<b>upgrade-configuration</b>".
The following options are implemented:
<b>-c</b> <i>config</i><b>_</b><i>dir</i>
Read the <a href="postconf.5.html"><b>main.cf</b></a> and <a href="master.5.html"><b>master.cf</b></a> configuration files in the named
directory instead of the default configuration directory. Use
this to distinguish between multiple Postfix instances on the
Read the <a href="postconf.5.html"><b>main.cf</b></a> and <a href="master.5.html"><b>master.cf</b></a> configuration files in the named
directory instead of the default configuration directory. Use
this to distinguish between multiple Postfix instances on the
same host.
With Postfix 2.6 and later, this option forces the <a href="postfix.1.html">postfix(1)</a>
With Postfix 2.6 and later, this option forces the <a href="postfix.1.html">postfix(1)</a>
command to operate on the specified Postfix instance only. This
behavior is inherited by <a href="postfix.1.html">postfix(1)</a> commands that run as a
behavior is inherited by <a href="postfix.1.html">postfix(1)</a> commands that run as a
descendant of the current process.
<b>-D</b> (with <b>postfix start</b> only)
Run each Postfix daemon under control of a debugger as specified
via the <b><a href="postconf.5.html#debugger_command">debugger_command</a></b> configuration parameter.
<b>-v</b> Enable verbose logging for debugging purposes. Multiple <b>-v</b>
<b>-v</b> Enable verbose logging for debugging purposes. Multiple <b>-v</b>
options make the software increasingly verbose.
<b>ENVIRONMENT</b>
The <a href="postfix.1.html"><b>postfix</b>(1)</a> command exports the following environment variables
The <a href="postfix.1.html"><b>postfix</b>(1)</a> command exports the following environment variables
before executing the <b>postfix-script</b> file:
<b>MAIL_CONFIG</b>
This is set when the -c command-line option is present.
With Postfix 2.6 and later, this environment variable forces the
<a href="postfix.1.html">postfix(1)</a> command to operate on the specified Postfix instance
only. This behavior is inherited by <a href="postfix.1.html">postfix(1)</a> commands that
<a href="postfix.1.html">postfix(1)</a> command to operate on the specified Postfix instance
only. This behavior is inherited by <a href="postfix.1.html">postfix(1)</a> commands that
run as a descendant of the current process.
<b>MAIL_VERBOSE</b>
@@ -135,7 +140,7 @@ POSTFIX(1) POSTFIX(1)
ment variables with the same names:
<b><a href="postconf.5.html#config_directory">config_directory</a> (see 'postconf -d' output)</b>
The default location of the Postfix <a href="postconf.5.html">main.cf</a> and <a href="master.5.html">master.cf</a> con-
The default location of the Postfix <a href="postconf.5.html">main.cf</a> and <a href="master.5.html">master.cf</a> con-
figuration files.
<b><a href="postconf.5.html#command_directory">command_directory</a> (see 'postconf -d' output)</b>
@@ -145,22 +150,22 @@ POSTFIX(1) POSTFIX(1)
The directory with Postfix support programs and daemon programs.
<b><a href="postconf.5.html#html_directory">html_directory</a> (see 'postconf -d' output)</b>
The location of Postfix HTML files that describe how to build,
The location of Postfix HTML files that describe how to build,
configure or operate a specific Postfix subsystem or feature.
<b><a href="postconf.5.html#mail_owner">mail_owner</a> (postfix)</b>
The UNIX system account that owns the Postfix queue and most
The UNIX system account that owns the Postfix queue and most
Postfix daemon processes.
<b><a href="postconf.5.html#mailq_path">mailq_path</a> (see 'postconf -d' output)</b>
Sendmail compatibility feature that specifies where the Postfix
Sendmail compatibility feature that specifies where the Postfix
<a href="mailq.1.html"><b>mailq</b>(1)</a> command is installed.
<b><a href="postconf.5.html#manpage_directory">manpage_directory</a> (see 'postconf -d' output)</b>
Where the Postfix manual pages are installed.
<b><a href="postconf.5.html#newaliases_path">newaliases_path</a> (see 'postconf -d' output)</b>
Sendmail compatibility feature that specifies the location of
Sendmail compatibility feature that specifies the location of
the <a href="newaliases.1.html"><b>newaliases</b>(1)</a> command.
<b><a href="postconf.5.html#queue_directory">queue_directory</a> (see 'postconf -d' output)</b>
@@ -171,31 +176,31 @@ POSTFIX(1) POSTFIX(1)
configure or operate a specific Postfix subsystem or feature.
<b><a href="postconf.5.html#sendmail_path">sendmail_path</a> (see 'postconf -d' output)</b>
A Sendmail compatibility feature that specifies the location of
A Sendmail compatibility feature that specifies the location of
the Postfix <a href="sendmail.1.html"><b>sendmail</b>(1)</a> command.
<b><a href="postconf.5.html#setgid_group">setgid_group</a> (postdrop)</b>
The group ownership of set-gid Postfix commands and of
The group ownership of set-gid Postfix commands and of
group-writable Postfix directories.
Available in Postfix version 2.5 and later:
<b><a href="postconf.5.html#data_directory">data_directory</a> (see 'postconf -d' output)</b>
The directory with Postfix-writable data files (for example:
The directory with Postfix-writable data files (for example:
caches, pseudo-random numbers).
Available in Postfix version 3.0 and later:
<b><a href="postconf.5.html#meta_directory">meta_directory</a> (see 'postconf -d' output)</b>
The location of non-executable files that are shared among mul-
tiple Postfix instances, such as postfix-files, dynamicmaps.cf,
and the multi-instance template files <a href="postconf.5.html">main.cf</a>.proto and <a href="master.5.html">mas-
The location of non-executable files that are shared among mul-
tiple Postfix instances, such as postfix-files, dynamicmaps.cf,
and the multi-instance template files <a href="postconf.5.html">main.cf</a>.proto and <a href="master.5.html">mas-
ter.cf</a>.proto.
<b><a href="postconf.5.html#shlib_directory">shlib_directory</a> (see 'postconf -d' output)</b>
The location of Postfix dynamically-linked libraries (libpost-
fix-*.so), and the default location of Postfix database plugins
(postfix-*.so) that have a relative pathname in the dynam-
The location of Postfix dynamically-linked libraries (libpost-
fix-*.so), and the default location of Postfix database plugins
(postfix-*.so) that have a relative pathname in the dynam-
icmaps.cf file.
Available in Postfix version 3.1 and later:
@@ -206,8 +211,9 @@ POSTFIX(1) POSTFIX(1)
Other configuration parameters:
<b><a href="postconf.5.html#import_environment">import_environment</a> (see 'postconf -d' output)</b>
The list of environment parameters that a Postfix process will
import from a non-Postfix parent process.
The list of environment parameters that a privileged Postfix
process will import from a non-Postfix parent process, or
name=value environment overrides.
<b><a href="postconf.5.html#syslog_facility">syslog_facility</a> (mail)</b>
The syslog facility of Postfix logging.

View File

@@ -37,6 +37,11 @@ and create missing directories.
.IP \fBstart\fR
Start the Postfix mail system. This also runs the configuration
check described above.
.IP \fBstart\-fg\fR
Like \fBstart\fR, but keep the master daemon running in the
foreground. This requires that multi\-instance support is
disabled (i.e. the multi_instance_directories parameter
value is empty).
.IP \fBstop\fR
Stop the Postfix mail system in an orderly fashion. If
possible, running processes are allowed to terminate at
@@ -187,8 +192,9 @@ The location of the OpenSSL command line program \fBopenssl\fR(1).
.PP
Other configuration parameters:
.IP "\fBimport_environment (see 'postconf -d' output)\fR"
The list of environment parameters that a Postfix process will
import from a non\-Postfix parent process.
The list of environment parameters that a privileged Postfix
process will import from a non\-Postfix parent process, or name=value
environment overrides.
.IP "\fBsyslog_facility (mail)\fR"
The syslog facility of Postfix logging.
.IP "\fBsyslog_name (see 'postconf -d' output)\fR"

View File

@@ -397,14 +397,14 @@ static int dns_res_search(const char *name, int class, int type,
/* Prepare for returning a null-padded server reply. */
memset(answer, 0, anslen);
len = res_query(name, class, type, answer, anslen);
/* Begin FreeBSD 11.1 workaround. */
/* Begin API creep workaround. */
if (len < 0 && h_errno == 0) {
SET_H_ERRNO(TRY_AGAIN);
msg_warn("res_query(\"%s\", %d, %d, %p, %d) returns %d with h_errno==0"
" -- setting h_errno=TRY_AGAIN",
name, class, type, answer, anslen, len);
}
/* End FreeBSD 11.1 workaround. */
/* End API creep workaround. */
if (len > 0) {
SET_H_ERRNO(0);
} else if (keep_notfound && NOT_FOUND_H_ERRNO(h_errno)) {

View File

@@ -20,7 +20,7 @@
* Patches change both the patchlevel and the release date. Snapshots have no
* patchlevel; they change the release date only.
*/
#define MAIL_RELEASE_DATE "20171218"
#define MAIL_RELEASE_DATE "20171221"
#define MAIL_VERSION_NUMBER "3.3"
#ifdef SNAPSHOT

View File

@@ -31,6 +31,11 @@
/* .IP \fBstart\fR
/* Start the Postfix mail system. This also runs the configuration
/* check described above.
/* .IP \fBstart-fg\fR
/* Like \fBstart\fR, but keep the master daemon running in the
/* foreground. This requires that multi-instance support is
/* disabled (i.e. the multi_instance_directories parameter
/* value is empty).
/* .IP \fBstop\fR
/* Stop the Postfix mail system in an orderly fashion. If
/* possible, running processes are allowed to terminate at
@@ -177,8 +182,9 @@
/* .PP
/* Other configuration parameters:
/* .IP "\fBimport_environment (see 'postconf -d' output)\fR"
/* The list of environment parameters that a Postfix process will
/* import from a non-Postfix parent process.
/* The list of environment parameters that a privileged Postfix
/* process will import from a non-Postfix parent process, or name=value
/* environment overrides.
/* .IP "\fBsyslog_facility (mail)\fR"
/* The syslog facility of Postfix logging.
/* .IP "\fBsyslog_name (see 'postconf -d' output)\fR"