[Dovecot] dovecot.log file permissions and ownership

Timo Sirainen tss at iki.fi
Tue Oct 27 23:54:55 EET 2009


On Sun, 2009-10-25 at 07:14 -0400, Jerry wrote:
> Using FreeBSD-7.2 and Dovecot v1.2.4
> 
> what user does dovecot use to write to its log file? I have the logfile
> located in the /var/log directory.

Most of Dovecot writes to it as root, but deliver is a special case.

> I have Postfix configured to use 'virtual' users and use dovecot for
> delivery.
> 
> While dove can write to the file when accessed for POP services, when
> accessed via Postfix, I get this error message:
> 
> Oct 25 07:02:15 scorpio postfix/pipe[56956]: B01BD2287E: to=<user at domain.com>, relay=dovecot, delay=220, delays=220/0.01/0/0.04, dsn=4.3.0, status=deferred (temporary failure. Command output: Can't open log file /var/log/dovecot.log: Permission denied )

Then you either need to make it writable to the user that runs pipe, or
use a different file. http://wiki.dovecot.org/LDA#Logging

> I have used the following ownership types for the file:
> 
> 1) root:wheel
> 2) dovecot:dovecot
> 3) root:dovecot
> 4) dovecot:wheel

Never use "dovecot" user for anything at all. It's internal to Dovecot
and you never need to give it access to anything or set any file to be
owned by dovecot.

> The only thing that works all the time is to give the file full r/w
> (0666) permission. That seems extreme.

What user did you give to Postfix's pipe in master.cf? That's the user
you need.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20091027/72562e94/attachment-0001.bin 


More information about the dovecot mailing list