[Dovecot] Problem with default_mail_env in beta9

Timo Sirainen tss at iki.fi
Sun Jun 18 01:26:04 EEST 2006


On Fri, 2006-06-16 at 15:00 +0200, Andreas Schulze wrote:
> I have all users in ldap.
> there is an attribute "mailMessageStore" which contains a relative path to users maildir
> mailMessageStore: sca/
> 
> my mailer completes this relative pathinformation to /var/mail/sca/
> 
> therefor I setup default_mail_env to "maildir:/var/mail/%h"
> dovecot-ldap.conf includes "user_attrs = mailMessageStore=home,uidNumber=uid,gidNumber=gid"
..
> dovecot: Jun 16 14:50:30 Error: POP3(sca): dovecot: Jun 16 14:50:30 Fatal: chdir(sca/) failed with uid 30014: Permission denied

Dovecot tries to chdir() to the home directory before starting up the
pop3 process, and since the default startup directory
is /var/run/dovecot, it tried to chdir() under it. I've no idea why it
happened to be working for you with beta7. Maybe I added some extra
check which broke it for you.

One easy way to fix this would be to just comment out the chdir() call
from src/master/mail-process.c. The proper way would be to make the home
directory be an absolute path.

Perhaps the LDAP code needs a bit more changing so that you can use the
values received from LDAP in a template for Dovecot's settings.
Something like:

user_attrs = mailMessageStore=home=/var/mail/%1,uidNumber=uid,gidNumber=gid

BTW. This would break that other guy's quota configuration who I just
recently replied to that I wouldn't be breaking it.. :)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 191 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20060618/dc50e9ec/attachment.pgp


More information about the dovecot mailing list