]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mon: Monitor: do not reopen MonitorDBStore during conversion
authorJoao Eduardo Luis <joao.luis@inktank.com>
Tue, 16 Jul 2013 15:45:39 +0000 (16:45 +0100)
committerSage Weil <sage@inktank.com>
Tue, 16 Jul 2013 17:31:46 +0000 (10:31 -0700)
We already open the store on ceph_mon.cc, before we start the conversion.
Given we are unable to reproduce this every time a conversion is triggered,
we are led to believe that this causes a race in leveldb that will lead
to 'store.db/LOCK' being locked upon the open this patch removes.

Regardless, reopening the db here is pointless as we already did it when
we reach Monitor::StoreConverter::convert().

Fixes: #5640
Backport: cuttlefish

Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
src/mon/Monitor.cc

index 1282cb359cac49503a638a9d0a16a70c92d2b4f9..5cba9d4f80a6eb78da7e311f1f32bf7250cd0615 100644 (file)
@@ -3851,7 +3851,6 @@ out:
 int Monitor::StoreConverter::convert()
 {
   _init();
-  assert(!db->create_and_open(std::cerr));
   assert(!store->mount());
   if (db->exists("mon_convert", "on_going")) {
     dout(0) << __func__ << " found a mon store in mid-convertion; abort!"