[Twisted-Python] Log file ownership
flaviogrossi at ymail.com
Mon Jun 11 03:21:49 EDT 2012
<exarkun <at> twistedmatrix.com> writes:
> Log rotation - ie, renaming a file - isn't affected by the permissions
> of the log file. The permissions of the *directory containing the log
> file* control whether it can be renamed (and a new one created) or not.
> So it doesn't matter what permissions the log file has. It only matters
> what permissions you set on the directory holding the log file. That's
> outside of the control of twistd.
if not (os.access(self.directory, os.W_OK) and os.access(self.path,
it seems to also need write access to log file.
More information about the Twisted-Python