From: Sage Weil Date: Tue, 30 Apr 2013 00:01:55 +0000 (-0700) Subject: debian: only start/stop upstart jobs if upstart is present X-Git-Tag: v0.61~46 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=030bf8aaa15837f898e453161eeaf1d52fc5779d;p=ceph.git debian: only start/stop upstart jobs if upstart is present This avoids errors on non-upstart distros (like wheezy). Signed-off-by: Sage Weil --- diff --git a/debian/ceph-mds.postinst b/debian/ceph-mds.postinst index dfe02d2308ef..7fcbf5c62304 100644 --- a/debian/ceph-mds.postinst +++ b/debian/ceph-mds.postinst @@ -20,7 +20,7 @@ set -e case "$1" in configure) - start ceph-mds-all || : + [ -x /sbin/start ] && start ceph-mds-all || : ;; abort-upgrade|abort-remove|abort-deconfigure) : diff --git a/debian/ceph-mds.prerm b/debian/ceph-mds.prerm index 56d9e0128f10..c4af0994d948 100644 --- a/debian/ceph-mds.prerm +++ b/debian/ceph-mds.prerm @@ -1,5 +1,5 @@ #!/bin/sh -stop ceph-mds-all || : +[ -x /sbin/stop ] && stop ceph-mds-all || : exit 0 \ No newline at end of file diff --git a/debian/ceph.postinst b/debian/ceph.postinst index 4edbf10d93b6..090a91aa9bb3 100644 --- a/debian/ceph.postinst +++ b/debian/ceph.postinst @@ -27,7 +27,7 @@ set -e case "$1" in configure) rm -f /etc/init/ceph.conf - start ceph-all || : + [ -x /sbin/start ] && start ceph-all || : ;; abort-upgrade|abort-remove|abort-deconfigure) : diff --git a/debian/ceph.prerm b/debian/ceph.prerm index 159a96e33c39..557a1dbdac05 100644 --- a/debian/ceph.prerm +++ b/debian/ceph.prerm @@ -1,5 +1,5 @@ #!/bin/sh -stop ceph-all || : +[ -x /sbin/stop ] && stop ceph-all || : exit 0 \ No newline at end of file