For non-btrfs file systems we should tolerate EEXIST because we may
replay the event more than once.
Signed-off-by: Sage Weil <sage@newdream.net>
else if (r == -ENOTEMPTY) {
assert(0 == "ENOTEMPTY suggests garbage data in osd data dir");
}
+ else if (r == -EEXIST && op == Transaction::OP_MKCOLL && replaying && !btrfs) {
+ dout(10) << "tolerating EEXIST during journal replay on non-btrfs" << dendl;
+ }
else if (r < 0) {
dout(0) << " error " << cpp_strerror(r) << " not handled" << dendl;
assert(0 == "unexpected error");
return err;
}
+ replaying = true;
+
int count = 0;
while (1) {
bufferlist bl;
seq++; // we expect the next op
}
+ replaying = false;
+
applied_seq = op_seq;
// done reading, make writeable.
list<uint64_t> ops_submitting;
list<Cond*> ops_apply_blocked;
+ bool replaying;
+
protected:
void journal_start();
void journal_stop();
open_ops(0), blocked(false),
journal(NULL), finisher(g_ceph_context),
journal_lock("JournalingObjectStore::journal_lock"),
- com_lock("JournalingObjectStore::com_lock") { }
+ com_lock("JournalingObjectStore::com_lock"),
+ replaying(false) { }
};