summaryrefslogtreecommitdiff
path: root/src/mkcephfs.in
diff options
context:
space:
mode:
authorSamuel Just <samuel.just@dreamhost.com>2011-02-17 11:43:58 -0800
committerSamuel Just <samuel.just@dreamhost.com>2011-02-17 11:53:27 -0800
commitda416004bc15397b1d11d58baa2bad91acfded86 (patch)
treea976063e5faeb2256102befe8e9c24152a01e305 /src/mkcephfs.in
parent040663255e5d71a98d03b1308647b168b59a290c (diff)
downloadceph-da416004bc15397b1d11d58baa2bad91acfded86.tar.gz
mkcephfs: fix premature tmp directory deletion
Previously, the temp directory would be deleted after the first daemon on a host was started leaving the second one to fail. Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
Diffstat (limited to 'src/mkcephfs.in')
-rw-r--r--src/mkcephfs.in6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mkcephfs.in b/src/mkcephfs.in
index a754165f49b..a4c60adee2b 100644
--- a/src/mkcephfs.in
+++ b/src/mkcephfs.in
@@ -282,6 +282,12 @@ for name in $what; do
fi
rm -f $TDIR/keyring.mds.$id
fi
+done
+
+for name in $what; do
+ type=`echo $name | cut -c 1-3` # e.g. 'mon', if $name is 'mon1'
+ id=`echo $name | cut -c 4- | sed 's/\\.//'`
+ num=$id
if [ -n "$ssh" ]; then
ssh $host rm -rf $TDIR
fi