This also presents part of the solution to another problem I need to
solve: Scaling the mail server across multiple machines. This covers how
to get the users imapping/popping off of the correct machine but can
anyone share with me the details of how to get qmail to route mail to the
appropriate host for local delivery? I already have a perl script wrapping
qmail-queue which filters and reroutes certain emails locally. Perhaps I
could just use it to rewrite the envelope to address with the appropriate
machine name as derived from a dbm file or something.
You might want to take a look at qmail-ldap, which keeps account info in
ldap directories, and supports full routing and doesn't need to rewrite
addresses. It just looks at a users ldap entry for a mailhost attribute,
then sends the mail to that box using qmqpd (lightning fast qmail
queueing protocol). I just converted a 30GB mailstore on a
UW-Imap/Sendmail box to Courier and Qmail-LDAP, then put local mail
servers at international offices. Users can't even log onto the mail
servers, they just have imap access. Some of the power-users aren't too
crazy about this new system, but it hasn't crashed once in two months.
The old system was crashing 1-2 times a week and causing major problems.