Hallo,
ich habe festgestellt, dass nach der Installation von homegear die Logs nicht rotiert werden. Nach Eingabe von
sudo logrotate -f /etc/logrotate.conf
erhalte ich die folgenden Fehlermeldungen:
error: skipping "/var/log/homegear/homegear.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/homegear/homegear-scriptengine.log" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/homegear/homegear.err" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.
error: skipping "/var/log/homegear/homegear-scriptengine.err" because parent directory has insecure permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell logrotate which user/group should be used for rotation.
Ergänze ich die Datei /etc/logrotate.d/homegear wie folgt um die Zeile “su homegear homegear”, funktioniert logrotate wieder:
/var/log/homegear/*.log /var/log/homegear/*.err {
su homegear homegear
missingok
rotate 2
compress
delaycompress
notifempty
size 10M
create 640 homegear homegear
sharedscripts
postrotate
/etc/init.d/homegear reload > /dev/null
endscript
}
Müsste dieses Problem nicht bei jedem Homegear-Benutzer auftreten?