zeoctl logreopen doesn't work
Hi, since i'm running my zeo.log at debug level in grows quite large. I've tried to rotate the log daily by renaming the zeo.log and call zeoctl logreopen. ./bin/zeoctl logreopen kill(6319, 31) signal 31 sent to process 6319 But no new zeo.log is created and all log entries still go to the old file. How can I get zeo to create a new logfile without restarting the zeo server completely. Bye Estartu ---------------------------------------------------------------------------- Gerhard Schmidt | Nick : estartu IRC : Estartu | Fischbachweg 3 | | PGP Public Key 86856 Hiltenfingen | EMail: estartu@augusta.de | on request Germany | |
--On 13. September 2006 10:00:12 +0200 Gerhard Schmidt <estartu@ze.tum.de> wrote:
Hi,
since i'm running my zeo.log at debug level in grows quite large. I've tried to rotate the log daily by renaming the zeo.log and call zeoctl logreopen.
./bin/zeoctl logreopen kill(6319, 31) signal 31 sent to process 6319
But no new zeo.log is created and all log entries still go to the old file.
How can I get zeo to create a new logfile without restarting the zeo
# Likely a bug. File a bugreport! -aj
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 13 Sep 2006, at 10:00, Gerhard Schmidt wrote:
How can I get zeo to create a new logfile without restarting the zeo server completely.
If on Linux, use the standard logrotate utility with the keyword "copytruncate". That will safely truncate the log file to zero length and copy it to the side and you don't need to restart anything. jens -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (Darwin) iD8DBQFFB8ARRAx5nvEhZLIRAhjIAJ98IsBiL26rKYA2xmAsIjMd3J0wcACfXNCg G00297pWjMFnQ4UKF4zQvoA= =BetG -----END PGP SIGNATURE-----
On Sep 13, 2006, at 4:00 AM, Gerhard Schmidt wrote:
But no new zeo.log is created and all log entries still go to the old file.
It looks like that wasn't implemented and just sort of stubbed out. The method that gets called with logrotate looks like this: def handle_sigusr2(self): # TODO: this used to reinitialize zLOG. How do I achieve # the same effect with Python's logging package? # Should we restart as with SIGHUP? log("received SIGUSR2, but it was not handled!", level=logging.WARNING)
participants (4)
-
Andreas Jung -
Andrew Langmead -
Gerhard Schmidt -
Jens Vagelpohl