Installation notes for package Mailman (2016)
By installing the mailman package, you will find configuration instruction at
The mailman web site is extremely good, but not openSUSE specific (there are some differences).
To begin with
Of course you have to install mailman through YaST or zypper. After that, mailman home can be found in
(for "CULTe", moved to /home/data/mailman - /etc/password fixed)
- also written ~mailman in the doc, home of user mailman.
The executables are in
specially the "bin" folder with the mailman scripts (this folder is not in the PATH, so you have to type the whole path to execute them).
Do not forget to add these folders in your backup path, specially /var/lib/mailman/archives/.
The package is preconfigured for use with the Apache2 web server and the Postfix MTA.
in /etc/sysconfig/mailman tweak the parameters. Here my 13.1 config. only the three "culte" lines are new:
s-r:~ # egrep -v "^$|^#" /etc/sysconfig/mailman MAILMAN_MAIL_GID="mailman" MAILMAN_CGI_GID="www" MAILMAN_MTA="Postfix" MAILMAN_SMTPHOST="localhost" MAILMAN_DEFAULT_NNTP_HOST="news.culte.org" MAILMAN_DEFAULT_EMAIL_HOST="culte.org" MAILMAN_DEFAULT_URL_HOST="culte.org" MAILMAN_VIRTUAL_HOSTS="" MAILMAN_DEFAULT_HTTPS="no" MAILMAN_SMTPPORT="25"
and run "/usr/lib/mailman/bin/mailman-generate-sysconfig"
following notices where in my previous notice, looks like this config file get simplified:
and run "SuSEconfig -module mailman".
SMTPHOST is the mail server you use. If it's the same machine as mailman, localhost is the good value.
...EMAIL_HOST and ...URL_HOST can receive the domain name as shown.
When running config, be aware than if ever you touched the /usr/lib/mailman/Mailman/mm_cfg.py mailman file, config do not overwrite it, but write his prefered config file next to it. Specially, the value DELIVERY_MODULE = 'SMTPDirect' is the good one for openSUSE, when default is sendmail.
as user root to set your site master password.
Of course you need to start postfix!
Add /var/lib/mailman/data/aliases to the alias_maps statement in /etc/postfix/main.cf:
alias_maps = hash:/etc/aliases, hash:/var/lib/mailman/data/aliases and "postfix reload" .
Make sure to add this at the end of the main.cf file. The last line in the file win, and the default is to have a blanc alias_maps line at the end of the file.
I keep the following for reference, but in the systemd times, using /etc/sysconfig seems deprecated:
Alternatively, you can add the following line to /etc/sysconfig/postfix:
POSTFIX_ADD_ALIAS_MAPS="hash:/etc/aliases, hash:/var/lib/mailman/data/aliases" and let SuSEconfig do the job for you.
The aliases are used to copy the incomming mails to mailman, so if mailman receive the mails (and archive them, for example), the aliases are ok.
Finally, call "/usr/lib/mailman/bin/newlist mailman" as user root to create the master mailing list. This list is needed for the inner workings of Mailman. For details see
you will be prompted for a password.
In /etc/sysconfig/apache2, add "MAILMAN" to the APACHE_SERVER_FLAGS. To do this, call
and restart Apache:
With systemV inits:
From 12.1 on, you can still use the same command, but the best way is to call
systemctl start apache2.service
Wich will report much more info. Completion with TAB key works.
systemctl start mailman.service
This will also run cron if not yet running, mailman needs cron for some jobs.
You can either create mailing lists through the web interface or with the "newlist" command as root (located in /usr/lib/mailman/bin). In both cases, the lists' aliases are created automatically and propagated to the Postfix MTA.
To remove mailing lists, you need to use the command line.
Setting cron. Looks like the -u option is necessary even if you did su mailman, so better run this as root
[root prompt]# cd /usr/lib/mailman/cron [root prompt]# crontab -u mailman crontab.in
The list of scripts may change depending of the mailman version, but running the cronjob is still necessary
Copied all of
from the old server to the new one.
Fix the permissions with
chown -R wwwrun:mailman /var/lib/mailman/lists/
Fix the urls for the new one with
withlist -l -r fix_url [listname]
for each list. (Only necessary if the new server has a different domain name than the old one)
to the new server.
Fix the permissions with
chown -R wwwrun:mailman /var/lib/mailman/archives/private
(mailman:mailman should also works. The group owner is the most important).
probably necesssary, reinstall aliases (anyway, do not hurt):
I don't really see the point of this, but who knows?
"Regenerated the archives using "/var/lib/mailman/bin/arch [listname]" for each list. Note that if your archives are big, this process can consume all the memory in your system and then some, so you may have to split the mbox files up and regenerate the list archives in peices or use the "--start" and "--end" options to arch.
the mailman logs are in
in debugging session, it's a good idea to remove all the logs files (save them elsewhere if useful) to see the logs that come from the next move. These files/folders are created on the move.
to fix permissions problems:
Owner in new mailman config is root:mailman
in any list folder, owner is wwwrun:mailman
ls -l mailman/lists/mailman/ total 12 -rw-rw---- 1 wwwrun mailman 3779 avril 29 14:58 config.pck -rw-rw---- 1 wwwrun mailman 3779 avril 29 14:58 config.pck.last -rw-rw---- 1 wwwrun mailman 298 avril 29 14:57 pending.pck
Once Mailman and Inn installed, to connect the two systems, it's enough to go in each list admin manager, go to "news<->mail gateway" menu. There give the news server's name (do not need to be localhost) and the newsgroup name (nntp name).
Don't forget to tick the gateway options
Mailman do all the job.
if it's a move, or just in case, you may have to use "withlist" to manipulate the message index (for example found in logs/fromusenet)
$ bin/withlist -l <listname>
withlist loads an interactive mode. ">>>" is the withlist prompt. You get:
Loading list test (locked) The variable `m' is the test MailList instance >>>
type in withlist:
and after the = sign, you can type "None" or the message number in the newsgroup of the first message to be sent to the list. If there are many message, do not give "0" (all the messages) - and <CR> (hit Enter)
to save the changes, then "Control D" to exit withlist, you get:
Unlocking (but not saving) list: test Finalizing
Notice that the mailing list "mailman-users" gives invaluable help, specially Marc Sapiro, thanks to him (and to the others).