diff options
author | Tommi Virtanen <tv@inktank.com> | 2012-10-05 09:22:34 -0700 |
---|---|---|
committer | Tommi Virtanen <tv@inktank.com> | 2012-10-05 15:43:18 -0700 |
commit | 13b448b8ce959f31d07cd1827614c445c410aa62 (patch) | |
tree | 68f2f1fbc60c8701dfc22adb10c4981c37d6d93d /src/upstart | |
parent | d9dfa2d17859ca07d735b8e35c5dc00a25995153 (diff) | |
download | ceph-13b448b8ce959f31d07cd1827614c445c410aa62.tar.gz |
upstart: OSD journal can be a symlink; if it's dangling, don't start.
This lets a $osd_data/journal symlink point to
/dev/disk/by-partuuid/UUID and the osd will not attempt to start until
that disk is available.
Signed-off-by: Tommi Virtanen <tv@inktank.com>
Diffstat (limited to 'src/upstart')
-rw-r--r-- | src/upstart/ceph-osd.conf | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/upstart/ceph-osd.conf b/src/upstart/ceph-osd.conf index 119ad000fc4..0e22e6699de 100644 --- a/src/upstart/ceph-osd.conf +++ b/src/upstart/ceph-osd.conf @@ -28,6 +28,13 @@ pre-start script host="$(hostname -s)" \ $location \ || : + + journal="/var/lib/ceph/osd/${cluster:-ceph}-$id/journal" + if [ -L "$journal" -a ! -e "$journal" ]; then + echo "ceph-osd($UPSTART_INSTANCE): journal not present, not starting yet." 1>&2 + stop + exit 0 + fi end script instance ${cluster:-ceph}/$id |