From: Sage Weil Date: Fri, 15 Mar 2013 04:10:09 +0000 (-0700) Subject: mon: only try to bump max if leader X-Git-Tag: v0.59~9 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=11650c5a8cd851a64280efbb89826668ef029f10;p=ceph.git mon: only try to bump max if leader I broke this in 4637752db6f8520abba160b4817323379c4a7fe0 when I restructured this function. Only try to increase the max if we are the leader. Signed-off-by: Sage Weil --- diff --git a/src/mon/AuthMonitor.cc b/src/mon/AuthMonitor.cc index 5cf0e22e70fe..998ee0801b21 100644 --- a/src/mon/AuthMonitor.cc +++ b/src/mon/AuthMonitor.cc @@ -343,7 +343,7 @@ uint64_t AuthMonitor::assign_global_id(MAuth *m, bool should_increase_max) bool return_next = (next_global_id <= max_global_id); // bump the max? - while (next_global_id >= max_global_id) { + while (mon->is_leader() && next_global_id >= max_global_id) { increase_max_global_id(); }