<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>Thanks man</p>
<p>You suggesting the same as <a class="moz-txt-link-freetext" href="https://wiki2.dovecot.org/Logging">https://wiki2.dovecot.org/Logging</a>
says?</p>
<pre style="border: 1pt solid rgb(174, 189, 204); background-color: rgb(243, 245, 247); padding: 5pt; font-family: courier, monospace; white-space: pre-wrap; word-wrap: break-word; color: rgb(0, 0, 0); font-size: 16px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: start; text-indent: 0px; text-transform: none; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;">postrotate
<span class="anchor" id="line-2-4"></span> kill -s 0 `cat /var/run/dovecot/master.pid` || kill -s USR1 `cat /var/run/dovecot/master.pid`
<span class="anchor" id="line-3-3"></span>endscript
</pre>
Well, I already tried that and didn't work. Hence my guess that it's
something else.<br>
<br>
<div class="moz-cite-prefix">On 15/06/18 13:19, Stephen Satchell
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:bb1e038c-f1bf-aeb8-e968-0987ebb8ed8b@satchell.net">
<pre wrap="">From the manpage:
SIGNALS
Dovecot handles the following signals as described:
USR1 Force dovecot to reopen all configured log files
(log_path, info_log_path and debug_log_path).
So, you need to add
kill -s USR1 `cat /var/run/dovecot/master.pod`
(or wherever your distribution puts the PID for dovecot) in your
log-rotate file, to tell Dovecot to use the new log file.
Alternatively, check to see if "doveadm" is installed in your system; if
not, that would cause exactly the symptoms you are seeing.
On 06/14/2018 03:30 PM, Michael Heuberger wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Hi there
This is weird. On my latest Ubuntu server Dovecot seems to write to
/var/log/dovecot.log.1 instead of a recently created /var/log/dovecot.log
Here my logrotate config for Dovecot:
/var/log/dovecot.log {
su root syslog
rotate 7
missingok
copytruncate
create 666 root syslog
sharedscripts
postrotate
doveadm log reopen
endscript
}
Doveadm should reopen it but no, still writes to old log file.
Not sure, maybe it's someone else, not dovecot, writing to the log file?
And here the versions:
# 2.2.33.2 (d6601f4ec): /etc/dovecot/dovecot.conf
# Pigeonhole version 0.4.21 (92477967)
# OS: Linux 4.14.49-rh65-20180612025235.xenU.x86_64 x86_64 Ubuntu 18.04 LTS
How can we investigate best? Or is there a mistake in the above
logrotate config?
- Michael
</pre>
</blockquote>
<pre wrap="">
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Binary Kitchen
Michael Heuberger
1/33 Parrish Road
Sandringham
Auckland 1025
(New Zealand)
Mobile (text only) ... +64 21 261 89 81
Email ................ <a class="moz-txt-link-abbreviated" href="mailto:michael@binarykitchen.com">michael@binarykitchen.com</a>
Website .............. <a class="moz-txt-link-freetext" href="http://www.binarykitchen.com">http://www.binarykitchen.com</a></pre>
</body>
</html>