[Dovecot] Questions about deliver log files
Hi,
I upgraded from Courier to dovecot, and now I try to rebuild some of the features I used to have. One was a monthly per user log of maildrop's work.
I used this code in maildroprc:
DATE=date +%m
logfile "$MAILDIR/maildrop-$DATE.log"
This created a monthly log in the each user's Maildir. I find it easier to have a log per user than having to filter the log entries from a large log file for all users.
I tried to recreate it with deliver by using the variables %h and %d/%n, but they are not interpreted when the log file is accessed ("Can't open log file /var/vmail/%d/%n/deliver.log: No such file or directory"). And there seems to be no way to include a date in the file name (but maybe I could use logrotate for that).
Another problem:
Currently deliver only logs the message id. A user would never ask for this (especially if he asks where certain mails were stored/discarded), he would ask for the sender's name/email or subject. Is the contents of the log file configurable?
Frank
On Sun, 2007-11-25 at 00:03 +0100, frank.kintrup@fkware.de wrote:
I tried to recreate it with deliver by using the variables %h and %d/%n, but they are not interpreted when the log file is accessed ("Can't open log file /var/vmail/%d/%n/deliver.log: No such file or directory"). And there seems to be no way to include a date in the file name (but maybe I could use logrotate for that).
v2.0 will have better support for these kind of things, but for now you could use a dynamically generated config file. Before running deliver you'd create a config for it using perl or whatever where the log_path is set like you want it.
Currently deliver only logs the message id. A user would never ask for this (especially if he asks where certain mails were stored/discarded), he would ask for the sender's name/email or subject. Is the contents of the log file configurable?
Unfortunately not. I added this to my TODO now. It wouldn't be difficult to modify deliver's sources for this though.
On Mon, 2007-11-26 at 14:56 +0200, Timo Sirainen wrote:
Currently deliver only logs the message id. A user would never ask for this (especially if he asks where certain mails were stored/discarded), he would ask for the sender's name/email or subject. Is the contents of the log file configurable?
Unfortunately not. I added this to my TODO now. It wouldn't be difficult to modify deliver's sources for this though.
v1.1 supports this now: http://hg.dovecot.org/dovecot/rev/6b5f89c41de5
participants (2)
-
frank.kintrup@fkware.de
-
Timo Sirainen