[Dovecot] dovecot-lda logging
Hi everyone, I'm using Postfix and Dovecot with dovecot-lda used for local delivery. I've successfully migrated from 1.2.13 to 2.0.0 however I have a little problem with dovecot-lda logging. With version 1.2.13, I use to log dovecot-lda to /var/log/dovecot-lda.log with world-writable mode. With version 2.0.0, postfix complains: "Can't open log file /var/log/dovecot.log: permission denied".
This is understandable because my dovecot.log file is 0600 mode. My question is how do I retain the 1.2.13 functionality of logging dovecot-lda to /var/log/dovecot-lda.log.
I've read the LDA.txt in the wiki documentation and it states I can override log_path & info_log_path like this:
protocol lda { log_path = /var/log/dovecot-lda.log info_log_path = /var/log/dovecot-lda.log }
What I don't know is where to add that segment. Should I add it to 10-logging.conf or 15-lda.conf? Right now I've added that to both the files but I still see the postfix permission denied message.
I will appreciate if someone can help out. Thanks!
BTW, Great work Timo!!! Thank you very much for a great piece of software!
On Tue, 2010-08-17 at 22:22 -0500, Nishant Limbachia wrote:
I've read the LDA.txt in the wiki documentation and it states I can override log_path & info_log_path like this:
protocol lda { log_path = /var/log/dovecot-lda.log info_log_path = /var/log/dovecot-lda.log }
Yes.
What I don't know is where to add that segment. Should I add it to 10-logging.conf or 15-lda.conf?
It doesn't matter. The files are split only for readability.
Right now I've added that to both the files but I still see the postfix permission denied message.
It works with me. What does this say:
doveconf -f service=lda|grep log_path
On Wed, Aug 18, 2010 at 10:04 AM, Timo Sirainen tss@iki.fi wrote:
It doesn't matter. The files are split only for readability.
I've removed the the following from 10-logging.conf and kept it in 15-lda.conf. I've also restart dovecot after the change.
protocol lda { log_path = /var/log/dovecot-lda.log info_log_path = /var/log/dovecot-lda.log }
It works with me. What does this say:
doveconf -f service=lda|grep log_path
debug_log_path = /var/log/dovecot.log info_log_path = /var/log/dovecot-lda.log log_path = /var/log/dovecot-lda.log info_log_path = /var/log/dovecot-lda.log log_path = /var/log/dovecot-lda.log
Not sure why it shows twice.
Since I was having postfix delivery problem, I had changed dovecot.log perms to 0666 and all was well. After adding the lda logging, I've changed back the perms on /var/log/dovecot.log to 0600 and instantly I get the postfix permission denied message.
/var/log/dovecot-lda.log is mode 0666. /var/log/dovecot.log is mode 0600.
Thanks Timo
On Wed, 2010-08-18 at 10:50 -0500, Nishant Limbachia wrote:
doveconf -f service=lda|grep log_path
debug_log_path = /var/log/dovecot.log
This is the problem. You've specified a debug_log_path explicitly globally and didn't override it for lda. So lda was trying to open the debug log and failed to do it. Either comment out the global (it defaults to info_log_path) or override it in protocol lda {} as well.
On Wed, Aug 18, 2010 at 10:52 AM, Timo Sirainen tss@iki.fi wrote:
This is the problem. You've specified a debug_log_path explicitly globally and didn't override it for lda. So lda was trying to open the debug log and failed to do it. Either comment out the global (it defaults to info_log_path) or override it in protocol lda {} as well.
Specifying debug_log_path fixed the problem. Thanks once again. Appreciate the quick response.
participants (2)
-
Nishant Limbachia
-
Timo Sirainen