From: Sage Weil Date: Tue, 9 Jul 2013 21:12:15 +0000 (-0700) Subject: mon: do not scrub if scrub is in progress X-Git-Tag: v0.67-rc1~129 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=00ae543b3e32f89d906a0e934792cc5309f57696;p=ceph.git mon: do not scrub if scrub is in progress This prevents an assert from unexpected scrub results from the previous scrub on the leader. Backport: cuttlefish Signed-off-by: Sage Weil --- diff --git a/src/mon/Monitor.cc b/src/mon/Monitor.cc index 76efc6c21e45..b2676ec43576 100644 --- a/src/mon/Monitor.cc +++ b/src/mon/Monitor.cc @@ -4004,6 +4004,11 @@ int Monitor::scrub() return -EOPNOTSUPP; } + if (!scrub_result.empty()) { + clog.info() << "scrub already in progress\n"; + return -EBUSY; + } + scrub_result.clear(); scrub_version = paxos->get_version();