Exim configuration for Mailman with Redhat RPMs

I’ve been working on installing Mailman at our institution. It’s been interesting and fun (I’ve been working particularly on altering the default design), but we ran into a problem that had me scratching my head for the past couple of days.

When I tried to send e-mail to a list, I got the following error in the Exim log:

Child process of mailman_transport transport returned 127 (could mean unable to exec or command does not exist)

I finally tracked the issue down with lots of help from another pair of eyes from a colleague. When you install using Redhat RPMs, mailman messages and list data are stored in /var/lib/mailman, but the binaries and other installation files are stored in /usr/lib/mailman. The Exim instructions for Mailman go like this:


# By default this is set to "/usr/local/mailman"
# On a Red Hat/Fedora system using the RPM use "/var/mailman"
# On Debian using the deb package use "/var/lib/mailman"
# This is normally the same as ~mailman
MM_HOME=/var/mailman
#
<snip>
#
# These values are derived from the ones above and should not need
# editing unless you have munged your mailman installation
#
# The path of the Mailman mail wrapper script
MM_WRAP=MM_HOME/mail/mailman
#
# The path of the list config file (used as a required file when
# verifying list addresses)
MM_LISTCHK=MM_HOME/lists/${lc::$local_part}/config.pck

See the problem? The list check on a Redhat RPM needs to point to one place (/var/lib/mailman), and the wrapper needs to point to another (/usr/lib/mailman), so one can work, but not the other – the other error we were getting was “local delivery failed” (when the MM_HOME value was set to /usr/lib/mailman the Exim mailman_router would fail because the config.pck file was actually in /var/lib/mailman) – you can also test these at the command line with /usr/sbin/exim -bt <listname>@<yourhost>.

The solution was to hard-code the list check in exim.conf:


MM_HOME=/usr/lib/mailman
...
<snip>
...
# The path of the Mailman mail wrapper script
MM_WRAP=MM_HOME/mail/mailman
#
# The path of the list config file (used as a required file when
# verifying list addresses)
MM_LISTCHK=/var/lib/mailman/lists/${lc::$local_part}/config.pck

Hopefully this will help anyone else who might run into this problem.