From: John Spray Date: Tue, 29 Apr 2014 15:01:52 +0000 (+0100) Subject: mon: don't require 'sure' flag for new fs X-Git-Tag: v0.84~164^2~12 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=243963c1225239d9f80e27921bc53ecf24b0c20b;p=ceph.git mon: don't require 'sure' flag for new fs Only prompt for --yes-i-really-mean-it if there is an existing FS. Signed-off-by: John Spray --- diff --git a/src/mon/MDSMonitor.cc b/src/mon/MDSMonitor.cc index f225197288cc..2b5e8ac79ca3 100644 --- a/src/mon/MDSMonitor.cc +++ b/src/mon/MDSMonitor.cc @@ -1154,7 +1154,7 @@ bool MDSMonitor::prepare_command(MMonCommand *m) string sure; cmd_getval(g_ceph_context, cmdmap, "sure", sure); - if (sure != "--yes-i-really-mean-it") { + if (pending_mdsmap.enabled && sure != "--yes-i-really-mean-it") { ss << "this is DANGEROUS and will wipe out the mdsmap's fs, and may clobber data in the new pools you specify. add --yes-i-really-mean-it if you do."; r = -EPERM; } else {