Puppetmaster Logrotate isn't working

495 views
Skip to first unread message

willi....@home24.de

unread,
Apr 29, 2014, 12:13:41 PM4/29/14
to puppet...@googlegroups.com, Sergey Novikov
Hello,

we have an issue that the Puppetmaster logrotate isn't working.

We are using the following default Logrotate:

/var/log/puppet/*log {
missingok
sharedscripts
create 0644 puppet puppet
compress
rotate 4

postrotate
pkill -USR2 -u puppet -f 'puppet master' || true
[ -e /etc/init.d/puppet ] && /etc/init.d/puppet reload > /dev/null 2>&1 || true
endscript
}

After running the logrotate script we have this message in syslog:

Apr 29 09:36:12 puppet1 puppet-master[3109]: Caught USR2; calling reopen_logs Apr 29 09:36:12 puppet1 puppet-master[3109]: Reopening log files

The problem is that the logrotate does not create a new masterhttp.log. We tried it with Puppet-3.4.2, 3.4.3 and 3.5.1.

Regards - Willi







Felix Frank

unread,
May 5, 2014, 8:14:33 AM5/5/14
to puppet...@googlegroups.com
On 04/29/2014 06:13 PM, willi....@home24.de wrote:
> The problem is that the logrotate does not create a new masterhttp.log. We tried it with Puppet-3.4.2, 3.4.3 and 3.5.1.

So, that is a logrotate problem then? Maybe ask those guys?

masterhttp.log...are you running webrick?

Thanks,
Felix

Joachim Schrod

unread,
May 5, 2014, 8:07:42 PM5/5/14
to puppet...@googlegroups.com
I can add that it doesn't work in 3.3.1 on openSUSE 12.x either.
Signal USR2 doesn't work there, log files are not reopened. (I
can't upgrade to 3.5 yet, am waiting for that to check if the
problem is still there.)

I resorted to restart the puppet service, instead of reloading it.

Cheers,
Joachim

--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Joachim Schrod, Roedermark, Germany
Email: jsc...@acm.org

Chris

unread,
May 6, 2014, 5:43:22 PM5/6/14
to puppet...@googlegroups.com
I can't help with the puppet side of things, but try 'copytruncate' in
your logrotate conf instead, and remove the postrotate section.

--
Postgresql & php tutorials
http://www.designmagick.com/

Reply all
Reply to author
Forward
0 new messages