mirror of
https://github.com/ceph/ceph
synced 2024-12-18 01:16:55 +00:00
ceph-disk: tolerate /sbin/service or /usr/sbin/service
CentOS/RH has it in /sbin, others in /usr/sbin. Backport: bobtail Signed-off-by: Sage Weil <sage@inktank.com>
This commit is contained in:
parent
c2bcc2a60c
commit
cd1d6fb3f9
@ -1311,9 +1311,13 @@ def start_daemon(
|
||||
],
|
||||
)
|
||||
elif os.path.exists(os.path.join(path, 'sysvinit')):
|
||||
if os.path.exists('/usr/sbin/service'):
|
||||
svc = '/usr/sbin/service'
|
||||
else:
|
||||
svc = '/sbin/service'
|
||||
subprocess.check_call(
|
||||
args=[
|
||||
'/usr/sbin/service',
|
||||
svc,
|
||||
'ceph',
|
||||
'start',
|
||||
'osd.{osd_id}'.format(osd_id=osd_id),
|
||||
|
Loading…
Reference in New Issue
Block a user