D. J. Bernstein
Internet mail
Frequently asked questions

Routing incoming messages by user

How do I set up a mailing list? I'd like me-sos@my.host.name to be forwarded to a bunch of people.

Answer: Put a list of addresses into ~me/.qmail-sos, one per line. Then incoming mail for me-sos will be forwarded to each of those addresses. You should also touch ~me/.qmail-sos-owner so that bounces come back to you rather than the original sender.

Alternative: ezmlm is a modern mailing list manager, supporting automatic subscriptions, confirmations, archives, fully automatic bounce handling (including warnings to subscribers saying which messages they've missed), and more.

How do I create aliases with dots? I tried setting up ~alias/.qmail-P.D.Q.Bach, but it doesn't do anything.

Answer: Use .qmail-p:d:q:bach. Dots are converted to colons, and uppercase is converted to lowercase.

How do I use sendmail's .forward files with qmail?

Answer: Install the dot-forward package.

How do I use sendmail's /etc/aliases with qmail?

Answer: Install the fastforward package.

To make majordomo 1.94.* work with qmail under fastforward, insert

before the lclose(LIST) line in do_subscribe and do_unsubscribe in majordomo. See ftp://ftp.eyrie.org/pub/software/majordomo/mjqmail and http://www.qmail.org for other methods of using majordomo with qmail. majordomo 2.0 is expected to support qmail directly.
How do I make qmail defer messages during NFS or NIS outages? If ~joe suddenly disappears, I'd like mail for joe to be deferred.

Answer: Build a qmail-users database, so that qmail no longer checks home directories and the password database. This takes three steps. First, put your complete user list (including local and NIS passwords) into /var/qmail/users/passwd. Second, run

     qmail-pw2u -h < /var/qmail/users/passwd > /var/qmail/users/assign
Here -h means that every user must have a home directory; if you happen to run qmail-pw2u during an NFS outage, it will print an error message and stop. Third, run
Make sure to rebuild the database whenever you change your user list.
How do I change which account controls an address? I set up ~alias/.qmail-www, but qmail is looking at ~www/.qmail instead.

Answer: If you run

     chown root ~www
then qmail will no longer consider www to be a user; see /var/qmail/man/cat8/qmail-getpw.0. For more precise control over address assignments, see /var/qmail/man/cat5/qmail-users.0.
How do I use procmail with qmail?

Answer: Users can run

     | preline procmail
from ~/.qmail. They will need to use a full path for procmail unless procmail is in the system's startup PATH.

If you are moving from sendmail, and users have procmail in their .forward files: procmail will continue to work from .forward files if you have installed dot-forward.

If you are moving from sendmail, and sendmail was using procmail instead of binmail: Copy /var/qmail/boot/proc or /var/qmail/boot/proc+df to /var/qmail/rc.

How do I use elm's filter with qmail?

Answer: Users can run

     | preline filter
from ~/.qmail. They will need to use a full path for filter unless filter is in the system's startup PATH.
How do I forward unrecognized usernames to another host? With sendmail I had a LUSER_RELAY pointing at bigbang.af.mil.

Answer: Put

     | forward "$LOCAL@bigbang.af.mil"
into ~alias/.qmail-default.