27 |
|
|
28 |
There are some command line options that are used so often that it is |
There are some command line options that are used so often that it is |
29 |
inconvenient to specify them in the command line each time you run |
inconvenient to specify them in the command line each time you run |
30 |
a mailutils utility. The @file{mailutils.rc} provides a way to |
a mailutils utility. The @dfn{configuration files} provide a way to |
31 |
add default command line arguments without having to type them in |
add default command line arguments without having to type them in |
32 |
the command line. The file is located in your system configuration |
the command line. Upon startup, each mailutils utility scans and |
33 |
directory (usually, @file{/etc} or @file{/usr/local/etc}). |
processes the contents of the two startup files: the site-wide |
34 |
@footnote{Currently, the mailutils programs that use @file{mailutils.rc} |
configuration file @file{mailutils.rc} and user-specific configuration |
35 |
are: |
file @file{.mailutils}. The site-wide configuration file is searched |
36 |
|
in your system configuration directory (usually, @file{/etc} or |
37 |
@itemize @bullet |
@file{/usr/local/etc}), the user-specific configuration file is searched |
38 |
@item imap4d |
in user home directory. |
39 |
@item pop3d |
|
40 |
@item mail.local |
Both files have simple line-oriented syntax. Comments begin with the |
41 |
@item comsatd |
pound sign (@samp{#}) and extend through the end of the line |
42 |
@end itemize |
@footnote{If @samp{#} is not the first character on the line, it |
43 |
} |
should be separated from the previous word by any amount of whitespace.}. |
44 |
|
Very long lines may be split across several lines by escaping final newline |
45 |
The @file{mailutils.rc} has a simple line-oriented syntax. Upon |
with a backslash (@samp{\}) character. |
46 |
startup, each mailutils program scans this file for a line that |
|
47 |
begins either with a program name or with word `mailutils'. When |
Any non-comment line starts with a @dfn{tag}. A tag is either a name |
48 |
found, the rest of the line following the first word is split up |
of a particular mailutils utility or @dfn{option group}, prefixed with |
49 |
at whitespace characters and resulting words are added to the |
colon (@samp{:}). The command line options common for several mailutils |
50 |
program arguments @emph{before} the command line options. Thus, |
programs are divided into @dfn{option groups} or @dfn{capabilities}, |
51 |
the options specified in the command line override those from |
e.g. the options @option{--maildir} and @option{--license} form group |
52 |
@file{mailutils.rc} file. |
@samp{mailutils}. These groups are discussed in detail below. |
53 |
|
|
54 |
The very long lines may be split across several lines of text by |
When processing the configuration file, a mailutils utility selects |
55 |
escaping final newline with a backslash (@samp{\}) character. |
those lines, whose tag is either the name of that utility or the name |
56 |
The @samp{#} character introduces a comment (it must be |
of the option group supported by it. For each line found, its tag |
57 |
preceeded by whitespace). |
is stripped away, and the rest of the line is split up into words. |
58 |
|
These words are regarded as command line options and are inserted to |
59 |
Here is an example of a simple @file{mailutils.rc} file. It tells |
the program arguments @emph{before} any options from the command line. |
60 |
all mailutils programs to use @file{/var/spool/mail} as a mailspool |
Thus the options from @file{.mailutils} take precedence over those |
61 |
directory. All programs, except @command{imap4d} will issue diagnostics |
from @file{mailutils.rc}, and the options from the command line take |
62 |
via @code{local1} @file{syslog} facility. @command{imap4d} will use |
precedence over those from both configuration files. |
63 |
@code{local2}. |
|
64 |
|
The word splitting occurs at whitespace characters and is similar to |
65 |
|
that performed by the shell. If an option must contain embedded |
66 |
|
whitespace, it should be enclosed in a pair of quotes (either double |
67 |
|
or single quotes). |
68 |
|
|
69 |
|
@menu |
70 |
|
* mailutils:: Options common for all utilities. |
71 |
|
* daemon:: Options common for daemon programs. |
72 |
|
* auth:: Authentication-specific options. |
73 |
|
* logging:: Logging control options. |
74 |
|
* config sample:: A sample configuration file. |
75 |
|
@end menu |
76 |
|
|
77 |
|
@node mailutils |
78 |
|
@subsection mailutils --- Options common for all utilities. |
79 |
|
@cindex :mailutils |
80 |
|
|
81 |
|
Option group @samp{mailutils} consists of options common for all |
82 |
|
utilities in the package: |
83 |
|
|
84 |
|
@table @option |
85 |
|
@item -m @var{path} |
86 |
|
@itemx --maildir=@var{path} |
87 |
|
Set path to the mailspool directory |
88 |
|
@end table |
89 |
|
|
90 |
|
Each program also understands the following informational options: |
91 |
|
|
92 |
|
@table @option |
93 |
|
@item -u |
94 |
|
@itemx --usage |
95 |
|
Display a short usage message and exit. |
96 |
|
@item -h |
97 |
|
@itemx --help |
98 |
|
Display help message and exit. |
99 |
|
@item -L |
100 |
|
@itemx --license |
101 |
|
Display GNU General Public License and exit. |
102 |
|
@item -v |
103 |
|
@itemx --version |
104 |
|
Display program version and exit. |
105 |
|
@end table |
106 |
|
|
107 |
|
@node daemon |
108 |
|
@subsection daemon --- Options common for daemon programs. |
109 |
|
@cindex :daemon |
110 |
|
|
111 |
|
@table @option |
112 |
|
@item -d[@var{number}] |
113 |
|
@itemx --daemon[=@var{number}] |
114 |
|
Run in standalone mode. An optional @var{number} specifies the maximum number |
115 |
|
of child processes the daemon is allowed to fork. When it is omitted, |
116 |
|
it defaults to 20 processes. |
117 |
|
@emph{Please note}, that there should be no whitespace between the |
118 |
|
@option{-d} and its parameter. |
119 |
|
@item -i |
120 |
|
@itemx --inetd |
121 |
|
Run in inetd mode. |
122 |
|
@item -p @var{number} |
123 |
|
@itemx --port @var{number} |
124 |
|
Listen on given port @var{number}. This option is meaningful only in |
125 |
|
standalone mode. It defaults to port 143. |
126 |
|
@item -t @var{number} |
127 |
|
@itemx --timeout @var{number} |
128 |
|
Set idle timeout to given @var{number} of seconds. The daemon breaks the |
129 |
|
connection if it receives no commands from the client within that number |
130 |
|
of seconds. |
131 |
|
@end table |
132 |
|
|
133 |
|
@node auth |
134 |
|
@subsection auth --- Authentication-specific options. |
135 |
|
@cindex :auth |
136 |
|
|
137 |
|
@table @option |
138 |
|
@item --pam-service @var{name} |
139 |
|
When compiled with @acronym{pam} support, this option specifies the |
140 |
|
name of @acronym{pam} service to be used when authenticating. |
141 |
|
@end table |
142 |
|
|
143 |
|
The following options exist in this group if the package was configured |
144 |
|
with @samp{--enable-sql} option: |
145 |
|
|
146 |
|
@table @option |
147 |
|
@item sql-getpwnam @var{query} |
148 |
|
SQL query to retrieve a passwd entry based on username |
149 |
|
@item sql-getpwuid @var{query} |
150 |
|
@item sql-getpass @var{query} |
151 |
|
SQL query to retrieve a password from the database |
152 |
|
@item sql-host @var{name} |
153 |
|
Name or IP of MySQL server to connect to. |
154 |
|
@item sql-user @var{name} |
155 |
|
SQL user name |
156 |
|
@item sql-passwd @var{string} |
157 |
|
SQL connection password |
158 |
|
@item sql-db @var{string} |
159 |
|
Name of the database to connect to. |
160 |
|
@item sql-port @var{number} |
161 |
|
Port to use |
162 |
|
@end table |
163 |
|
|
164 |
|
@node logging |
165 |
|
@subsection logging --- Logging control options. |
166 |
|
@cindex :logging |
167 |
|
|
168 |
|
@table @option |
169 |
|
@item log-facility @var{facility} |
170 |
|
Output logs to the specified @command{syslog} facility. The following |
171 |
|
facility names are recognized: @samp{user}, @samp{daemon}, @samp{mail}, |
172 |
|
@samp{auth} and @samp{local0} through @samp{local7}. These names are |
173 |
|
case-insensitive. |
174 |
|
@end table |
175 |
|
|
176 |
|
@node config sample |
177 |
|
@subsection A sample configuration file. |
178 |
|
@cindex mailutils.rc, an example |
179 |
|
|
180 |
|
The following configuration file specifies that all mailutils programs |
181 |
|
should use @file{/var/spool/mail} as a local mailspool |
182 |
|
directory. Programs performing authentication will use @acronym{pam} |
183 |
|
service @samp{mailutils}. All programs, except @command{imap4d} will |
184 |
|
issue log messages via @samp{mail} facility, @command{imap4d} will use |
185 |
|
facility @samp{local1}. |
186 |
|
|
187 |
@example |
@example |
188 |
mailutils --log-facility local1 --maildir /var/spool/mail |
@group |
189 |
imap4d --log-facility local2 --daemon=10 |
:mailutils --maildir /var/spool/mail |
190 |
@end example |
:auth --pam-service mailutils |
191 |
|
:logging --log-facility mail |
192 |
|
imap4d --daemon=20 --timeout=1800 --log-facility local1 |
193 |
|
@end group |
194 |
|
@end example |
195 |
|
|
196 |
@page |
@page |
197 |
@node imap4d |
@node imap4d |
215 |
mode is triggered by @option{-d} command line switch. |
mode is triggered by @option{-d} command line switch. |
216 |
@end table |
@end table |
217 |
|
|
218 |
|
The program uses following option groups: @xref{mailutils}, |
219 |
|
@xref{daemon}, @xref{logging}, @xref{auth}. |
220 |
|
|
221 |
@subheading Command line options |
@subheading Command line options |
222 |
|
|
223 |
@table @option |
@table @option |
283 |
mode is triggered by @option{-d} command line switch. |
mode is triggered by @option{-d} command line switch. |
284 |
@end table |
@end table |
285 |
|
|
286 |
|
The program uses following option groups: @xref{mailutils}, |
287 |
|
@xref{daemon}, @xref{logging}, @xref{auth}. |
288 |
|
|
289 |
@subheading Command line options |
@subheading Command line options |
290 |
|
|
291 |
@table @option |
@table @option |
331 |
the command line, the program reads that folder rather than the default |
the command line, the program reads that folder rather than the default |
332 |
mailbox. |
mailbox. |
333 |
|
|
334 |
|
The program uses following option groups: @xref{mailutils}. |
335 |
|
|
336 |
The following command line options alter the behavior of the program: |
The following command line options alter the behavior of the program: |
337 |
|
|
338 |
@table @option |
@table @option |
|
@item -h |
|
|
@itemx --help |
|
|
Display short help message and exit. |
|
339 |
@item -f STRING |
@item -f STRING |
340 |
@item --field STRING |
@item --field STRING |
341 |
Display the header named by STRING instead of @code{From} @code{Subject} pair. |
Display the header named by STRING instead of @code{From} @code{Subject} pair. |
367 |
@itemx --align |
@itemx --align |
368 |
Tidy mode. Currently is not implemented. Included for compatibility with |
Tidy mode. Currently is not implemented. Included for compatibility with |
369 |
@command{frm} program from Elm package. |
@command{frm} program from Elm package. |
|
@item -v |
|
|
@itemx --version |
|
|
Display version information and exit |
|
370 |
@end table |
@end table |
371 |
|
|
372 |
@page |
@page |
410 |
If [address...] part is present, @command{mail} switches to mail sending |
If [address...] part is present, @command{mail} switches to mail sending |
411 |
mode, otherwise it operates in mail reading mode. |
mode, otherwise it operates in mail reading mode. |
412 |
|
|
413 |
|
The program uses following option groups: @xref{mailutils}. |
414 |
|
|
415 |
@command{Mail} understands following command line options: |
@command{Mail} understands following command line options: |
416 |
|
|
417 |
@table @option |
@table @option |
1619 |
@node Invocation |
@node Invocation |
1620 |
@subsection Invoking mail.local |
@subsection Invoking mail.local |
1621 |
|
|
1622 |
|
The program uses following option groups: @xref{mailutils}, @xref{auth}, |
1623 |
|
@xref{logging}. |
1624 |
|
|
1625 |
@table @option |
@table @option |
1626 |
@item -f @var{addr} |
@item -f @var{addr} |
1627 |
@itemx --from @var{addr} |
@itemx --from @var{addr} |
1767 |
where @var{folder} represents the folder name, @var{number} represents |
where @var{folder} represents the folder name, @var{number} represents |
1768 |
the number of messages. |
the number of messages. |
1769 |
|
|
1770 |
|
The program uses following option groups: @xref{mailutils}. |
1771 |
|
|
1772 |
The program accepts following command line options: |
The program accepts following command line options: |
1773 |
|
|
1774 |
@table @option |
@table @option |
1875 |
to each of them in turn and saves the resulting output in mailbox |
to each of them in turn and saves the resulting output in mailbox |
1876 |
format. |
format. |
1877 |
|
|
1878 |
|
The program uses following option groups: @xref{mailutils}. |
1879 |
|
|
1880 |
@menu |
@menu |
1881 |
* Specifying Scheme Program to Execute:: |
* Specifying Scheme Program to Execute:: |
1882 |
* Specifying Mailboxes to Operate Upon:: |
* Specifying Mailboxes to Operate Upon:: |
2251 |
@node Starting comsatd |
@node Starting comsatd |
2252 |
@subsection Starting comsatd |
@subsection Starting comsatd |
2253 |
|
|
2254 |
|
@command{Comsatd} uses following option groups: @xref{mailutils}, |
2255 |
|
@xref{daemon}, @xref{logging}. |
2256 |
|
|
2257 |
@table @option |
@table @option |
2258 |
@item -c @var{file} |
@item -c @var{file} |
2259 |
@itemx --config @var{file} |
@itemx --config @var{file} |