[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Apache log rotation changes user permission on their log files

On Fri, 1 Mar 2002, Keith Elder wrote:

> When the weekly apache log rotation occurs, the virtual accounts get
> their log files owned by www-data.  Because of this, the users do not
> have access to their log files and so when webalizer runs it doesn't
> have permission to view the logs.  Anyone know how to get around this
> without having to write some script?

Debian's apache log rotation is done by /etc/cron.daily/apache (which
doesn't mean it is rotated "daily").

It tries to figure out user and group from /etc/apache/*.conf files. So it
uses the first "Group" directive.

But this is irrelevant; it can be read by everyone. It uses the savelog(8)
command to do the actual rotation. It uses 644 mode (make a file readable
by anyone and writable by the owner only) for permissions.

What are you using to rotate your apache logs?

  Jeremy C. Reed
echo 'G014AE824B0-07CC?/JJFFFI?D64CB>D=3C427=>;>6HI2><J' |
tr /-_ :\ Sc-y./ | sed swxw`uname`w

Reply to: