[Dovecot] Ambiguous mail location setting
Shawn
shawn.collins at mts.net
Sun Jul 5 08:56:48 EEST 2009
"Using Dovecot v1.0.alpha4 on OpenBSD 3.8 (same problem find using Dovecot v1.0.alpha3 on OpenBSD 3.7)
Log output:
_________________________________
dovecot: Nov 04 11:15:28 Info: auth(default): client in: AUTH 1 PLAIN service=IMAP secured lip=127.0.0.1 rip=127.0.0.1 resp=AHl2cmlAbjN1dHJpbm4uaXQAeXVyaW6zgXRyaW1v
dovecot: Nov 04 11:15:28 Info: auth(default): sql(myuser at mydomain.com <http://dovecot.org/cgi-bin/mailman/listinfo/dovecot>,127.0.0.1): query: SELECT password FROM user_accounts WHERE username='myuser at mydomain.com <http://dovecot.org/cgi-bin/mailman/listinfo/dovecot>'
dovecot: Nov 04 11:15:28 Info: auth(default): client out: OK 1 user=myuser at mydomain.com <http://dovecot.org/cgi-bin/mailman/listinfo/dovecot>
dovecot: Nov 04 11:15:28 Info: auth(default): master in: REQUEST 5 32206 1
dovecot: Nov 04 11:15:28 Info: auth(default): sql(myuser at mydomain.com <http://dovecot.org/cgi-bin/mailman/listinfo/dovecot>,127.0.0.1): SELECT '/var/mail/'||mailbox AS mail, uid, gid FROM user_accounts WHERE username='myuser at mydomain.com <http://dovecot.org/cgi-bin/mailman/listinfo/dovecot>'
dovecot: Nov 04 11:15:28 Info: auth(default): master out: USER 5 myuser at mydomain.com <http://dovecot.org/cgi-bin/mailman/listinfo/dovecot> mail=/var/mail/mydomain.com/myuser uid=10001 gid=10001
dovecot: Nov 04 11:15:28 Error: imap(myuser at mydomain.com <http://dovecot.org/cgi-bin/mailman/listinfo/dovecot>): Ambiguous mail location setting, don't know what to do with it: /var/mail/mydomain.com/myuser (try prefixing it with mbox: or maildir:)
dovecot: Nov 04 11:15:28 Error: imap(myuser at mydomain.com <http://dovecot.org/cgi-bin/mailman/listinfo/dovecot>): Failed to create storage with data: /var/mail/mydomain.com/myuser
_________________________________
I verified that "default_mail_env" on my dovecot configuration file are "maildir:" correctly prefixed:
"default_mail_env = maildir:/var/mail/%d/%n"
and ... permissions of /var/mail/mydomain and /var/mail/mydomain/myuser are 2755 and owner is root:mail.
I'm sure that isn't an authentication problem.
I've tried some days to understand and to find over internet and here in the dovecot mailing list but I've not find a solution yet.
I think it's a dovecot internal bug.
Someone know what I'm talking about?"
Set permissions on the mail folder to 2775 because dovecot runs as its own user and group and you need the mail file in that folder to accept writes from mail and from dovecot groups.
Also in the config file dovecot.conf you need to specify if the files are maildir or mbox. They are probably mbox but try both for the error messages.
More information about the dovecot
mailing list