[Dovecot] dovecot-lda and vpopmail
I'm setting up a new box with Dovecot 1.0 beta1 and vpopmail. Normal operations works like a charm, i.e. vpopmail virtual can log in sucessfully using TLS.
However, when trying to test dovecot-lda out of CVS, it is not locating the user:
*** Starting dovecot-imapd service... dovecot: Info: Dovecot v1.0.beta1 starting up dovecot: Info: auth(default): master in: USER 1 postmaster@example.com service=deliver dovecot: Info: auth(default): master out: USER 1 postmaster uid=89 gid=89 home=/home/vpopmail/domains/example.com/postmaster dovecot: Error: auth(default):
except that the "master out" line *has* the correct information, though I don't know what that "Error" line is trying to tell me.
However, I am getting the mail bounced back with:
deliver: Fatal: mail setting not given
which is this error in the src/deliver.c:607
/* MAIL comes from userdb, DEFAULT_MAIL_ENV from dovecot.conf */
mail_env = getenv("MAIL");
if (mail_env == NULL)
mail_env = getenv("DEFAULT_MAIL_ENV");
if (mail_env == NULL)
i_fatal_status(EX_CONFIG, "mail setting not given");
which would certainly suggest that the userdb access failed in deliver (though the log would see to seem to suggest otherwise).
I even tried setting the DEFAULT_MAIL_ENV in dovecot.conf, but that didn't work either.
Anyone have any ideas about what I am missing?
John
-- John Peacock Director of Information Research and Technology Rowman & Littlefield Publishing Group 4501 Forbes Boulevard Suite H Lanham, MD 20706 301-459-3366 x.5010 fax 301-429-5748
John Peacock wrote:
I even tried setting the DEFAULT_MAIL_ENV in dovecot.conf, but that didn't work either.
Replying to myself. It seems that DEFAULT_MAIL_ENV is *required* in order for dovecot-lda to operate correctly (this is a big limitation, IMHO). The problem was that I was not setting it to the correct value. For the list archives, the correct answer is as follows.
Add the following line to dovecot.conf:
default_mail_env = maildir:%h/Maildir
and in .qmail-default for the domain have this line:
| /usr/local/libexec/dovecot/deliver -d $EXT@$USER
and then add a .dovecot.sieve file in the virtual user home directory (typically /home/vpopmail/domains/example.com/user) and it will be compiled and acted upon.
John
-- John Peacock Director of Information Research and Technology Rowman & Littlefield Publishing Group 4501 Forbes Boulevard Suite H Lanham, MD 20706 301-459-3366 x.5010 fax 301-429-5748
On Fri, 2006-01-20 at 16:56 -0500, John Peacock wrote:
John Peacock wrote:
I even tried setting the DEFAULT_MAIL_ENV in dovecot.conf, but that didn't work either.
Replying to myself. It seems that DEFAULT_MAIL_ENV is *required* in order for dovecot-lda to operate correctly (this is a big limitation, IMHO).
Well, I suppose I could make it non-required in which case it uses autodetection for the mailbox location. Although I'm not so sure if autodetection is all that great idea when delivering the mail. Anyway, changed in CVS now.
Timo Sirainen wrote:
Well, I suppose I could make it non-required in which case it uses autodetection for the mailbox location. Although I'm not so sure if autodetection is all that great idea when delivering the mail. Anyway, changed in CVS now.
Ideally, the exact same code would be used in deliver as is used in the IMAP server for determining the mailbox location, since both services rely on the same stanzas in dovecot.conf for configuration. If the site configuration is relying on autodetection for IMAP, it make sense to do so for deliver as well.
I was wondering if it wouldn't be best to share the imap/namespace.c code (since you already have a comment in deliver.c about handling namespaces).
John
-- John Peacock Director of Information Research and Technology Rowman & Littlefield Publishing Group 4720 Boston Way Lanham, MD 20706 301-459-3366 x.5010 fax 301-429-5747
On Sun, 2006-01-22 at 10:23 -0500, John Peacock wrote:
Timo Sirainen wrote:
Well, I suppose I could make it non-required in which case it uses autodetection for the mailbox location. Although I'm not so sure if autodetection is all that great idea when delivering the mail. Anyway, changed in CVS now.
Ideally, the exact same code would be used in deliver as is used in the IMAP server for determining the mailbox location, since both services rely on the same stanzas in dovecot.conf for configuration. If the site configuration is relying on autodetection for IMAP, it make sense to do so for deliver as well.
It's done now that way.
I was wondering if it wouldn't be best to share the imap/namespace.c code (since you already have a comment in deliver.c about handling namespaces).
It would be best, but I think I'll leave it after v1.0 release. I've actually already done it in my "dovecot 2.0" code branch.
participants (2)
-
John Peacock
-
Timo Sirainen