masqmail

view man/masqmail.8 @ 336:2d4aa516ba0e

updated ChangeLog and NEWS
author markus schnalke <meillo@marmaro.de>
date Sat, 27 Aug 2011 18:38:55 +0200
parents 8bf7820a0e0e
children 1ca9bc4c6552
line source
1 .TH masqmail 8 2011-08-27 masqmail-0.3.3 "Maintenance Commands"
3 .SH NAME
4 masqmail \- An offline Mail Transfer Agent
6 .SH SYNOPSIS
8 .BR masqmail\ [ \-t ] \ [ \-oi ] \ [ \-f\ \fIADDRESS ]\ \fIRECIPIENT...
10 .B mailq
11 .br
12 .B masqmail \-bp
14 .B runq
15 .br
16 .B masqmail \-q
18 .BR masqmail\ \-qo\ \fINAME
20 .BI mailrm\ MSGID...
21 .br
22 .BI masqmail\ -Mrm\ MSGID...
24 .BR masqmail\ [ \-C\ \fIFILE ] \ [ \-odq ]\ \-bs
26 .BR masqmail\ [ \-C\ \fIFILE ] \ [ \-odq ]\ \-bd\ \-q\fIINTERVAL
28 (This list is a selection.)
31 .SH DESCRIPTION
33 Masqmail is a mail server designed for hosts that do not have a permanent internet connection
34 e.g. a home network or a single host at home.
35 It has special support for connections to different ISPs.
36 It replaces sendmail or other MTAs such as qmail or exim.
39 .SH OPERATION MODES
41 Masqmail operates in one of several exclusive modes.
43 The daemon mode has two flavors that may be,
44 and usually are, used in combination:
45 .TP
46 .B Daemon (listen)
47 .B \-bd
48 or invoked as
49 .B smtpd
51 Run as daemon.
52 Act as SMTP server and accept SMTP connections,
53 on port 25 if not configured differently.
55 This is normally used in the startup script at system boot
56 and together with \fB\-q\fIINTERVAL\fR (see below).
58 Alternatively masqmail can be run with the \fB\-bs\fR option
59 from inetd.
61 .TP
62 .B Daemon (queue)
63 .B \-q\fIINTERVAL
65 Run as daemon.
66 Do regular queue runs at the specified time interval.
67 This is normally used together with \fB\-bd\fR (see above).
69 An argument may be a time interval i.e. a numerical value followed by one
70 of the letters s,m,h,d,w which are interpreted as
71 seconds, minutes, hours, days or weeks respectively.
72 Example: \fB\-q30m\fR.
73 Combinations like \fB\-q1h30m\fR, which sendmail accepts, are not possible.
75 Alternatively single queue runs (\fB\-q\fR) can be started from cron.
77 .P
78 The queue processing mode has two flavors that may be
79 used in combination:
81 .TP
82 .B Single queue run (normal)
83 .B \-q
84 (without argument)
85 or invoked as
86 .B runq
88 Do a single queue run.
89 Try to deliver all messages in the queue.
90 Masqmail sends to addresses on the local host, on the local net,
91 and to remote ones, if available online routes permit.
92 That means, masqmail sends all queued mail it can.
93 Online detection is done with the configured
94 method (see \fBonline_query\fR in \fBmasqmail.conf(5)\fR).
96 .TP
97 .B Single queue run (only named route)
98 .BI \-qo\ NAME
100 Do a single queue run and deliver only using the specified online route.
102 The route configuration for \fINAME\fP is read and queued mail
103 to matching remote recipients is sent.
104 (See \fBonline_routes.\fINAME\fR in the main config file.)
106 You may want to use this option in scripts that run as soon as a link
107 to the internet has been set up (e.g. ip-up).
109 .B Obsolete behavior:
110 Up to now: If
111 .B \-qo
112 has no argument, the online connection is determinded
113 by online detect and, if available, mail is sent through it.
114 If none is available no mail is delivered.
116 This behavior is likely to change in future versions
117 because it is included in \-q.
118 We could do something more useful instead.
120 .P
121 The other modes are simple ones:
123 .TP
124 .B Rebuild alias database
125 .B \-bi
126 or invoked as
127 .B newaliases
129 A no-op for masqmail, just exit.
130 Old sendmail rebuilds its alias database when invoked with this option.
131 Masqmail reads directly from its alias file
132 (see config option `alias_file'),
133 thus no database needs to be updated.
135 .TP
136 .B Accept messages
137 .BR \-bm ,
138 also the default mode
140 Accept a text message on stdin.
141 This is the default mode of operation.
142 One will hardly use this switch as it is the default.
144 The command line options
145 .BR \-f , \-F , \-i / \-oi , \-t
146 are only used in this mode.
148 .TP
149 .B Print queue
150 .B \-bp
151 or invoked as
152 .B mailq
154 Show the messages in the queue.
156 .TP
157 .B Stand-alone SMTP server
158 .B \-bs
160 Act as SMTP server by reading commands from stdin
161 and writing to stdout.
162 Some mailers (e.g. pine) use this option as an interface.
163 It can also be used to call masqmail from inetd.
165 .TP
166 .B Print version
167 .B \-bV
168 or if called without arguments
170 Print version information, then exit.
172 .TP
173 .B Queue manipulation mode
174 .B \-Mrm
175 or invoked as
176 .B mailrm
178 Remove given messages from the queue.
179 Privileged users may remove any message, other users only their own.
180 The message identifiers are listed when printing the queue
181 (see \fB\-bp\fR).
183 .P
184 The default mode:
185 .P
186 When no mode had been specified by either one of the above command line
187 options or by calling masqmail under a special name,
188 then the default mode \fB\-bm\fR
189 (i.e. accept messages on stdin) is entered.
190 However, if neither address arguments are specified nor
191 \fB\-t\fR is given, then mail can not be sent,
192 hence something more useful is done: \fB\-bV\fP is assumed.
195 .SH OPTIONS
197 Since masqmail is intended to replace sendmail,
198 it uses the same command line options,
199 but not all are implemented.
200 The \fB\-qo\fP option is additional, and unique to masqmail.
202 .TP
203 \fB\-\-\fR
205 Not a `real' option, it means that all following arguments are to be understood
206 as arguments and not as options even if they begin with a leading dash `\-'.
207 Mutt is known to call sendmail with this option.
209 .TP
210 \fB\-bd\fR
212 ``Daemon (listen)'' mode. See above.
214 .TP
215 \fB\-bi\fR
217 ``Rebuild alias database'' mode. See above.
219 .TP
220 .B \-bm
222 ``Accept message'' mode. See above.
224 .TP
225 \fB\-bp\fR
227 ``Print queue'' mode. See above.
229 .TP
230 \fB\-bs\fR
232 ``Stand-alone SMTP server'' mode. See above.
234 .TP
235 \fB\-bV \fR
237 ``Print version'' mode. See above.
239 .TP
240 \fB\-B \fIarg\fR
242 \fIarg\fR is usually 8BITMIME.
243 Some mailers use this to indicate that the message contains characters > 127.
244 Masqmail is 8-bit clean and ignores this, so you do not have to recompile elm,
245 which is very painful ;-).
246 Note though that this violates some conventions:
247 masqmail does not convert 8 bit messages to any MIME format if it encounters
248 a mail server which does not advertise its 8BITMIME capability,
249 masqmail does not advertise this itself.
250 This is the same practice as that of exim (but different to sendmail).
252 .TP
253 \fB\-C \fIfilename\fR
255 Use another configuration than \fI/etc/masqmail/masqmail.conf\fR.
256 Useful for debugging purposes.
257 If not invoked by a privileged user, masqmail will drop all privileges.
259 .TP
260 \fB\-d \fInumber\fR
262 Set the debug level.
263 This takes precedence before the value of `debug_level' in the configuration file.
264 Read the warning in the description of the latter.
265 Only root may set the debug level.
267 .TP
268 \fB\-f [\fIaddress\fB]\fR
270 Set the return path address to \fIaddress\fR.
271 Only root, the user mail and anyone in group mail is allowed to do that.
273 .TP
274 \fB\-F [\fIstring\fB]\fR
276 Set the full sender name (in the From: header) to \fIstring\fR.
278 .TP
279 \fB\-i\fR
281 Same as \fB\-oi\fR, see below.
282 Kept for compatibility.
284 .TP
285 \fB\-Mrm \fImsgid...\fR
287 ``Queue manipulation'' mode. See above.
289 .TP
290 \fB\-m\fR
292 ``Me too''
293 This switch is ignored as,
294 masqmail never excludes the sender from any alias expansions.
296 \fB\-m\fP is an ancient alias for \fB\-om\fP.
297 Kept for compatibility.
299 .TP
300 \fB\-odb\fR
302 ``Deliver in Background''
303 Masqmail always does this.
304 Hence masqmail ignores this switch.
306 .TP
307 \fB\-odq\fR
309 ``Do Queueing''
310 Do not attempt to deliver immediately.
311 Any messages will be queued until the next queue running process picks them
312 up and delivers them.
313 You get the same effect by setting the do_queue option in
314 /etc/masqmail/masqmail.conf.
316 .TP
317 \fB\-oi\fR
319 A dot as a single character in a line does not terminate the message.
321 The same as \fB\-i\fP.
323 .TP
324 \fB\-oXXX\fR
326 Any other switch starting with `\-o' is ignored.
327 This especially affects \-om, \-oem, \-oee.
329 .TP
330 \fB\-q
332 ``Single queue run (normal)'' mode. See above.
334 .TP
335 \fB\-q\fIINTERVAL
337 ``Daemon (queue)'' mode. See above.
339 .TP
340 \fB\-qo \fIname
342 ``Single queue run (only named route)'' mode. See above.
344 .TP
345 \fB\-t\fR
347 Read recipients from mail headers and add them to the ones specified on the
348 command line.
349 (Only To:, Cc:, and Bcc: headers are regarded.)
351 .B WARNING: The behavior changed with version 0.3.1!
353 In earlier versions command line argument addresses were ``substracted''
354 from header addresses.
356 The old behavior was similar to exim's and smail's
357 (which are anchesters of masqmail).
358 The new behavior is similar to the one of current postfix versions,
359 which add the arguments to the set of header recipients.
360 (Earlier postfix failed in case of address arguments with \-t.)
361 Sendmail seems to behave differently, depending on the version.
362 See exim(8) for further information.
364 For masqmail the most simple approach had been taken.
366 As the behavior of \-t together with command line address arguments
367 differs among MTAs, one better not steps into this corner case.
369 .TP
370 \fB\-v\fR
372 ``Verbose''
373 Log also to stdout.
374 Currently, some log messages are marked as `write to stdout' and additionally,
375 all messages with priority `LOG_ALERT' and `LOG_WARNING' will be written to stdout
376 if this option is given. It is disabled in daemon mode.
379 .SH ENVIRONMENT FOR PIPES AND MDAS
381 For security reasons, before any pipe command from an alias expansion or an mda is called,
382 the environment variables will be completely discarded and newly set up. These are:
384 SENDER, RETURN_PATH \(en the return path.
386 SENDER_DOMAIN \(en the domain part of the return path.
388 SENDER_LOCAL \(en the local part of the return path.
390 RECEIVED_HOST \(en the host the message was received from (unless local).
392 LOCAL_PART, USER, LOGNAME \(en the local part of the (original) recipient.
394 MESSAGE_ID \(en the unique message id.
395 This is not necessarily identical with the Message ID as given in the Message ID: header.
397 QUALIFY_DOMAIN \(en the domain which will be appended to unqualified addresses.
400 .SH FILES
402 .TP
403 .I /etc/masqmail/masqmail.conf
404 The main configuration for masqmail.
405 Depending on the settings in this file, you will also have other configuration
406 files in \fI/etc/masqmail/\fR.
408 .TP
409 .I /var/spool/masqmail/
410 The spool directory where masqmail stores its queued mails.
412 .TP
413 .I /var/spool/mail/
414 The directory where locally delivered mail will be put,
415 if not configured differently in \fImasqmail.conf\fR.
417 .TP
418 .I /var/log/masqmail/
419 The directory where masqmail stores its log messages.
421 .P
422 Any of the paths can be configured at compile time,
423 and (except the main config file) also in the main config file.
424 The typical paths are different, depending on the Unix system you use.
427 .SH CONFORMING TO
429 RFC 821, 822, 1869, 1870, 2197, 2554 (SMTP)
431 RFC 1321 (MD5)
433 RFC 2195 (CRAM-MD5)
436 .SH AUTHOR
438 Masqmail was written by Oliver Kurth.
439 It is now maintained by Markus Schnalke <meillo@marmaro.de>.
441 You will find the newest version of masqmail on its website:
442 .BR http://marmaro.de/prog/masqmail/ .
443 There is also a mailing list;
444 you will find information about it on the website.
447 .SH BUGS
449 Bug reports of any kind are very welcome.
450 They help masqmail to become better.
451 Please report bugs to the mailing list (anyone can post).
454 .SH SEE ALSO
456 \fBmasqmail.conf(5)\fR, \fBmasqmail.route(5)\fR, \fBmasqmail.aliases(5)\fR