1SENDMAIL(1) General Commands Manual SENDMAIL(1)
2
3
4
6 sendmail - Postfix to Sendmail compatibility interface
7
9 sendmail [option ...] [recipient ...]
10
11 mailq
12 sendmail -bp
13
14 newaliases
15 sendmail -I
16
18 The Postfix sendmail(1) command implements the Postfix to Sendmail com‐
19 patibility interface. For the sake of compatibility with existing
20 applications, some Sendmail command-line options are recognized but
21 silently ignored.
22
23 By default, Postfix sendmail(1) reads a message from standard input
24 until EOF or until it reads a line with only a . character, and
25 arranges for delivery. Postfix sendmail(1) relies on the postdrop(1)
26 command to create a queue file in the maildrop directory.
27
28 Specific command aliases are provided for other common modes of opera‐
29 tion:
30
31 mailq List the mail queue. Each entry shows the queue file ID, message
32 size, arrival time, sender, and the recipients that still need
33 to be delivered. If mail could not be delivered upon the last
34 attempt, the reason for failure is shown. The queue ID string is
35 followed by an optional status character:
36
37 * The message is in the active queue, i.e. the message is
38 selected for delivery.
39
40 ! The message is in the hold queue, i.e. no further deliv‐
41 ery attempt will be made until the mail is taken off
42 hold.
43
44 This mode of operation is implemented by executing the
45 postqueue(1) command.
46
47 newaliases
48 Initialize the alias database. If no input file is specified
49 (with the -oA option, see below), the program processes the
50 file(s) specified with the alias_database configuration parame‐
51 ter. If no alias database type is specified, the program uses
52 the type specified with the default_database_type configuration
53 parameter. This mode of operation is implemented by running the
54 postalias(1) command.
55
56 Note: it may take a minute or so before an alias database update
57 becomes visible. Use the "postfix reload" command to eliminate
58 this delay.
59
60 These and other features can be selected by specifying the appropriate
61 combination of command-line options. Some features are controlled by
62 parameters in the main.cf configuration file.
63
64 The following options are recognized:
65
66 -Am (ignored)
67
68 -Ac (ignored)
69 Postfix sendmail uses the same configuration file regardless of
70 whether or not a message is an initial submission.
71
72 -B body_type
73 The message body MIME type: 7BIT or 8BITMIME.
74
75 -bd Go into daemon mode. This mode of operation is implemented by
76 executing the "postfix start" command.
77
78 -bh (ignored)
79
80 -bH (ignored)
81 Postfix has no persistent host status database.
82
83 -bi Initialize alias database. See the newaliases command above.
84
85 -bl Go into daemon mode. To accept only local connections as with
86 Sendmail´s -bl option, specify "inet_interfaces = loopback" in
87 the Postfix main.cf configuration file.
88
89 -bm Read mail from standard input and arrange for delivery. This is
90 the default mode of operation.
91
92 -bp List the mail queue. See the mailq command above.
93
94 -bs Stand-alone SMTP server mode. Read SMTP commands from standard
95 input, and write responses to standard output. In stand-alone
96 SMTP server mode, mail relaying and other access controls are
97 disabled by default. To enable them, run the process as the
98 mail_owner user.
99
100 This mode of operation is implemented by running the smtpd(8)
101 daemon.
102
103 -bv Do not collect or deliver a message. Instead, send an email
104 report after verifying each recipient address. This is useful
105 for testing address rewriting and routing configurations.
106
107 This feature is available in Postfix version 2.1 and later.
108
109 -C config_file
110
111 -C config_dir
112 The path name of the Postfix main.cf file, or of its parent
113 directory. This information is ignored with Postfix versions
114 before 2.3.
115
116 With all Postfix versions, you can specify a directory pathname
117 with the MAIL_CONFIG environment variable to override the loca‐
118 tion of configuration files.
119
120 -F full_name
121 Set the sender full name. This overrides the NAME environment
122 variable, and is used only with messages that have no From: mes‐
123 sage header.
124
125 -f sender
126 Set the envelope sender address. This is the address where
127 delivery problems are sent to. With Postfix versions before 2.1,
128 the Errors-To: message header overrides the error return
129 address.
130
131 -G Gateway (relay) submission, as opposed to initial user submis‐
132 sion. Either do not rewrite addresses at all, or update incom‐
133 plete addresses with the domain information specified with
134 remote_header_rewrite_domain.
135
136 This option is ignored before Postfix version 2.3.
137
138 -h hop_count (ignored)
139 Hop count limit. Use the hopcount_limit configuration parameter
140 instead.
141
142 -I Initialize alias database. See the newaliases command above.
143
144 -i When reading a message from standard input, don´t treat a line
145 with only a . character as the end of input.
146
147 -L label (ignored)
148 The logging label. Use the syslog_name configuration parameter
149 instead.
150
151 -m (ignored)
152 Backwards compatibility.
153
154 -N dsn (default: 'delay, failure')
155 Delivery status notification control. Specify either a comma-
156 separated list with one or more of failure (send notification
157 when delivery fails), delay (send notification when delivery is
158 delayed), or success (send notification when the message is
159 delivered); or specify never (don't send any notifications at
160 all).
161
162 This feature is available in Postfix 2.3 and later.
163
164 -n (ignored)
165 Backwards compatibility.
166
167 -oAalias_database
168 Non-default alias database. Specify pathname or type:pathname.
169 See postalias(1) for details.
170
171 -O option=value (ignored)
172 Set the named option to value. Use the equivalent configuration
173 parameter in main.cf instead.
174
175 -o7 (ignored)
176
177 -o8 (ignored)
178 To send 8-bit or binary content, use an appropriate MIME encap‐
179 sulation and specify the appropriate -B command-line option.
180
181 -oi When reading a message from standard input, don´t treat a line
182 with only a . character as the end of input.
183
184 -om (ignored)
185 The sender is never eliminated from alias etc. expansions.
186
187 -o x value (ignored)
188 Set option x to value. Use the equivalent configuration parame‐
189 ter in main.cf instead.
190
191 -r sender
192 Set the envelope sender address. This is the address where
193 delivery problems are sent to. With Postfix versions before 2.1,
194 the Errors-To: message header overrides the error return
195 address.
196
197 -R return
198 Delivery status notification control. Specify "hdrs" to return
199 only the header when a message bounces, "full" to return a full
200 copy (the default behavior).
201
202 The -R option specifies an upper bound; Postfix will return only
203 the header, when a full copy would exceed the bounce_size_limit
204 setting.
205
206 This option is ignored before Postfix version 2.10.
207
208 -q Attempt to deliver all queued mail. This is implemented by exe‐
209 cuting the postqueue(1) command.
210
211 Warning: flushing undeliverable mail frequently will result in
212 poor delivery performance of all other mail.
213
214 -qinterval (ignored)
215 The interval between queue runs. Use the queue_run_delay config‐
216 uration parameter instead.
217
218 -qIqueueid
219 Schedule immediate delivery of mail with the specified queue ID.
220 This option is implemented by executing the postqueue(1) com‐
221 mand, and is available with Postfix version 2.4 and later.
222
223 -qRsite
224 Schedule immediate delivery of all mail that is queued for the
225 named site. This option accepts only site names that are eligi‐
226 ble for the "fast flush" service, and is implemented by execut‐
227 ing the postqueue(1) command. See flush(8) for more information
228 about the "fast flush" service.
229
230 -qSsite
231 This command is not implemented. Use the slower "sendmail -q"
232 command instead.
233
234 -t Extract recipients from message headers. These are added to any
235 recipients specified on the command line.
236
237 With Postfix versions prior to 2.1, this option requires that no
238 recipient addresses are specified on the command line.
239
240 -U (ignored)
241 Initial user submission.
242
243 -V envid
244 Specify the envelope ID for notification by servers that support
245 DSN.
246
247 This feature is available in Postfix 2.3 and later.
248
249 -XV (Postfix 2.2 and earlier: -V)
250 Variable Envelope Return Path. Given an envelope sender address
251 of the form owner-listname@origin, each recipient user@domain
252 receives mail with a personalized envelope sender address.
253
254 By default, the personalized envelope sender address is owner-
255 listname+user=domain@origin. The default + and = characters are
256 configurable with the default_verp_delimiters configuration
257 parameter.
258
259 -XVxy (Postfix 2.2 and earlier: -Vxy)
260 As -XV, but uses x and y as the VERP delimiter characters,
261 instead of the characters specified with the default_verp_delim‐
262 iters configuration parameter.
263
264 -v Send an email report of the first delivery attempt (Postfix ver‐
265 sions 2.1 and later). Mail delivery always happens in the back‐
266 ground. When multiple -v options are given, enable verbose log‐
267 ging for debugging purposes.
268
269 -X log_file (ignored)
270 Log mailer traffic. Use the debug_peer_list and debug_peer_level
271 configuration parameters instead.
272
274 By design, this program is not set-user (or group) id. However, it must
275 handle data from untrusted, possibly remote, users. Thus, the usual
276 precautions need to be taken against malicious inputs.
277
279 Problems are logged to syslogd(8) and to the standard error stream.
280
282 MAIL_CONFIG
283 Directory with Postfix configuration files.
284
285 MAIL_VERBOSE (value does not matter)
286 Enable verbose logging for debugging purposes.
287
288 MAIL_DEBUG (value does not matter)
289 Enable debugging with an external command, as specified with the
290 debugger_command configuration parameter.
291
292 NAME The sender full name. This is used only with messages that have
293 no From: message header. See also the -F option above.
294
296 The following main.cf parameters are especially relevant to this pro‐
297 gram. The text below provides only a parameter summary. See post‐
298 conf(5) for more details including examples.
299
301 Available with Postfix 2.9 and later:
302
303 sendmail_fix_line_endings (always)
304 Controls how the Postfix sendmail command converts email message
305 line endings from <CR><LF> into UNIX format (<LF>).
306
308 The DEBUG_README file gives examples of how to trouble shoot a Postfix
309 system.
310
311 debugger_command (empty)
312 The external command to execute when a Postfix daemon program is
313 invoked with the -D option.
314
315 debug_peer_level (2)
316 The increment in verbose logging level when a remote client or
317 server matches a pattern in the debug_peer_list parameter.
318
319 debug_peer_list (empty)
320 Optional list of remote client or server hostname or network
321 address patterns that cause the verbose logging level to
322 increase by the amount specified in $debug_peer_level.
323
325 Available in Postfix version 2.2 and later:
326
327 authorized_flush_users (static:anyone)
328 List of users who are authorized to flush the queue.
329
330 authorized_mailq_users (static:anyone)
331 List of users who are authorized to view the queue.
332
333 authorized_submit_users (static:anyone)
334 List of users who are authorized to submit mail with the send‐
335 mail(1) command (and with the privileged postdrop(1) helper com‐
336 mand).
337
339 bounce_size_limit (50000)
340 The maximal amount of original message text that is sent in a
341 non-delivery notification.
342
343 fork_attempts (5)
344 The maximal number of attempts to fork() a child process.
345
346 fork_delay (1s)
347 The delay between attempts to fork() a child process.
348
349 hopcount_limit (50)
350 The maximal number of Received: message headers that is allowed
351 in the primary message headers.
352
353 queue_run_delay (300s)
354 The time between deferred queue scans by the queue manager;
355 prior to Postfix 2.4 the default value was 1000s.
356
358 The ETRN_README file describes configuration and operation details for
359 the Postfix "fast flush" service.
360
361 fast_flush_domains ($relay_domains)
362 Optional list of destinations that are eligible for per-destina‐
363 tion logfiles with mail that is queued to those destinations.
364
366 The VERP_README file describes configuration and operation details of
367 Postfix support for variable envelope return path addresses.
368
369 default_verp_delimiters (+=)
370 The two default VERP delimiter characters.
371
372 verp_delimiter_filter (-=+)
373 The characters Postfix accepts as VERP delimiter characters on
374 the Postfix sendmail(1) command line and in SMTP commands.
375
377 alias_database (see 'postconf -d' output)
378 The alias databases for local(8) delivery that are updated with
379 "newaliases" or with "sendmail -bi".
380
381 command_directory (see 'postconf -d' output)
382 The location of all postfix administrative commands.
383
384 config_directory (see 'postconf -d' output)
385 The default location of the Postfix main.cf and master.cf con‐
386 figuration files.
387
388 daemon_directory (see 'postconf -d' output)
389 The directory with Postfix support programs and daemon programs.
390
391 default_database_type (see 'postconf -d' output)
392 The default database type for use in newaliases(1), postalias(1)
393 and postmap(1) commands.
394
395 delay_warning_time (0h)
396 The time after which the sender receives a copy of the message
397 headers of mail that is still queued.
398
399 enable_errors_to (no)
400 Report mail delivery errors to the address specified with the
401 non-standard Errors-To: message header, instead of the envelope
402 sender address (this feature is removed with Postfix version
403 2.2, is turned off by default with Postfix version 2.1, and is
404 always turned on with older Postfix versions).
405
406 mail_owner (postfix)
407 The UNIX system account that owns the Postfix queue and most
408 Postfix daemon processes.
409
410 queue_directory (see 'postconf -d' output)
411 The location of the Postfix top-level queue directory.
412
413 remote_header_rewrite_domain (empty)
414 Don't rewrite message headers from remote clients at all when
415 this parameter is empty; otherwise, rewrite message headers and
416 append the specified domain name to incomplete addresses.
417
418 syslog_facility (mail)
419 The syslog facility of Postfix logging.
420
421 syslog_name (see 'postconf -d' output)
422 The mail system name that is prepended to the process name in
423 syslog records, so that "smtpd" becomes, for example, "post‐
424 fix/smtpd".
425
427 /var/spool/postfix, mail queue
428 /etc/postfix, configuration files
429
431 pickup(8), mail pickup daemon
432 qmgr(8), queue manager
433 smtpd(8), SMTP server
434 flush(8), fast flush service
435 postsuper(1), queue maintenance
436 postalias(1), create/update/query alias database
437 postdrop(1), mail posting utility
438 postfix(1), mail system control
439 postqueue(1), mail queue control
440 syslogd(8), system logging
441
443 Use "postconf readme_directory" or "postconf html_directory" to locate
444 this information.
445 DEBUG_README, Postfix debugging howto
446 ETRN_README, Postfix ETRN howto
447 VERP_README, Postfix VERP howto
448
450 The Secure Mailer license must be distributed with this software.
451
453 Wietse Venema
454 IBM T.J. Watson Research
455 P.O. Box 704
456 Yorktown Heights, NY 10598, USA
457
458
459
460 SENDMAIL(1)