[SOLVED] dovecot: No log rotation bug
[SOLVED] dovecot: No log rotation bug
I have some VESTA CP [ 0.9.8 (amd64)] installations, all on Ubuntu 14.04.
Today I noticed that dovecot log files in /var/log/dovecot.log (in every server) have grown quite large. I also noticed that there are no other dovecot.* files in /var/log and that lead me thinking that there is no log rotation for dovecot.
Based on the above I would like to ask two things:
Today I noticed that dovecot log files in /var/log/dovecot.log (in every server) have grown quite large. I also noticed that there are no other dovecot.* files in /var/log and that lead me thinking that there is no log rotation for dovecot.
Based on the above I would like to ask two things:
- Is this behavior (not rotating the logs) by design and if so why? To my understanding, not rotating logs seems more like a bug...
- How can I setup log rotation for dovecot?
Last edited by Felix on Mon Feb 22, 2016 11:27 am, edited 4 times in total.
-
- Collaborator
- Posts: 783
- Joined: Mon May 11, 2015 8:43 am
- Contact:
- Os: CentOS 6x
- Web: apache + nginx
Re: dovecot: No log rotation
I have checked this on CentOS, and there I see the same behavior. You can try to change this manually:
https://www.digitalocean.com/community/ ... untu-12-10
https://www.digitalocean.com/community/ ... untu-12-10
Re: dovecot: No log rotation
Thanks tjebbeke for the useful reply. I read the guide you suggested along with the following:
Setup a mail server with Postfix and Dovecot on Ubuntu / Debian
HowTo: The Ultimate Logrotate Command Tutorial with 10 Examples
Dovecot Wiki: Logging
Then I setup log rotation for dovecot as follows:
Setup a mail server with Postfix and Dovecot on Ubuntu / Debian
HowTo: The Ultimate Logrotate Command Tutorial with 10 Examples
Dovecot Wiki: Logging
Then I setup log rotation for dovecot as follows:
- created the file /etc/logrotate.d/dovecot with the following content
Code: Select all
/var/log/dovecot*.log { missingok notifempty delaycompress sharedscripts postrotate doveadm log reopen endscript }
- To force log rotation (for all logs) I run the command
Code: Select all
logrotate --force -s logrotate.status /etc/logrotate.conf
Re: [SOLVED] dovecot: No log rotation bug
Seems like a bug, we'll check this.
https://bugs.vestacp.com/issues/207
Thanks you for topic and detail answers.
https://bugs.vestacp.com/issues/207
Thanks you for topic and detail answers.