1POSTFIX(1) General Commands Manual POSTFIX(1)
2
3
4
6 postfix - Postfix control program
7
9 postfix [-Dv] [-c config_dir] command
10
12 This command is reserved for the superuser. To submit mail, use the
13 Postfix sendmail(1) command.
14
15 The postfix(1) command controls the operation of the Postfix mail sys‐
16 tem: start or stop the master(8) daemon, do a health check, and other
17 maintenance.
18
19 By default, the postfix(1) command sets up a standardized environment
20 and runs the postfix-script shell script to do the actual work.
21
22 However, when support for multiple Postfix instances is configured,
23 postfix(1) executes the command specified with the multi_instance_wrap‐
24 per configuration parameter. This command will execute the command for
25 each applicable Postfix instance.
26
27 The following commands are implemented:
28
29 check Warn about bad directory/file ownership or permissions, and cre‐
30 ate missing directories.
31
32 start Start the Postfix mail system. This also runs the configuration
33 check described above.
34
35 stop Stop the Postfix mail system in an orderly fashion. If possible,
36 running processes are allowed to terminate at their earliest
37 convenience.
38
39 Note: in order to refresh the Postfix mail system after a con‐
40 figuration change, do not use the start and stop commands in
41 succession. Use the reload command instead.
42
43 abort Stop the Postfix mail system abruptly. Running processes are
44 signaled to stop immediately.
45
46 flush Force delivery: attempt to deliver every message in the deferred
47 mail queue. Normally, attempts to deliver delayed mail happen at
48 regular intervals, the interval doubling after each failed
49 attempt.
50
51 Warning: flushing undeliverable mail frequently will result in
52 poor delivery performance of all other mail.
53
54 reload Re-read configuration files. Running processes terminate at
55 their earliest convenience.
56
57 status Indicate if the Postfix mail system is currently running.
58
59 set-permissions [name=value ...]
60 Set the ownership and permissions of Postfix related files and
61 directories, as specified in the postfix-files file.
62
63 Specify name=value to override and update specific main.cf con‐
64 figuration parameters. Use this, for example, to change the
65 mail_owner or setgid_group setting for an already installed
66 Postfix system.
67
68 This feature is available in Postfix 2.1 and later. With Post‐
69 fix 2.0 and earlier, use "$config_directory/post-install set-
70 permissions".
71
72 upgrade-configuration [name=value ...]
73 Update the main.cf and master.cf files with information that
74 Postfix needs in order to run: add or update services, and add
75 or update configuration parameter settings.
76
77 Specify name=value to override and update specific main.cf con‐
78 figuration parameters.
79
80 This feature is available in Postfix 2.1 and later. With Post‐
81 fix 2.0 and earlier, use "$config_directory/post-install
82 upgrade-configuration".
83
84 The following options are implemented:
85
86 -c config_dir
87 Read the main.cf and master.cf configuration files in the named
88 directory instead of the default configuration directory. Use
89 this to distinguish between multiple Postfix instances on the
90 same host.
91
92 With Postfix 2.6 and later, this option forces the postfix(1)
93 command to operate on the specified Postfix instance only. This
94 behavior is inherited by postfix(1) commands that run as a
95 descendant of the current process.
96
97 -D (with postfix start only)
98 Run each Postfix daemon under control of a debugger as specified
99 via the debugger_command configuration parameter.
100
101 -v Enable verbose logging for debugging purposes. Multiple -v
102 options make the software increasingly verbose.
103
105 The postfix(1) command exports the following environment variables
106 before executing the postfix-script file:
107
108 MAIL_CONFIG
109 This is set when the -c command-line option is present.
110
111 With Postfix 2.6 and later, this environment variable forces the
112 postfix(1) command to operate on the specified Postfix instance
113 only. This behavior is inherited by postfix(1) commands that
114 run as a descendant of the current process.
115
116 MAIL_VERBOSE
117 This is set when the -v command-line option is present.
118
119 MAIL_DEBUG
120 This is set when the -D command-line option is present.
121
123 The following main.cf configuration parameters are exported as environ‐
124 ment variables with the same names:
125
126 command_directory (see 'postconf -d' output)
127 The location of all postfix administrative commands.
128
129 daemon_directory (see 'postconf -d' output)
130 The directory with Postfix support programs and daemon programs.
131
132 config_directory (see 'postconf -d' output)
133 The default location of the Postfix main.cf and master.cf con‐
134 figuration files.
135
136 queue_directory (see 'postconf -d' output)
137 The location of the Postfix top-level queue directory.
138
139 mail_owner (postfix)
140 The UNIX system account that owns the Postfix queue and most
141 Postfix daemon processes.
142
143 setgid_group (postdrop)
144 The group ownership of set-gid Postfix commands and of group-
145 writable Postfix directories.
146
147 sendmail_path (see 'postconf -d' output)
148 A Sendmail compatibility feature that specifies the location of
149 the Postfix sendmail(1) command.
150
151 newaliases_path (see 'postconf -d' output)
152 Sendmail compatibility feature that specifies the location of
153 the newaliases(1) command.
154
155 mailq_path (see 'postconf -d' output)
156 Sendmail compatibility feature that specifies where the Postfix
157 mailq(1) command is installed.
158
159 html_directory (see 'postconf -d' output)
160 The location of Postfix HTML files that describe how to build,
161 configure or operate a specific Postfix subsystem or feature.
162
163 manpage_directory (see 'postconf -d' output)
164 Where the Postfix manual pages are installed.
165
166 readme_directory (see 'postconf -d' output)
167 The location of Postfix README files that describe how to build,
168 configure or operate a specific Postfix subsystem or feature.
169
170 Available in Postfix version 2.5 and later:
171
172 data_directory (see 'postconf -d' output)
173 The directory with Postfix-writable data files (for example:
174 caches, pseudo-random numbers).
175
176 Other configuration parameters:
177
178 config_directory (see 'postconf -d' output)
179 The default location of the Postfix main.cf and master.cf con‐
180 figuration files.
181
182 import_environment (see 'postconf -d' output)
183 The list of environment parameters that a Postfix process will
184 import from a non-Postfix parent process.
185
186 syslog_facility (mail)
187 The syslog facility of Postfix logging.
188
189 syslog_name (see 'postconf -d' output)
190 The mail system name that is prepended to the process name in
191 syslog records, so that "smtpd" becomes, for example, "post‐
192 fix/smtpd".
193
194 Available in Postfix version 2.6 and later:
195
196 multi_instance_directories (empty)
197 An optional list of non-default Postfix configuration directo‐
198 ries; these directories belong to additional Postfix instances
199 that share the Postfix executable files and documentation with
200 the default Postfix instance, and that are started, stopped,
201 etc., together with the default Postfix instance.
202
203 multi_instance_wrapper (empty)
204 The pathname of a multi-instance manager command that the post‐
205 fix(1) command invokes when the multi_instance_directories
206 parameter value is non-empty.
207
208 multi_instance_group (empty)
209 The optional instance group name of this Postfix instance.
210
211 multi_instance_name (empty)
212 The optional instance name of this Postfix instance.
213
214 multi_instance_enable (no)
215 Allow this Postfix instance to be started, stopped, etc., by a
216 multi-instance manager.
217
219 Prior to Postfix version 2.6, all of the following files were in $con‐
220 fig_directory. Some files are now in $daemon_directory so that they can
221 be shared among multiple instances that run the same Postfix version.
222
223 Use the command "postconf config_directory" or "postconf daemon_direc‐
224 tory" to expand the names into their actual values.
225
226 $config_directory/main.cf, Postfix configuration parameters
227 $config_directory/master.cf, Postfix daemon processes
228 $daemon_directory/postfix-files, file/directory permissions
229 $daemon_directory/postfix-script, administrative commands
230 $daemon_directory/post-install, post-installation configuration
231
233 Commands:
234 postalias(1), create/update/query alias database
235 postcat(1), examine Postfix queue file
236 postconf(1), Postfix configuration utility
237 postfix(1), Postfix control program
238 postkick(1), trigger Postfix daemon
239 postlock(1), Postfix-compatible locking
240 postlog(1), Postfix-compatible logging
241 postmap(1), Postfix lookup table manager
242 postmulti(1), Postfix multi-instance manager
243 postqueue(1), Postfix mail queue control
244 postsuper(1), Postfix housekeeping
245 mailq(1), Sendmail compatibility interface
246 newaliases(1), Sendmail compatibility interface
247 sendmail(1), Sendmail compatibility interface
248
249 Postfix configuration:
250 bounce(5), Postfix bounce message templates
251 master(5), Postfix master.cf file syntax
252 postconf(5), Postfix main.cf file syntax
253 postfix-wrapper(5), Postfix multi-instance API
254
255 Table-driven mechanisms:
256 access(5), Postfix SMTP access control table
257 aliases(5), Postfix alias database
258 canonical(5), Postfix input address rewriting
259 generic(5), Postfix output address rewriting
260 header_checks(5), body_checks(5), Postfix content inspection
261 relocated(5), Users that have moved
262 transport(5), Postfix routing table
263 virtual(5), Postfix virtual aliasing
264
265 Table lookup mechanisms:
266 cidr_table(5), Associate CIDR pattern with value
267 ldap_table(5), Postfix LDAP client
268 mysql_table(5), Postfix MYSQL client
269 nisplus_table(5), Postfix NIS+ client
270 pcre_table(5), Associate PCRE pattern with value
271 pgsql_table(5), Postfix PostgreSQL client
272 regexp_table(5), Associate POSIX regexp pattern with value
273 tcp_table(5), Postfix client-server table lookup
274
275 Daemon processes:
276 anvil(8), Postfix connection/rate limiting
277 bounce(8), defer(8), trace(8), Delivery status reports
278 cleanup(8), canonicalize and enqueue message
279 discard(8), Postfix discard delivery agent
280 error(8), Postfix error delivery agent
281 flush(8), Postfix fast ETRN service
282 local(8), Postfix local delivery agent
283 master(8), Postfix master daemon
284 oqmgr(8), old Postfix queue manager
285 pickup(8), Postfix local mail pickup
286 pipe(8), deliver mail to non-Postfix command
287 proxymap(8), Postfix lookup table proxy server
288 qmgr(8), Postfix queue manager
289 qmqpd(8), Postfix QMQP server
290 scache(8), Postfix connection cache manager
291 showq(8), list Postfix mail queue
292 smtp(8), lmtp(8), Postfix SMTP+LMTP client
293 smtpd(8), Postfix SMTP server
294 spawn(8), run non-Postfix server
295 tlsmgr(8), Postfix TLS cache and randomness manager
296 trivial-rewrite(8), Postfix address rewriting
297 verify(8), Postfix address verification
298 virtual(8), Postfix virtual delivery agent
299
300 Other:
301 syslogd(8), system logging
302
304 Use "postconf readme_directory" or "postconf html_directory" to locate
305 this information.
306 OVERVIEW, overview of Postfix commands and processes
307 BASIC_CONFIGURATION_README, Postfix basic configuration
308 ADDRESS_REWRITING_README, Postfix address rewriting
309 SMTPD_ACCESS_README, SMTP relay/access control
310 CONTENT_INSPECTION_README, Postfix content inspection
311 QSHAPE_README, Postfix queue analysis
312
314 The Secure Mailer license must be distributed with this software.
315
317 Wietse Venema
318 IBM T.J. Watson Research
319 P.O. Box 704
320 Yorktown Heights, NY 10598, USA
321
322 TLS support by:
323 Lutz Jaenicke
324 Brandenburg University of Technology
325 Cottbus, Germany
326
327 Victor Duchovni
328 Morgan Stanley
329
330 SASL support originally by:
331 Till Franke
332 SuSE Rhein/Main AG
333 65760 Eschborn, Germany
334
335 LMTP support originally by:
336 Philip A. Prindeville
337 Mirapoint, Inc.
338 USA.
339
340 Amos Gouaux
341 University of Texas at Dallas
342 P.O. Box 830688, MC34
343 Richardson, TX 75083, USA
344
345 IPv6 support originally by:
346 Mark Huizer, Eindhoven University, The Netherlands
347 Jun-ichiro 'itojun' Hagino, KAME project, Japan
348 The Linux PLD project
349 Dean Strik, Eindhoven University, The Netherlands
350
351
352
353 POSTFIX(1)