From: Tommi Virtanen Date: Mon, 17 Sep 2012 15:55:14 +0000 (-0700) Subject: ceph-disk-activate, upstart: Use "initctl emit" to start OSDs. X-Git-Tag: v0.48.2argonaut~8 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=16aca749989b006f4d5d2190ed1e8480c1bf0282;p=ceph.git ceph-disk-activate, upstart: Use "initctl emit" to start OSDs. This avoids an error if the daemon was running already, and is already being done with the other services. Signed-off-by: Tommi Virtanen --- diff --git a/src/ceph-disk-activate b/src/ceph-disk-activate index 17e520dde222..225e2a664ea9 100755 --- a/src/ceph-disk-activate +++ b/src/ceph-disk-activate @@ -276,7 +276,9 @@ def upstart_start( subprocess.check_call( args=[ 'initctl', - 'start', + # use emit, not start, because start would fail if the + # instance was already running + 'emit', # since the daemon starting doesn't guarantee much about # the service being operational anyway, don't bother # waiting for it diff --git a/src/upstart/ceph-osd.conf b/src/upstart/ceph-osd.conf index 7a976c2397a4..119ad000fc49 100644 --- a/src/upstart/ceph-osd.conf +++ b/src/upstart/ceph-osd.conf @@ -1,5 +1,6 @@ description "Ceph OSD" +start on ceph-osd stop on runlevel [!2345] respawn