Hello is there an internal mechanism in dovecot to rotate logs daily ? thanks
> -----Original Message----- > From: dovecot-bounces+nick.lunt=patech-solutions.com at dovecot.org > [mailto:dovecot-bounces+nick.lunt=patech-solutions.com at dovecot.org] On > Behalf Of Frank Bonnet > Sent: 18 January 2011 09:41 > To: Dovecot Mailing List > Subject: [Dovecot] rotate logs ? > > Hello > > is there an internal mechanism in dovecot to rotate logs daily ? > > thanksHow about putting the something similar to the following in /etc/logrotate.conf (on redhat/centos) /var/log/dovecot.log { weekly minsize 1M create 0664 root postfix rotate 4 } Cheers Nick . __________ Information from ESET NOD32 Antivirus, version of virus signature database 5795 (20110117) __________ The message was checked by ESET NOD32 Antivirus. http://www.eset.com
* Frank Bonnet <f.bonnet at esiee.fr>:> Hello > > is there an internal mechanism in dovecot to rotate logs daily ?No. -- Ralf Hildebrandt Gesch?ftsbereich IT | Abteilung Netzwerk Charit? - Universit?tsmedizin Berlin Campus Benjamin Franklin Hindenburgdamm 30 | D-12203 Berlin Tel. +49 30 450 570 155 | Fax: +49 30 450 570 962 ralf.hildebrandt at charite.de | http://www.charite.de
Same advise. Works flawlessly. Egbert Jan Op 18-1-2011 10:41, Nick Lunt schreef:> > >> -----Original Message----- >> From: dovecot-bounces+nick.lunt=patech-solutions.com at dovecot.org >> [mailto:dovecot-bounces+nick.lunt=patech-solutions.com at dovecot.org] On >> Behalf Of Frank Bonnet >> Sent: 18 January 2011 09:41 >> To: Dovecot Mailing List >> Subject: [Dovecot] rotate logs ? >> >> Hello >> >> is there an internal mechanism in dovecot to rotate logs daily ? >> >> thanks > > How about putting the something similar to the following in > /etc/logrotate.conf (on redhat/centos) > > /var/log/dovecot.log { > weekly > minsize 1M > create 0664 root postfix > rotate 4 > } > > Cheers > Nick . > > > > > __________ Information from ESET NOD32 Antivirus, version of virus > signature database 5795 (20110117) __________ > > The message was checked by ESET NOD32 Antivirus. > > http://www.eset.com >
On 18.1.2011, at 11.41, Nick Lunt wrote:> How about putting the something similar to the following in > /etc/logrotate.conf (on redhat/centos) > > /var/log/dovecot.log { > weekly > minsize 1M > create 0664 root postfix > rotate 4 > }Be sure to send a SIGUSR1 signal to dovecot process too so that it reopens the logs. (With v2.0 you can use doveadm log reopen.)
On 01/18/2011 10:53 AM, Timo Sirainen wrote:> On 18.1.2011, at 11.41, Nick Lunt wrote: > >> How about putting the something similar to the following in >> /etc/logrotate.conf (on redhat/centos) >> >> /var/log/dovecot.log { >> weekly >> minsize 1M >> create 0664 root postfix >> rotate 4 >> } > Be sure to send a SIGUSR1 signal to dovecot process too so that it reopens the logs. (With v2.0 you can use doveadm log reopen.) >Would this be OK in logrotate.conf ? kill -HUP `cat /var/run/dovecot/master.pid`
On Tue, 18 Jan 2011 11:53:17 +0200, Timo Sirainen <tss at iki.fi> wrote:> Be sure to send a SIGUSR1 signal to dovecot process too so that it > reopens the logs. (With v2.0 you can use doveadm log reopen.)Would this do? /var/log/dovecot.log { weekly rotate 4 create 600 root root size 64k compress notifempty postrotate [ -f /var/run/dovecot/master.pid ] && kill -USR1 $(cat /var/run/dovecot/master.pid) endscript } M.