Christian wrote:
[...] drwxr-xr-x 2 root root /var/log/foo/ -rw-rw-r-- 2 foo bar /var/log/foo/foo.log
Am 23.02.2012 16:16, schrieb Ludwig Nussel: this won't work e.g. for tinyproxy. tinyproxy creates his logfile as
drwxr-x--- 2 tinyproxy root 80 23. Feb 00:15 ./ drwxr-xr-x 13 root root 1264 22. Feb 22:47 ../ -rw------- 1 tinyproxy tinyproxy 226 23. Feb 00:16 tinyproxy.log
I wouldn't have created this "user-owned" subdir, if tinyproxy would have been able to write his log directly to /var/log. So how should this be fixed ?
The question is whether tinyproxy actually needs to create, unlink or rename the log file. Usually this is not the case. Have you tried creating an empty log file with correct permissions in %post or the init script? I'd expect the typical daemon to be happy with that as it can open the file and append to it then. When logrotate rotates the log it creates an empty log file with correct permissions too. cu Ludwig -- (o_ Ludwig Nussel //\ V_/_ http://www.suse.de/ SUSE LINUX Products GmbH, GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer, HRB 16746 (AG Nürnberg) -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org