2
#GNU Mailman - Installation Manual About this document... About this
5
Previous Page Up One Level Next Page GNU Mailman - Installation Manual
6
_________________________________________________________________
8
GNU Mailman - Installation Manual
21
This document describes how to install GNU Mailman on a POSIX-based
22
system such as Unix, MacOSX, or GNU/Linux. It will cover basic
23
installation instructions, as well as guidelines for integrating
24
Mailman with your web and mail servers.
26
The GNU Mailman website is at http://www.list.org
28
1 Installation Requirements
30
GNU Mailman works on most POSIX-based systems such as Unix, MacOSX, or
31
GNU/Linux. It does not currently work on Windows. You must have a mail
32
server that you can send messages to, and a web server that supports
33
the CGI/1.1 API. Apache makes a fine choice for web server, and mail
34
servers such as Postfix, Exim, Sendmail, and qmail should work just
37
To install Mailman from source, you will need an ANSI C compiler to
38
build Mailman's security wrappers. The GNU C compiler gcc 2.8.1 or
39
later is known to work well.
41
You must have the Python interpreter installed somewhere on your
42
system. Mailman 2.1 requires Python 2.1 or newer, although Python 2.3
43
or newer is recommended.
47
Before installing Mailman, you need to prepare your system by adding
48
certain users and groups. You will need to have root privileges to
49
perform the steps in this section.
51
2.1 Add the group and user
53
Mailman requires a unique user and group name which will own its
54
files, and under which its processes will run. Mailman's basic
55
security is based on group ownership permissions, so it's important to
56
get this step right1. Typically, you will add a new user and a new
57
group, both called mailman. The mailman user must be a member of the
58
mailman group. Mailman will be installed under the mailman user and
59
group, with the set-group-id (setgid) bit enabled.
61
If these names are already in use, you can choose different user and
62
group names, as long as you remember these when you run configure. If
63
you choose a different unique user name, you will have to specify this
64
with configure's --with-username option, and if you choose a different
65
group name, you will have to specify this with configure's
66
--with-groupname option.
68
On Linux systems, you can use the following commands to create these
69
accounts. Check your system's manual pages for details:
72
% useradd -c''GNU Mailman'' -s /no/shell -d /no/home -g mailman mailman
74
2.2 Create the installation directory
76
Typically, Mailman is installed into a single directory, which
77
includes both the Mailman source code and the run-time list and
78
archive data. It is possible to split the static program files from
79
the variable data files and install them in separate directories. This
80
section will describe the available options.
82
The default is to install all of Mailman to /usr/local/mailman2. You
83
can change this base installation directory (referred to here as
84
$prefix) by specifying the directory with the --prefix configure
85
option. If you're upgrading from a previous version of Mailman, you
86
may want to use the --prefix option unless you move your mailing
89
Warning: You cannot install Mailman on a filesystem that is mounted
90
with the nosuid option. This will break Mailman, which relies on
91
setgid programs for its security. If this describes your environment,
92
simply install Mailman in a location that allows setgid programs.
94
Make sure the installation directory is set to group mailman (or
95
whatever you're going to specify with --with-groupname) and has the
96
setgid bit set3. You probably also want to guarantee that this
97
directory is readable and executable by everyone. For example, these
98
shell commands will accomplish this:
104
You are now ready to configure and install the Mailman software.
106
3 Build and install Mailman
110
Before you can install Mailman, you must run configure to set various
111
installation options your system might need.
113
Note: Take special note of the --with-mail-gid and --with-cgi-gid
114
options below. You will probably need to use these.
116
You should not be root while performing the steps in this section. Do
117
them under your own login, or whatever account you typically use to
118
install software. You do not need to do these steps as user mailman,
119
but you could. However, make sure that the login used is a member of
120
the mailman group as that that group has write permissions to the
121
$prefix directory made in the previous step. You must also have
122
permission to create a setgid file in the file system where it resides
123
(NFS and other mounts can be configured to inhibit setgid settings).
125
If you've installed other GNU software, you should be familiar with
126
the configure script. Usually you can just cd to the directory you
127
unpacked the Mailman source tarball into, and run configure with no
130
% cd mailman-<version>
134
The following options allow you to customize your Mailman
138
Standard GNU configure option which changes the base directory
139
that Mailman is installed into. By default $prefix is
140
/usr/local/mailman. This directory must already exist, and be
141
set up as described in 2.2.
144
Standard GNU configure option which lets you specify a
145
different installation directory for architecture dependent
148
--with-var-prefix=dir
149
Store mutable data under dir instead of under the $prefix or
150
$exec_prefix. Examples of such data include the list archives
151
and list settings database.
153
--with-python=/path/to/python
154
Specify an alternative Python interpreter to use for the
155
wrapper programs. The default is to use the interpreter found
156
first on your shell's $PATH.
158
--with-username=username-or-uid
159
Specify a different username than mailman. The value of this
160
option can be an integer user id or a user name. Be sure your
161
$prefix directory is owned by this user.
163
--with-groupname=groupname-or-gid
164
Specify a different groupname than mailman. The value of this
165
option can be an integer group id or a group name. Be sure your
166
$prefix directory is group-owned by this group.
168
--with-mail-gid=group-or-groups
169
Specify an alternative group for running scripts via the mail
170
wrapper. group-or-groups can be a list of one or more integer
171
group ids or symbolic group names. The first value in the list
172
that resolves to an existing group is used. By default, the
173
value is the list mailman, other, mail, and daemon.
175
Note: This is highly system dependent and you must get this
176
right, because the group id is compiled into the mail wrapper
177
program for added security. On systems using sendmail, the
178
sendmail.cf configuration file designates the group id of
179
sendmail processes using the DefaultUser option. (If commented
180
out, it still may be indicating the default...)
182
Check your mail server's documentation and configuration files
183
to find the right value for this switch.
185
--with-cgi-gid=group-or-groups
186
Specify an alternative group for running scripts via the CGI
187
wrapper. group-or-groups can be a list of one or more integer
188
group ids or symbolic group names. The first value in the list
189
that resolves to an existing group is used. By default, the
190
value is the the list www, www-data, and nobody.
192
Note: The proper value for this is dependent on your web server
193
configuration. You must get this right, because the group id is
194
compiled into the CGI wrapper program for added security, and
195
no Mailman CGI scripts will run if this is incorrect.
197
If you're using Apache, check the values for the Group option
198
in your httpd.conf file.
200
--with-cgi-ext=extension
201
Specify an extension for cgi-bin programs. The CGI wrappers
202
placed in $prefix/cgi-bin will have this extension (some web
203
servers require an extension). extension must include the
206
--with-mailhost=hostname
207
Specify the fully qualified host name part for outgoing email.
208
After the installation is complete, this value can be overriden
209
in $prefix/Mailman/mm_cfg.py.
211
--with-urlhost=hostname
212
Specify the fully qualified host name part of urls. After the
213
installation is complete, this value can be overriden in
214
$prefix/Mailman/mm_cfg.py.
217
Don't use gcc, even if it is found. In this case, cc must be
222
Once you've run configure, you can simply run make, then make install
223
to build and install Mailman.
225
4 Check your installation
227
After you've run make install, you should check that your installation
228
has all the correct permissions and group ownerships by running the
229
check_perms script. First change to the installation (i.e. $prefix)
230
directory, then run the bin/check_perms program. Don't try to run
231
bin/check_perms from the source directory; it will only run from the
232
installation directory.
234
If this reports no problems, then it's very likely <wink> that your
235
installation is set up correctly. If it reports problems, then you can
236
either fix them manually, re-run the installation, or use
237
bin/check_perms to fix the problems (probably the easiest solution):
239
* You need to become the user that did the installation, and that
240
owns all the files in $prefix, or root.
241
* Run bin/check_perms -f
242
* Repeat previous step until no more errors are reported!
244
Warning: If you're running Mailman on a shared multiuser system, and
245
you have mailing lists with private archives, you may want to hide the
246
private archive directory from other users on your system. In that
247
case, you should drop the other execute permission (o-x) from the
248
archives/private directory. However, the web server process must be
249
able to follow the symbolic link in public directory, otherwise your
250
public Pipermail archives will not work. To set this up, become root
251
and run the following commands:
253
# cd <prefix>/archives
254
# chown <web-server-user> private
257
You need to know what user your web server runs as. It may be www,
258
apache, httpd or nobody, depending on your server's configuration.
260
5 Set up your web server
262
Congratulations! You've installed the Mailman software. To get
263
everything running you need to hook Mailman up to both your web server
264
and your mail system.
266
If you plan on running your mail and web servers on different
267
machines, sharing Mailman installations via NFS, be sure that the
268
clocks on those two machines are synchronized closely. You might take
269
a look at the file Mailman/LockFile.py; the constant CLOCK_SLOP helps
270
the locking mechanism compensate for clock skew in this type of
273
This section describes some of the things you need to do to connect
274
Mailman's web interface to your web server. The instructions here are
275
somewhat geared toward the Apache web server, so you should consult
276
your web server documentation for details.
278
You must configure your web server to enable CGI script permission in
279
the $prefix/cgi-bin to run CGI scripts. The line you should add might
280
look something like the following, with the real absolute directory
281
substituted for $prefix, of course:
283
Exec /mailman/* $prefix/cgi-bin/*
287
ScriptAlias /mailman/ $prefix/cgi-bin/
289
Warning: You want to be very sure that the user id under which your
290
CGI scripts run is not in the mailman group you created above,
291
otherwise private archives will be accessible to anyone.
293
Copy the Mailman, Python, and GNU logos to a location accessible to
294
your web server. E.g. with Apache, you've usually got an icons
295
directory that you can drop the images into. For example:
297
% cp $prefix/icons/*.{jpg,png} /path/to/apache/icons
299
You then want to add a line to your $prefix/Mailman/mm_cfg.py file
300
which sets the base URL for the logos. For example:
302
IMAGE_LOGOS = '/images/'
304
The default value for IMAGE_LOGOS is /icons/. Read the comment in
305
Defaults.py.in for details.
307
Configure your web server to point to the Pipermail public mailing
308
list archives. For example, in Apache:
310
Alias /pipermail/ $varprefix/archives/public/
312
where $varprefix is usually $prefix unless you've used the
313
--with-var-prefix option to configure. Also be sure to configure your
314
web server to follow symbolic links in this directory, otherwise
315
public Pipermail archives won't be accessible. For Apache users,
316
consult the FollowSymLinks option.
318
If you're going to be supporting internationalized public archives,
319
you will probably want to turn off any default charset directive for
320
the Pipermail directory, otherwise your multilingual archive pages
321
won't show up correctly. Here's an example for Apache, based on the
322
standard installation directories:
324
<Directory "/usr/local/mailman/archives/public/">
325
AddDefaultCharset Off
328
Now restart your web server.
330
6 Set up your mail server
332
This section describes some of the things you need to do to connect
333
Mailman's email interface to your mail server. The instructions here
334
are different for each mail server; if your mail server is not
335
described in the following subsections, try to generalize from the
336
existing documentation, and consider contributing documentation
337
updates to the Mailman developers.
339
6.1 Using the Postfix mail server
341
Mailman should work pretty much out of the box with a standard Postfix
342
installation. It has been tested with various Postfix versions up to
343
and including Postfix 2.1.5.
345
In order to support Mailman's optional VERP delivery, you will want to
346
disable luser_relay (the default) and you will want to set
347
recipient_delimiter for extended address semantics. You should comment
348
out any luser_relay value in your main.cf and just go with the
349
defaults. Also, add this to your main.cf file:
351
recipient_delimiter = +
353
Using "+" as the delimiter works well with the default values for
354
VERP_FORMAT and VERP_REGEXP in Defaults.py.
356
When attempting to deliver a message to a non-existent local address,
357
Postfix may return a 450 error code. Since this is a transient error
358
code, Mailman will continue to attempt to deliver the message for
359
DELIVERY_RETRY_PERIOD - 5 days by default. You might want to set
360
Postfix up so that it returns permanent error codes for non-existent
361
local users by adding the following to your main.cf file:
363
unknown_local_recipient_reject_code = 550
365
Finally, if you are using Postfix-style virtual domains, read the
366
section on virtual domain support below.
368
6.1.1 Integrating Postfix and Mailman
370
You can integrate Postfix and Mailman such that when new lists are
371
created, or lists are removed, Postfix's alias database will be
372
automatically updated. The following are the steps you need to take to
375
In the description below, we assume that you've installed Mailman in
376
the default location, i.e. /usr/local/mailman. If that's not the case,
377
adjust the instructions according to your use of configure's --prefix
378
and --with-var-prefix options.
380
Note: If you are using virtual domains and you want Mailman to honor
381
your virtual domains, read the 6.1 section below first!
383
* Add this to the bottom of the $prefix/Mailman/mm_cfg.py file:
385
The MTA variable names a module in the Mailman/MTA directory which
386
contains the mail server-specific functions to be executed when a
387
list is created or removed.
388
* Look at the Defaults.py file for the variables POSTFIX_ALIAS_CMD
389
and POSTFIX_MAP_CMD command. Make sure these point to your
390
postalias and postmap programs respectively. Remember that if you
391
need to make changes, do it in mm_cfg.py.
392
* Run the bin/genaliases script to initialize your aliases file.
393
% cd /usr/local/mailman
396
Make sure that the owner of the data/aliases and data/aliases.db
397
file is mailman, that the group owner for those files is mailman,
398
or whatever user and group you used in the configure command, and
399
that both files are group writable:
401
% chown mailman:mailman data/aliases*
402
% chmod g+w data/aliases*
404
* Hack your Postfix's main.cf file to include the following path in
405
your alias_maps variable:
406
/usr/local/mailman/data/aliases
407
Note that there should be no trailing .db. Do not include this in
408
your alias_database variable. This is because you do not want
409
Postfix's newaliases command to modify Mailman's aliases.db file,
410
but you do want Postfix to consult aliases.db when looking for
412
You probably want to use a hash: style database for this entry.
414
alias_maps = hash:/etc/postfix/aliases,
415
hash:/usr/local/mailman/data/aliases
416
* When you configure Mailman, use the --with-mail-gid=mailman
417
switch; this will be the default if you configured Mailman after
418
adding the mailman owner. Because the owner of the aliases.db file
419
is mailman, Postfix will execute Mailman's wrapper program as uid
422
That's it! One caveat: when you add or remove a list, the aliases.db
423
file will updated, but it will not automatically run postfix reload.
424
This is because you need to be root to run this and suid-root scripts
425
are not secure. The only effect of this is that it will take about a
426
minute for Postfix to notice the change to the aliases.db file and
429
6.1.2 Virtual domains
431
Postfix 2.0 supports ``virtual alias domains'', essentially what used
432
to be called ``Postfix-style virtual domains'' in earlier Postfix
433
versions. To make virtual alias domains work with Mailman, you need to
434
do some setup in both Postfix and Mailman. Mailman will write all
435
virtual alias mappings to a file called, by default,
436
/usr/local/mailman/data/virtual-mailman. It will also use postmap to
437
create the virtual-mailman.db file that Postfix will actually use.
439
First, you need to set up the Postfix virtual alias domains as
440
described in the Postfix documentation (see Postfix's virtual(5)
441
manpage). Note that it's your responsibility to include the
442
virtual-alias.domain anything line as described manpage; Mailman will
443
not include this line in virtual-mailman. You are highly encouraged to
444
make sure your virtual alias domains are working properly before
445
integrating with Mailman.
447
Next, add a path to Postfix's virtual_alias_maps variable, pointing to
448
the virtual-mailman file, e.g.:
450
virtual_alias_maps = <your normal virtual alias files>,
451
hash:/usr/local/mailman/data/virtual-mailman
453
assuming you've installed Mailman in the default location. If you're
454
using an older version of Postfix which doesn't have the
455
virtual_alias_maps variable, use the virtual_maps variable instead.
457
Next, in your mm_cfg.py file, you will want to set the variable
458
POSTFIX_STYLE_VIRTUAL_DOMAINS to the list of virtual domains that
459
Mailman should update. This may not be all of the virtual alias
460
domains that your Postfix installation supports! The values in this
461
list will be matched against the host_name attribute of mailing lists
462
objects, and must be an exact match.
464
Here's an example. Say that Postfix is configured to handle the
465
virtual domains dom1.ain, dom2.ain, and dom3.ain, and further that in
466
your main.cf file you've got the following settings:
468
myhostname = mail.dom1.ain
470
mydestination = $myhostname, localhost.$mydomain
472
hash:/some/path/to/virtual-dom1,
473
hash:/some/path/to/virtual-dom2,
474
hash:/some/path/to/virtual-dom2
476
If in your virtual-dom1 file, you've got the following lines:
479
@dom1.ain @mail.dom1.ain
481
this tells Postfix to deliver anything addressed to dom1.ain to the
482
same mailbox at mail.dom1.com, its default destination.
484
In this case you would not include dom1.ain in
485
POSTFIX_STYLE_VIRTUAL_DOMAINS because otherwise Mailman will write
486
entries for mailing lists in the dom1.ain domain as
488
mylist@dom1.ain mylist
489
mylist-request@dom1.ain mylist-request
492
The more specific entries trump your more general entries, thus
493
breaking the delivery of any dom1.ain mailing list.
495
However, you would include dom2.ain and dom3.ain in mm_cfg.py:
497
POSTFIX_STYLE_VIRTUAL_DOMAINS = ['dom2.ain', 'dom3.ain']
499
Now, any list that Mailman creates in either of those two domains,
500
will have the correct entries written to
501
/usr/local/mailman/data/virtual-mailman.
503
As above with the data/aliases* files, you want to make sure that both
504
data/virtual-mailman and data/virtual-mailman.db are user and group
507
6.1.3 An alternative approach
509
Fil fil@rezo.net has an alternative approach based on virtual maps and
510
regular expressions, as described at:
512
* (French) http://listes.rezo.net/comment.php
513
* (English) http://listes.rezo.net/how.php
515
This is a good (and simpler) alternative if you don't mind exposing an
516
additional hostname in the domain part of the addresses people will
517
use to contact your list. I.e. if people should use
518
mylist@lists.dom.ain instead of mylist@dom.ain.
520
6.2 Using the Exim mail server
522
Note: This section is derived from Nigel Metheringham's ``HOWTO -
523
Using Exim and Mailman together'', which covers Mailman 2.0.x and Exim
524
3. It has been updated to cover Mailman 2.1 and Exim 4. The original
525
document is here: http://www.exim.org/howto/mailman.html.
527
There is no Mailman configuration needed other than the standard
528
options detailed in the Mailman install documentation. The Exim
529
configuration is transparent to Mailman. The user and group settings
530
for Mailman must match those in the config fragments given below.
532
6.2.1 Exim configuration
534
The Exim configuration is built so that a list created within Mailman
535
automatically appears to Exim without the need for defining any
538
The drawback of this configuration is that it will work poorly on
539
systems supporting lists in several different mail domains. While
540
Mailman handles virtual domains, it does not yet support having two
541
distinct lists with the same name in different virtual domains, using
542
the same Mailman installation. This will eventually change. (But see
543
below for a variation on this scheme that should accommodate virtual
546
The configuration file excerpts below are for use in an already
547
functional Exim configuration, which accepts mail for the domain in
548
which the list resides. If this domain is separate from the others
549
handled by your Exim configuration, then you'll need to:
551
* add the list domain, ``my.list.domain'' to local_domains
552
* add a ``domains=my.list.domain'' option to the director (router)
554
* (optional) exclude that domain from your other directors (routers)
556
Note: The instructions in this document should work with either Exim 3
557
or Exim 4. In Exim 3, you must have a local_domains configuration
558
setting; in Exim 4, you most likely have a local_domains domainlist.
559
If you don't, you probably know what you're doing and can adjust
560
accordingly. Similarly, in Exim 4 the concept of ``directors'' has
561
disappeared - there are only routers now. So if you're using Exim 4,
562
whenever this document says ``director'', read ``router''.
564
Whether you are using Exim 3 or Exim 4, you will need to add some
565
macros to the main section of your Exim config file. You will also
566
need to define one new transport. With Exim 3, you'll need to add a
567
new director; with Exim 4, a new router plays the same role.
569
Finally, the configuration supplied here should allow co-habiting
570
Mailman 2.0 and 2.1 installations, with the proviso that you'll
571
probably want to use mm21 in place of mailman - e.g., MM21_HOME,
574
6.2.2 Main configuration settings
576
First, you need to add some macros to the top of your Exim config
577
file. These just make the director (router) and transport below a bit
578
cleaner. Obviously, you'll need to edit these based on how you
579
configured and installed Mailman.
581
# Home dir for your Mailman installation -- aka Mailman's prefix
583
MAILMAN_HOME=/usr/local/mailman
584
MAILMAN_WRAP=MAILMAN_HOME/mail/mailman
586
# User and group for Mailman, should match your --with-mail-gid
587
# switch to Mailman's configure script.
589
MAILMAN_GROUP=mailman
591
6.2.3 Transport for Exim 3
593
Add this to the transports section of your Exim config file, i.e.
594
somewhere between the first and second ``end'' line:
598
command = MAILMAN_WRAP \
599
'${if def:local_part_suffix \
600
{${sg{$local_part_suffix}{-(\\w+)(\\+.*)?}{\$1}}} \
603
current_directory = MAILMAN_HOME
604
home_directory = MAILMAN_HOME
606
group = MAILMAN_GROUP
608
6.2.4 Director for Exim 3
610
If you're using Exim 3, you'll need to add the following director to
611
your config file (directors go between the second and third ``end''
612
lines). Also, don't forget that order matters - e.g. you can make
613
Mailman lists take precedence over system aliases by putting this
614
director in front of your aliasfile director, or vice-versa.
616
# Handle all addresses related to a list 'foo': the posting address.
617
# Automatically detects list existence by looking
618
# for lists/$local_part/config.pck under MAILMAN_HOME.
621
require_files = MAILMAN_HOME/lists/$local_part/config.pck
623
suffix = -bounces : -bounces+* : \
624
-confirm+* : -join : -leave : \
625
-owner : -request : -admin
626
transport = mailman_transport
628
6.2.5 Router for Exim 4
630
In Exim 4, there's no such thing as directors - you need to add a new
631
router instead. Also, the canonical order of the configuration file
632
was changed so routers come before transports, so the router for Exim
633
4 comes first here. Put this router somewhere after the ``begin
634
routers'' line of your config file, and remember that order matters.
638
require_files = MAILMAN_HOME/lists/$local_part/config.pck
639
local_part_suffix_optional
640
local_part_suffix = -bounces : -bounces+* : \
641
-confirm+* : -join : -leave : \
642
-owner : -request : -admin
643
transport = mailman_transport
645
6.2.6 Transports for Exim 4
647
The transport for Exim 4 is the same as for Exim 3 (see 6.2; just copy
648
the transport given above to somewhere under the ``begin transports''
649
line of your Exim config file.
651
6.2.7 Additional notes
653
Exim should be configured to allow reasonable volume - e.g. don't set
654
max_recipients down to a silly value - and with normal degrees of
655
security - specifically, be sure to allow relaying from 127.0.0.1, but
656
pretty much nothing else. Parallel deliveries and other tweaks can
657
also be used if you like; experiment with your setup to see what
658
works. Delay warning messages should be switched off or configured to
659
only happen for non-list mail, unless you like receiving tons of mail
660
when some random host is down.
664
* Mailman will send as many MAIL FROM/RCPT TO as it needs. It may
665
result in more than 10 or 100 messages sent in one connection,
666
which will exceed the default value of Exim's
667
smtp_accept_queue_per_connection value. This is bad because it
668
will cause Exim to switch into queue mode and severely delay
669
delivery of your list messages. The way to fix this is to set
670
Mailman's SMTP_MAX_SESSIONS_PER_CONNECTION (in
671
$prefix/Mailman/mm_cfg.py) to a smaller value than Exim's
672
smtp_accept_queue_per_connection.
673
* Mailman should ignore Exim delay warning messages, even though
674
Exim should never send this to list messages. Mailman 2.1's
675
general bounce detection and VERP support should greatly improve
676
the bounce detector's hit rates.
677
* List existence is determined by the existence of a config.pck file
678
for a list. If you delete lists by foul means, be aware of this.
679
* If you are getting Exim or Mailman complaining about user ids when
680
you send mail to a list, check that the MAILMAN_USER and
681
MAILMAN_GROUP match those of Mailman itself (i.e. what were used
682
in the configure script). Also make sure you do not have aliases
683
in the main alias file for the list.
685
6.2.9 Receiver Verification
687
Exim's receiver verification feature is very useful - it lets Exim
688
reject unrouteable addresses at SMTP time. However, this is most
689
useful for externally-originating mail that is addressed to mail in
690
one of your local domains. For Mailman list traffic, mail originates
691
on your server, and is addressed to random external domains that are
692
not under your control. Furthermore, each message is addressed to many
693
recipients - up to 500 if you use Mailman's default configuration and
694
don't tweak SMTP_MAX_RCPTS.
696
Doing receiver verification on Mailman list traffic is a recipe for
697
trouble. In particular, Exim will attempt to route every recipient
698
addresses in outgoing Mailman list posts. Even though this requires
699
nothing more than a few DNS lookups for each address, it can still
700
introduce significant delays. Therefore, you should disable recipient
701
verification for Mailman traffic.
703
Under Exim 3, put this in your main configuration section:
705
receiver_verify_hosts = !127.0.0.1
707
Under Exim 4, this is probably already taken care of for you by the
708
default recipient verification ACL statement (in the RCPT TO ACL):
710
accept domains = +local_domains
712
message = unknown user
715
which only does recipient verification on addresses in your domain.
716
(That's not exactly the same as doing recipient verification only on
717
messages coming from non-127.0.0.1 hosts, but it should do the trick
722
Exim's SMTP callback feature is an even more powerful way to detect
723
bogus sender addresses than normal sender verification. Unfortunately,
724
lots of servers send bounce messages with a bogus address in the
725
header, and there are plenty that send bounces with bogus envelope
726
senders (even though they're supposed to just use an empty envelope
729
In order to ensure that Mailman can disable/remove bouncing addresses,
730
you generally want to receive bounces for Mailman lists, even if those
731
bounces are themselves not bounceable. Thus, you might want to disable
732
SMTP callback on bounce messages.
734
With Exim 4, you can accomplish this using something like the
735
following in your RCPT TO ACL:
737
# Accept bounces to lists even if callbacks or other checks would fail
738
warn message = X-WhitelistedRCPT-nohdrfromcallback: Yes
740
${if and {{match{$local_part}{(.*)-bounces\+.*}} \
741
{exists {MAILMAN_HOME/lists/$1/config.pck}}} \
746
${if and {{match{$local_part}{(.*)-bounces\+.*}} \
747
{exists {MAILMAN_HOME/lists/$1/config.pck}}} \
751
# Now, check sender address with SMTP callback.
752
deny !verify = sender/callout=90s
754
If you also do SMTP callbacks on header addresses, you'll want
755
something like this in your DATA ACL:
757
deny !condition = $header_X-WhitelistedRCPT-nohdrfromcallback:
758
!verify = header_sender/callout=90s
760
6.2.11 Doing VERP with Exim and Mailman
762
VERP will send one email, with a separate envelope sender (return
763
path), for each of your subscribers - read the information in
764
$prefix/Mailman/Defaults.py for the options that start with VERP. In a
765
nutshell, all you need to do to enable VERP with Exim is to add these
766
lines to $prefix/Mailman/mm_cfg.py:
768
VERP_PASSWORD_REMINDERS = Yes
769
VERP_PERSONALIZED_DELIVERIES = Yes
770
VERP_DELIVERY_INTERVAL = Yes
771
VERP_CONFIRMATIONS = Yes
773
(The director (router) above is smart enough to deal with VERP
776
6.2.12 Virtual Domains
778
One approach to handling virtual domains is to use a separate Mailman
779
installation for each virtual domain. Currently, this is the only way
780
to have lists with the same name in different virtual domains handled
783
In this case, the MAILMAN_HOME and MAILMAN_WRAP macros are useless -
784
you can remove them. Change your director (router) to something like
787
require_files = /virtual/${domain}/mailman/lists/${lc:$local_part}/config.pck
789
and change your transport like this:
791
command = /virtual/${domain}/mailman/mail/mailman \
792
${if def:local_part_suffix \
793
{${sg{$local_part_suffix}{-(\\w+)(\\+.*)?}{\$1}}}
796
current_directory = /virtual/${domain}/mailman
797
home_directory = /virtual/${domain}/mailman
799
6.2.13 List Verification
801
This is how a set of address tests for the Exim lists look on a
802
working system. The list in question is
803
quixote-users@mems-exchange.org, and these commands were run on the
804
mems-exchange.org mail server ("% " indicates the Unix shell prompt):
806
% exim -bt quixote-users
807
quixote-users@mems-exchange.org
808
router = mailman_main_router, transport = mailman_transport
810
% exim -bt quixote-users-request
811
quixote-users-request@mems-exchange.org
812
router = mailman_router, transport = mailman_transport
814
% exim -bt quixote-users-bounces
815
quixote-users-bounces@mems-exchange.org
816
router = mailman_router, transport = mailman_transport
818
% exim -bt quixote-users-bounces+luser=example.com
819
quixote-users-bounces+luser=example.com@mems-exchange.org
820
router = mailman_router, transport = mailman_transport
822
If your exim -bt output looks something like this, that's a start: at
823
least it means Exim will pass the right messages to the right Mailman
824
commands. It by no means guarantees that your Exim/Mailman
825
installation is functioning perfectly, though!
827
6.2.14 Document History
829
Originally written by Nigel Metheringham postmaster@exim.org. Updated
830
by Marc Merlin marc_soft@merlins.org for Mailman 2.1, Exim 4.
831
Overhauled/reformatted/clarified/simplified by Greg Ward
834
6.3 Using the Sendmail mail server
836
Warning: You may be tempted to set the DELIVERY_MODULE configuration
837
variable in mm_cfg.py to 'Sendmail' when using the Sendmail mail
838
server. Don't. The Sendmail.py module is misnamed - it's really a
839
command line based message handoff scheme as opposed to the SMTP
840
scheme used in SMTPDirect.py (the default). Sendmail.py has known
841
security holes and is provided as a proof-of-concept only4. If you are
842
having problems using SMTPDirect.py fix those instead of using
843
Sendmail.py, or you may open your system up to security exploits.
845
6.3.1 Sendmail ``smrsh'' compatibility
847
Many newer versions of Sendmail come with a restricted execution
848
utility called ``smrsh'', which limits the executables that Sendmail
849
will allow to be used as mail programs. You need to explicitly allow
850
Mailman's wrapper program to be used with smrsh or Mailman will not
851
work. If mail is not getting delivered to Mailman's wrapper program
852
and you're getting an ``operating system error'' in your mail syslog,
853
this could be your problem.
855
One good way of enabling this is:
857
* Find out where your Sendmail executes its smrsh wrapper
858
% grep smrsh /etc/mail/sendmail.cf
860
* Figure out where smrsh expects symlinks for allowable mail
861
programs. At the very beginning of the following output you will
862
see a full path to some directory, e.g. /var/adm/sm.bin or
864
% strings $path_to_smrsh | less
866
* cd into /var/adm/sm.bin, or where ever it happens to reside on
867
your system - alternatives include /etc/smrsh, /var/smrsh and
871
* Create a symbolic link to Mailman's wrapper program:
872
% ln -s /usr/local/mailman/mail/mailman mailman
874
6.3.2 Integrating Sendmail and Mailman
876
David Champion has contributed a recipe for more closely integrating
877
Sendmail and Mailman, such that Sendmail will automatically recognize
878
and deliver to new mailing lists as they are created, without having
879
to manually edit alias tables.
881
In the contrib directory of Mailman's source distribution, you will
884
* mm-handler.readme - an explanation of how to set everything up
885
* mm-handler - the mail delivery agent (MDA)
886
* mailman.mc - a toy configuration file sample
887
* virtusertable - a sample for RFC 2142 address exceptions
889
6.3.3 Performance notes
891
One of the surest performance killers for Sendmail users is when
892
Sendmail is configured to synchronously verify the recipient's host
893
via DNS. If it does this for messages posted to it from Mailman, you
894
will get horrible performance. Since Mailman usually connects via
895
localhost (i.e. 127.0.0.1) to the SMTP port of Sendmail, you should be
896
sure to configure Sendmail to not do DNS verification synchronously
897
for localhost connections.
899
6.4 Using the Qmail mail server
901
There are some issues that users of the qmail mail transport agent
902
have encountered. None of the core maintainers use qmail, so all of
903
this information has been contributed by the Mailman user community,
904
especially Martin Preishuber and Christian Tismer, with notes by
905
Balazs Nagy (BN) and Norbert Bollow (NB).
907
* You might need to set the mail-gid user to either qmail, mailman,
908
or nofiles by using the --with-mail-gid configure option.
909
BN: it highly depends on your mail storing policy. For example if
910
you use the simple ~alias/.qmail-* files, you can use `id -g
911
alias`. But if you use /var/qmail/users, the specified mail gid
913
If you are going to be directing virtual domains directly to the
914
mailman user (using ``virtualdomains'' on a list-only domain, for
915
example), you will have to use --with-mail-gid=gid of mailman
916
user's group. This is incompatible with having list aliases in
917
~alias, unless that alias simply forwards to mailman-listname*.
918
* If there is a user mailman on your system, the alias mailman-owner
919
will work only in ~mailman. You have to do a touch .qmail-owner in
920
~mailman directory to create this alias.
921
NB: An alternative, IMHO better solution is to chown root
922
~mailman, that will stop qmail from considering mailman to be a
923
user to whom mail can be delivered. (See ``man 8 qmail-getpw''.)
924
* In a related issue, if you have any users with the same name as
925
one of your mailing lists, you will have problems if list names
926
contain "-" in them. Putting .qmail redirections into the user's
927
home directory doesn't work because the Mailman wrappers will not
928
get spawned with the proper GID. The solution is to put the
929
following lines in the /var/qmail/users/assign file:
930
+zope-:alias:112:11:/var/qmail/alias:-:zope-:
932
where in this case the listname is e.g. zope-users.
933
NB: Alternatively, you could host the lists on a virtual domain,
934
and use the /var/qmail/control/virtualdomains file to put the
935
mailman user in charge of this virtual domain.
936
* BN:If inbound messages are delivered by another user than mailman,
937
it's necessary to allow it to access ~mailman. Be sure that
938
~mailman has group writing access and setgid bit is set. Then put
939
the delivering user to mailman group, and you can deny access to
940
~mailman to others. Be sure that you can do the same with the WWW
942
By the way the best thing is to make a virtual mail server to
943
handle all of the mail. NB: E.g. make an additional "A" DNS record
944
for the virtual mailserver pointing to your IP address, add the
945
line lists.kva.hu:mailman to /var/qmail/control/virtualdomains and
946
a lists.kva.hu line to /var/qmail/control/rcpthosts file. Don't
947
forget to HUP the qmail-send after modifying ``virtualdomains''.
948
Then every mail to lists.kva.hu will arrive to mail.kva.hu's
950
Then make your aliases:
951
.qmail => mailman@...'s letters
952
.qmail-owner => mailman-owner's letters
953
For list aliases, you can either create them manually:
954
.qmail-list => posts to the 'list' list
955
.qmail-list-admin => posts to the 'list's owner
956
.qmail-list-request => requests to 'list'
958
or for automatic list alias handling (when using the lists.kva.hu
959
virtual as above), see contrib/qmail-to-mailman.py in the Mailman
960
source distribution. Modify the ~mailman/.qmail-default to
962
|preline /path/to/python /path/to/qmail-to-mailman.py
963
and new lists will automatically be picked up.
964
* You have to make sure that the localhost can relay. If you start
965
qmail via inetd and tcpenv, you need some line the following in
966
your /etc/hosts.allow file:
967
tcp-env: 127. 10.205.200. : setenv RELAYCLIENT
968
where 10.205.200. is your IP address block. If you use tcpserver,
969
then you need something like the following in your /etc/tcp.smtp
971
10.205.200.:allow,RELAYCLIENT=""
972
127.:allow,RELAYCLIENT=""
973
* BN: Bigger /var/qmail/control/concurrencyremote values work better
974
sending outbound messages, within reason. Unless you know your
975
system can handle it (many if not most cannot) this should not be
976
set to a value greater than 120.
977
* More information about setting up qmail and relaying can be found
978
in the qmail documentation.
980
BN: Last but not least, here's a little script to generate aliases to
981
your lists (if for some reason you can/will not have them
982
automatically picked up using contrib/qmail-to-mailman.py):
984
This script is for the Mailman 2.0 series:
989
echo Making links to $i in the current directory...
990
echo "|preline /home/mailman/mail/mailman post $i" > .qmail-$i
991
echo "|preline /home/mailman/mail/mailman mailowner $i" > .qmail-$i-admin
992
echo "|preline /home/mailman/mail/mailman mailowner $i" > .qmail-$i-owner
993
echo "|preline /home/mailman/mail/mailman mailowner $i" > .qmail-owner-$i
994
echo "|preline /home/mailman/mail/mailman mailcmd $i" > .qmail-$i-request
997
Note: This is for a new Mailman 2.1 installation. Users upgrading from
998
Mailman 2.0 would most likely change /usr/local/mailman to
999
/home/mailman. If in doubt, refer to the --prefix option passed to
1000
configure during compile time.
1005
echo Making links to $i in the current directory...
1006
echo "|preline /usr/local/mailman/mail/mailman post $i" > .qmail-$i
1007
echo "|preline /usr/local/mailman/mail/mailman admin $i" > .qmail-$i-admin
1008
echo "|preline /usr/local/mailman/mail/mailman bounces $i" > .qmail-$i-boun
1010
# The following line is for VERP
1011
# echo "|preline /usr/local/mailman/mail/mailman bounces $i" > .qmail-$i-bo
1013
echo "|preline /usr/local/mailman/mail/mailman confirm $i" > .qmail-$i-conf
1015
echo "|preline /usr/local/mailman/mail/mailman join $i" > .qmail-$i-join
1016
echo "|preline /usr/local/mailman/mail/mailman leave $i" > .qmail-$i-leave
1017
echo "|preline /usr/local/mailman/mail/mailman owner $i" > .qmail-$i-owner
1018
echo "|preline /usr/local/mailman/mail/mailman request $i" > .qmail-$i-requ
1020
echo "|preline /usr/local/mailman/mail/mailman subscribe $i" > .qmail-$i-su
1022
echo "|preline /usr/local/mailman/mail/mailman unsubscribe $i" > .qmail-$i-
1026
6.4.1 Information on VERP
1028
You will note in the alias generating script for 2.1 above, there is a
1029
line for VERP that has been commented out. If you are interested in
1030
VERP there are two options. The first option is to allow Mailman to do
1031
the VERP formatting. To activate this, uncomment that line and add the
1032
following lines to your mm_cfg.py file:
1034
VERP_FORMAT = '%(bounces)s-+%(mailbox)s=%(host)s'
1035
VERP_REGEXP = r'^(?P<bounces>.*?)-\+(?P<mailbox>[^=]+)=(?P<host>[^@]+)@.*$'
1037
The second option is a patch on SourceForge located at:
1039
http://sourceforge.net/tracker/?func=detail&atid=300103&aid=645513&gro
1042
This patch currently needs more testing and might best be suitable for
1043
developers or people well familiar with qmail. Having said that, this
1044
patch is the more qmail-friendly approach resulting in large
1047
6.4.2 Virtual mail server
1049
As mentioned in the 6.4 section for a virtual mail server, a patch
1050
under testing is located at:
1052
http://sf.net/tracker/index.php?func=detail&aid=621257&group_id=103&at
1055
Again, this patch is for people familiar with their qmail
1058
6.4.3 More information
1060
You might be interested in some information on modifying footers that
1061
Norbert Bollow has written about Mailman and qmail, available here:
1063
http://mailman.cis.to/qmail-verh/
1065
7 Review your site defaults
1067
Mailman has a large number of site-wide configuration options which
1068
you should now review and change according to your needs. Some of the
1069
options control how Mailman interacts with your environment, and other
1070
options select defaults for newly created lists5. There are system
1071
tuning parameters and integration options.
1073
The full set of site-wide defaults lives in the
1074
$prefix/Mailman/Defaults.py file, however you should never modify this
1075
file! Instead, change the mm_cfg.py file in that same directory. You
1076
only need to add values to mm_cfg.py that are different than the
1077
defaults in Defaults.py, and future Mailman upgrades are guaranteed
1078
never to touch your mm_cfg.py file.
1080
The Defaults.py file is documented extensively, so the options are not
1081
described here. The Defaults.py and mm_cfg.py are both Python files so
1082
valid Python syntax must be maintained or your Mailman installation
1085
Note: Do not change the HOME_DIR or MAILMAN_DIR variables. These are
1086
set automatically by the configure script, and you will break your
1087
Mailman installation by if you change these.
1089
You should make any changes to mm_cfg.py using the account you
1090
installed Mailman under in the 14 section.
1092
8 Create a site-wide mailing list
1094
After you have completed the integration of Mailman and your mail
1095
server, you need to create a ``site-wide'' mailing list. This is the
1096
one that password reminders will appear to come from, and it is
1097
required for proper Mailman operation. Usually this should be a list
1098
called mailman, but if you need to change this, be sure to change the
1099
MAILMAN_SITE_LIST variable in mm_cfg.py. You can create the site list
1100
with this command, following the prompts:
1102
% bin/newlist mailman
1104
Now configure your site list. There is a convenient template for a
1105
generic site list in the installation directory, under
1106
data/sitelist.cfg which can help you with this. You should review the
1107
configuration options in the template, but note that any options not
1108
named in the sitelist.cfg file won't be changed.
1110
The template can be applied to your site list by running:
1112
% bin/config_list -i data/sitelist.cfg mailman
1114
After applying the sitelist.cfg options, be sure you review the site
1115
list's configuration via the admin pages.
1117
You should also subscribe yourself to the site list.
1121
Several Mailman features occur on a regular schedule, so you must set
1122
up cron to run the right programs at the right time^6.
1124
If your version of crontab supports the -u option, you must be root to
1125
do this next step. Add $prefix/cron/crontab.in as a crontab entry by
1126
executing these commands:
1129
% crontab -u mailman crontab.in
1131
If you used the --with-username option, use that user name instead of
1132
mailman for the -u argument value. If your crontab does not support
1133
the -u option, try these commands:
1137
% crontab crontab.in
1139
10 Start the Mailman qrunner
1141
Mailman depends on a process called the ``qrunner'' to delivery all
1142
email messages it sees. You must start the qrunner by executing the
1143
following command from the $prefix directory:
1145
% bin/mailmanctl start
1147
You probably want to start Mailman every time you reboot your system.
1148
Exactly how to do this depends on your operating system. If your OS
1149
supports the chkconfig command (e.g. RedHat and Mandrake Linuxes) you
1150
can do the following (as root, from the Mailman install directory):
1152
% cp scripts/mailman /etc/init.d/mailman
1153
% chkconfig --add mailman
1155
Note that /etc/init.d may be /etc/rc.d/init.d on some systems.
1157
On Gentoo Linux, you can do the following:
1159
% cp scripts/mailman /etc/init.d/mailman
1160
% rc-update add mailman default
1162
On Debian, you probably want to use:
1164
% update-rc.d mailman defaults
1166
For Unixes that don't support chkconfig, you might try the following
1169
% cp scripts/mailman /etc/init.d/mailman
1170
% cp misc/mailman /etc/init.d
1171
% cd /etc/rc.d/rc0.d
1172
% ln -s ../init.d/mailman K12mailman
1174
% ln -s ../init.d/mailman K12mailman
1176
% ln -s ../init.d/mailman S98mailman
1178
% ln -s ../init.d/mailman S98mailman
1180
% ln -s ../init.d/mailman S98mailman
1182
% ln -s ../init.d/mailman S98mailman
1184
% ln -s ../init.d/mailman K12mailman
1186
11 Check the hostname settings
1188
You should check the values for DEFAULT_EMAIL_HOST and
1189
DEFAULT_URL_HOST in Defaults.py. Make any necessary changes in the
1190
mm_cfg.py file, not in the Defaults.py file. If you change either of
1191
these two values, you'll want to add the following afterwards in the
1194
add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
1196
You will want to run the bin/fix_url.py to change the domain of any
1199
12 Create the site password
1201
There are two site-wide passwords that you can create from the command
1202
line, using the bin/mmsitepass script. The first is the ``site
1203
password'' which can be used anywhere a password is required in the
1204
system. The site password will get you into the administration page
1205
for any list, and it can be used to log in as any user. Think root for
1206
a Unix system, so pick this password wisely!
1208
The second password is a site-wide ``list creator'' password. You can
1209
use this to delegate the ability to create new mailing lists without
1210
providing all the privileges of the site password. Of course, the
1211
owner of the site password can also create new mailing lists, but the
1212
list creator password is limited to just that special role.
1214
To set the site password, use this command:
1216
% $prefix/bin/mmsitepass <your-site-password>
1218
To set the list creator password, use this command:
1220
% $prefix/bin/mmsitepass -c <list-creator-password>
1222
It is okay not to set a list creator password, but you probably do
1223
want a site password.
1225
13 Create your first mailing list
1227
For more detailed information about using Mailman, including creating
1228
and configuring mailing lists, see the Mailman List Adminstration
1229
Manual. These instructions provide a quick guide to creating your
1230
first mailing list via the web interface:
1232
* Start by visiting the url http://my.dom.ain/mailman/create.
1233
* Fill out the form as described in the on-screen instructions, and
1234
in the ``List creator's password'' field, type the password you
1235
entered in section 7. Type your own email address for the
1236
``Initial list owner address'', and select ``Yes'' to notify the
1238
* Click on the ``Create List'' button.
1239
* Check your email for a message from Mailman informing you that
1240
your new mailing list was created.
1241
* Now visit the list's administration page, either by following the
1242
link on the confirmation web page or clicking on the link from the
1243
email Mailman just sent you. Typically the url will be something
1244
like http://my.dom.ain/mailman/admin/mylist.
1245
* Type in the list's password and click on ``Let me in...''
1246
* Click on ``Membership Management'' and then on ``Mass
1248
* Enter your email address in the big text field, and click on
1249
``Submit Your Changes''.
1250
* Now go to your email and send a message to mylist@my.dom.ain.
1251
Within a minute or two you should see your message reflected back
1254
Congratulations! You've just set up and tested your first Mailman
1255
mailing list. If you had any problems along the way, please see the 14
1260
If you encounter problems with running Mailman, first check the
1261
question and answer section below. If your problem is not covered
1262
there, check the online help, including the FAQ and the interactive
1265
Also check for errors in your syslog files, your mail and web server
1266
log files and in Mailman's $prefix/logs/error file. If you're still
1267
having problems, you should send a message to the
1268
mailman-users@python.org mailing list7; see
1269
http://mail.python.org/mailman/listinfo/mailman-users for more
1272
Be sure to including information on your operating system, which
1273
version of Python you're using, and which version of Mailman you're
1276
Here is a list of some common questions and answers:
1278
* Problem: All Mailman web pages give a 404 File not found error.
1279
Solution: Your web server has not been set up properly for
1280
handling Mailman's CGI programs. Make sure you have:
1281
1. configured the web server to give permissions to
1283
2. restarted the web server properly.
1284
Consult your web server's documentation for instructions on how to
1285
do check these issues.
1286
* Problem: All Mailman web pages give an "Internal Server Error".
1287
Solution: The likely problem is that you are using the wrong user
1288
or group for the CGI scripts. Check your web server's log files.
1289
If you see a line like
1290
Attempt to exec script with invalid gid 51, expected 99
1291
you will need to reinstall Mailman, specifying the proper CGI
1292
group id, as described in the section.
1293
* Problem: I send mail to the list, and get back mail saying the
1295
Solution: You probably didn't add the necessary aliases to the
1296
system alias database, or you didn't properly integrate Mailman
1297
with your mail server. Perhaps you didn't update the alias
1298
database, or your system requires you to run newaliases
1299
explicitly. Refer to your server specific instructions in the 6
1301
* Problem: I send mail to the list, and get back mail saying,
1302
``unknown mailer error''.
1303
Solution: The likely problem is that you are using the wrong user
1304
or group id for the mail wrappers. Check your mail server's log
1305
files; if you see a line like
1306
Attempt to exec script with invalid gid 51, expected 99
1307
you will need to reinstall Mailman, specifying the proper mail
1308
group id as described in the section.
1309
* Problem: I use Postfix as my mail server and the mail wrapper
1310
programs are logging complaints about the wrong GID.
1311
Solution: Make sure the $prefix/data/aliases.db file is user owned
1312
by mailman (or whatever user name you used in the configure
1313
command). If this file is not user owned by mailman, Postfix will
1314
not run the mail programs as the correct user.
1315
* Problem: I use Sendmail as my mail server, and when I send mail to
1316
the list, I get back mail saying, ``sh: mailman not available for
1317
sendmail programs''.
1318
Solution: Your system uses the Sendmail restricted shell (smrsh).
1319
You need to configure smrsh by creating a symbolic link from the
1320
mail wrapper ($prefix/mail/mailman) to the directory identifying
1321
executables allowed to run under smrsh.
1322
Some common names for this directory are /var/admin/sm.bin,
1323
/usr/admin/sm.bin or /etc/smrsh.
1324
Note that on Debian Linux, the system makes /usr/lib/sm.bin, which
1325
is wrong, you will need to create the directory /usr/admin/sm.bin
1326
and add the link there. Note further any aliases newaliases spits
1327
out will need to be adjusted to point to the secure link to the
1329
* Problem: I messed up when I called configure. How do I clean
1330
things up and re-install?
1333
% ./configure --with-the-right-options
1336
15 Platform and operating system notes
1338
Generally, Mailman runs on any POSIX-based system, such as Solaris,
1339
the various BSD variants, Linux systems, MacOSX, and other generic
1340
Unix systems. It doesn't run on Windows. For the most part, the
1341
generic instructions given in this document should be sufficient to
1342
get Mailman working on any supported platform. Some operating systems
1343
have additional recommended installation or configuration
1346
15.1 GNU/Linux issues
1348
Linux seems to be the most popular platform for running Mailman. Here
1349
are some hints on getting Mailman to run on Linux:
1351
* If you are getting errors with hard link creations and/or you are
1352
using a special secure kernel (securelinux/openwall/grsecurity),
1353
see the file contrib/README.check_perms_grsecurity in the Mailman
1354
source distribution.
1355
Note that if you are using Linux Mandrake in secure mode, you are
1356
probably concerned by this.
1357
* Apparently Mandrake 9.0 changed the permissions on gcc, so if you
1358
build as the mailman user, you need to be sure mailman is in the
1360
* If you installed Python from your Linux distribution's package
1361
manager (e.g. .rpms for Redhat-derived systems or .deb for
1362
Debian), you must install the ``development'' package of Python,
1363
or you may not get everything you need.
1364
For example, using Python 2.2 on Debian, you will need to install
1365
the python2.2-dev package. On Redhat, you probably need the
1366
python2-devel package.
1367
If you install Python from source, you should be fine.
1368
One symptom of this problem, although for unknown reasons, is that
1369
you might get an error such as this during your install:
1370
Traceback (most recent call last):
1371
File "bin/update", line 44, in ?
1373
ImportError: No module named paths
1374
make: *** [update] Error 1
1375
If this happens, install the Python development package and try
1376
configure and make install again. Or install the latest version of
1377
Python from source, available from http://www.python.org.
1378
This problem can manifest itself in other Linux distributions in
1379
different ways, although usually it appears as ImportErrors.
1383
Vivek Khera writes that some BSDs do nightly security scans for setuid
1384
file changes. setgid directories also come up on the scan when they
1385
change. Also, the setgid bit is not necessary on BSD systems because
1386
group ownership is automatically inherited on files created in
1387
directories. On other Unixes, this only happens when the directory has
1388
the setgid bit turned on.
1390
To install without turning on the setgid bit on directories, simply
1391
pass in the DIRSETGID variable to make, after you've run configure:
1393
% make DIRSETGID=: install
1395
This disables the chmod g+s command on installed directories.
1399
Many people run Mailman on MacOSX. Here are some pointers that have
1400
been collected on getting Mailman to run on MacOSX.
1402
* Jaguar (MacOSX 10.2) comes with Python 2.2. While this isn't the
1403
very latest stable version of Python, it ought to be sufficient to
1405
* David B. O'Donnell has a web page describing his configuration of
1406
Mailman 2.0.13 and Postfix on MacOSX Server.
1407
http://www.afp548.com/Articles/mail/python-mailman.html
1408
* Kathleen Webb posted her experiences in getting Mailman running on
1409
Jaguar using Sendmail.
1410
http://mail.python.org/pipermail/mailman-users/2002-October/022944
1412
* Panther server (MacOSX 10.3) comes with Mailman; Your operating
1413
system should contain documentation that will help you, and Apple
1414
has a tech document about a problem you might encounter running
1415
Mailman on Mac OS X Server 10.3:
1416
http://docs.info.apple.com/article.html?artnum=107889
1418
Terry Allen provides the following detailed instructions on running
1419
Mailman on the 'client' version of OSX, or in earlier versions of OSX:
1421
Mac OSX 10.3 and onwards has the basics for a successful Mailman
1422
installation. Users of earlier versions of Mac OSX contains Sendmail
1423
and those users should look at the Sendmail installation section for
1424
tips. You should follow the basic installation steps as described
1425
earlier in this manual, substituting as appropriate, the steps
1426
outlined in this section.
1428
By default, Mac OSX 10.3 'client' version does not have a fully
1429
functional version of Postfix. Setting up a working MTA such as
1430
Postfix is beyond the scope of this guide and you should refer to
1431
http://www.postfix.org for tips on getting Postfix running. An easy
1432
way to set Postfix up is to install and run Postfix Enabler, a
1433
stand-alone tool for configuring Postfix on Mac OSX, available from
1434
http://www.roadstead.com/weblog/Tutorials/PostfixEnabler.html.
1436
Likewise, Mac OSX 'client' version from 10.1 onwards includes a
1437
working Apache webserver. This is switched on using the System
1438
Preferences control panel under the 'Sharing tab'. A useful tool for
1439
configuring the Apache on Mac OSX is Webmin, which can be obtained
1440
from http://www.webmin.com.
1442
Webmin can also perform configuration for other system tasks,
1443
including Postfix, adding jobs to your crontab, adding user and
1444
groups, plus adding startup and shutdown jobs.
1446
In a stock installation of OSX, the requirement for Mailman is to have
1447
Python installed. Python is not installed by default, so it is advised
1448
that you install the developer's tools package, which may have been
1449
provided with your system. It can also be downloaded from the Apple
1450
developer site at http://connect.apple.com. Not only is the developer
1451
tools package an essential requirement for installing Mailman, but it
1452
will come in handy at a later date should you need other tools. The
1453
developer's tools are also know by the name XCode tools.
1455
As a minimum, the Python version should be 2.2, but 2.3 is
1458
If you wish to add a user and group using the command line in OSX
1459
instead of via Webmin or another GUI interface, open your terminal
1460
application and follow the commands as indicated below - do not type
1461
the comments following the "#" since they are just notes:
1464
niutil -create / /users/mailman
1465
niutil -createprop / /users/mailman name mailman
1466
# Note that xxx is a free user ID number on your system
1467
niutil -createprop / /users/mailman uid xxx
1468
niutil -createprop / /users/mailman home /usr/local/mailman
1469
mkdir -p /usr/local/mailman
1470
niutil -createprop / /users/mailman shell /bin/tcsh
1472
# To prevent malicious hacking, supply a secure password here
1473
niutil -create / /groups/mailman
1474
niutil -createprop / /groups/mailman name mailman
1475
# Note that xxx is a free group ID number on your system
1476
niutil -createprop / /groups/mailman gid xxx
1477
niutil -createprop / /groups/mailman passwd '*'
1478
niutil -createprop / /groups/mailman users 'mailman'
1479
chown mailman:mailman /usr/local/mailman
1480
cd /usr/local/mailman
1485
For setting up Apache on OSX to handle Mailman, the steps are almost
1486
identical and the configuration file on a stock Mac OSX Client version
1487
is stored in the nearly standard location of /etc/httpd/httpd.conf.
1489
The AFP548.com site has a time-saving automated startup item creator
1490
for Mailman, which can be found at
1491
http://www.afp548.com/Software/MailmanStartup.tar.gz
1493
To install it, copy it into your /Library/StartupItems directory. As
1494
the root or superuser, from the terminal, enter the following:
1496
gunzip MailmanStartup.tar.gz
1497
tar xvf MailmanStartup.tar
1499
It will create the startup item for you so that when you reboot,
1500
Mailman will start up.
1502
About this document ...
1504
GNU Mailman - Installation Manual, December 13, 2005, Release 2.1
1506
This document was generated using the LaTeX2HTML translator.
1508
LaTeX2HTML is Copyright � 1993, 1994, 1995, 1996, 1997, Nikos Drakos,
1509
Computer Based Learning Unit, University of Leeds, and Copyright �
1510
1997, 1998, Ross Moore, Mathematics Department, Macquarie University,
1513
The application of LaTeX2HTML to the Python documentation has been
1514
heavily tailored by Fred L. Drake, Jr. Original navigation icons were
1515
contributed by Christopher Petrilli.
1516
_________________________________________________________________
1521
You will be able to check and repair your permissions after
1522
installation is complete.
1524
.../usr/local/mailman2
1525
This is the default for Mailman 2.1. Earlier versions of
1526
Mailman installed everything under /home/mailman by default.
1529
BSD users should see the 15.2 section for additional
1533
In fact, in later versions of Mailman, this module is
1534
explicitly sabotaged. You have to know what you're doing in
1535
order to re-enable it.
1538
In general, changing the list defaults described in this
1539
section will not affect any already created lists. To make
1540
changes after a list has been created, use the web interface or
1541
the command line scripts, such as bin/withlist and
1545
Note that if you're upgrading from a previous version of
1546
Mailman, you'll want to install the new crontab, but be careful
1547
if you're running multiple Mailman installations on your site!
1548
Changing the crontab could mess with other parallel Mailman
1552
You must subscribe to this mailing list in order to post to it,
1553
but the mailing list's archives are publicly visible.
1554
_________________________________________________________________
1556
Previous Page Up One Level Next Page GNU Mailman - Installation Manual
1557
_________________________________________________________________
1559
Release 2.1, documentation updated on December 13, 2005.