Project

General

Profile

Bug #9656

Remove conditional statement in ceph-radosgw startup script log section

Added by Tupper Cole over 9 years ago. Updated almost 6 years ago.

Status:
Rejected
Priority:
High
Assignee:
-
Category:
-
Target version:
-
% Done:

0%

Source:
other
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

The startup script has a conditional statement to determine if a log file exists, and will touch and chown the log file appropriately if it does not (excepted below). When logrotate executes, it moves the old log file then creates a new /var/log/radosgw/radosgw.log as root. When the radosgw service is restarted the file exists, but with the wrong permissions. It seems there is no harm in chowning and touching the file on every start\restart to insure correct permissions.

<snip>
log_file=`$RADOSGW -n $name --show-config-value log_file`
if [ -n "$log_file" ] && [ ! -e "$log_file" ]; then
touch "$log_file"
chown $user $log_file
fi

History

#1 Updated by Sage Weil over 9 years ago

  • Priority changed from Normal to High

Hmm yeah. I think the better solution would be to fix the /var/log/ceph (/var/log/radosgw?) permissions so that log files can be created there with the correct initial ownership/permissions? I think we need to create a ceph user and group and g+s on the dir or something..

#2 Updated by Sage Weil almost 6 years ago

  • Status changed from New to Rejected

Also available in: Atom PDF