← Back to team overview

registry team mailing list archive

[Bug 676026] Re: Nova services do not log to new log file after log rotation

 

I actually just finally looked into this issue myself because another
symptom of this bug is that you end up with a bazillion log files after
a few weeks.  Here's my understanding of the issue:

- Nova's logging does not support log rotation, because it currently
opens the logfile at launch and holds that one filehandle for the
duration of the daemon's existence.  When logrotate runs, the file
descriptor changes but nova never finds out.  One way to deal with this
would be to allow nova daemons to reopen the logfile file handle when it
receives a SIGHUP.  See nova/server.py for the logging setup.

- The logrotate script is included with Soren's ppa-lucid branch and is
not part of trunk.  I assume it was an afterthought, because the
configuration simply tells logrotate to rotate *every* file in the
/var/log/nova directory.  So even the rotated logs get rotated.

- There is one possible workaround: If you don't include the --logfile
flag but set --use_syslog=1 then the nova daemon will log to syslog, so
logrotate should work OK.

-- 
Nova services do not log to new log file after log rotation
https://bugs.launchpad.net/bugs/676026
You received this bug notification because you are a member of Registry
Administrators, which is subscribed to OpenStack.



References