]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mon: make 'osd crush move ...' idempotent
authorSage Weil <sage@inktank.com>
Sat, 6 Apr 2013 20:54:10 +0000 (13:54 -0700)
committerSage Weil <sage@inktank.com>
Sat, 6 Apr 2013 20:54:43 +0000 (13:54 -0700)
If we don't need to move the item, return success.

Signed-off-by: Sage Weil <sage@inktank.com>
src/mon/OSDMonitor.cc

index e8cf2c84280de18e89944a7060b42117628c6e93..a9d68075cd4cf192631d8111053431172695155f 100644 (file)
@@ -2656,7 +2656,8 @@ bool OSDMonitor::prepare_command(MMonCommand *m)
            return true;
          }
        } else {
-           ss << "no need to move item id " << id << " name '" << name << "' to location " << loc << " in crush map";
+         ss << "no need to move item id " << id << " name '" << name << "' to location " << loc << " in crush map";
+         err = 0;
        }
       } while (false);
     }