]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
vstart: bail out if "-k" and old config is not readable 8305/head
authorKefu Chai <kchai@redhat.com>
Fri, 22 Apr 2016 16:47:26 +0000 (00:47 +0800)
committerKefu Chai <kchai@redhat.com>
Fri, 22 Apr 2016 16:47:28 +0000 (00:47 +0800)
Signed-off-by: Kefu Chai <kchai@redhat.com>
src/vstart.sh

index cca89da2d46383e406a9771d7cbc2175a824ff15..30eac4c707b23f108b3f5a1b2474c18c1372ee25 100755 (executable)
@@ -231,6 +231,10 @@ case $1 in
            cephx=0
            ;;
     -k )
+           if [ ! -r $conf_fn ]; then
+               echo "cannot use old configuration: $conf_fn not readable." >&2
+               exit
+           fi
            overwrite_conf=0
            ;;
     --memstore )