]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mon: disable 'osd setmap'
authorSage Weil <sage@newdream.net>
Wed, 17 Feb 2010 17:18:16 +0000 (09:18 -0800)
committerSage Weil <sage@newdream.net>
Wed, 17 Feb 2010 17:18:16 +0000 (09:18 -0800)
This is dangerous, since it doesn't preserve old pool ids or pool_max, and
will confuse osds and generally wreak havoc.

src/TODO
src/mon/OSDMonitor.cc

index 6af90b56efe1f9e000dd05e79d9b206a1aa3d5c0..d61544d8385e3dfefdb1bd122df479ad1fd36ad4 100644 (file)
--- a/src/TODO
+++ b/src/TODO
@@ -54,8 +54,6 @@ v0.20
 
 
 bugs
-- './ceph osd setmap foo -i foo' will clobber old pools.
-
 - dbench 1, restart mds (may take a few times), dbench will error out.
 
 - rm -r failure (on kernel tree)
index 6194759243905f6a94a99293c62c839574443f88..df2ca6af96fbf420bdebefc2ffb671de73bcc180 100644 (file)
@@ -1036,7 +1036,7 @@ bool OSDMonitor::prepare_command(MMonCommand *m)
       paxos->wait_for_commit(new Monitor::C_Command(mon, m, 0, rs, paxos->get_version()));
       return true;
     }
-    else if (m->cmd[1] == "setmap" && m->cmd.size() == 3) {
+    /*else if (m->cmd[1] == "setmap" && m->cmd.size() == 3) {
       OSDMap map;
       map.decode(m->get_data());
       epoch_t e = atoi(m->cmd[2].c_str());
@@ -1053,6 +1053,7 @@ bool OSDMonitor::prepare_command(MMonCommand *m)
          ss << "osdmap fsid " << map.fsid << " does not match monitor fsid " << mon->monmap->fsid;
       err = -EINVAL;
     }
+    */
     else if (m->cmd[1] == "setmaxosd" && m->cmd.size() > 2) {
       pending_inc.new_max_osd = atoi(m->cmd[2].c_str());
       ss << "set new max_osd = " << pending_inc.new_max_osd;