summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSage Weil <sage@inktank.com>2013-04-06 13:54:10 -0700
committerSage Weil <sage@inktank.com>2013-04-06 13:54:43 -0700
commitf5ba0fbbe73e11418634bc95e1fc36d17edccf37 (patch)
tree1d93ddf57d93cd281fca8fa2e459217a69bea9c0
parent628e9ae26db0d7765caffd4035903dcaa0429c89 (diff)
downloadceph-f5ba0fbbe73e11418634bc95e1fc36d17edccf37.tar.gz
mon: make 'osd crush move ...' idempotent
If we don't need to move the item, return success. Signed-off-by: Sage Weil <sage@inktank.com>
-rw-r--r--src/mon/OSDMonitor.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mon/OSDMonitor.cc b/src/mon/OSDMonitor.cc
index e8cf2c84280..a9d68075cd4 100644
--- a/src/mon/OSDMonitor.cc
+++ b/src/mon/OSDMonitor.cc
@@ -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);
}