]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mds: fix mds damaged due to unexpected journal length 24463/head
authorZhi Zhang <willzzhang@tencent.com>
Thu, 20 Sep 2018 02:55:46 +0000 (10:55 +0800)
committerPrashant D <pdhange@redhat.com>
Sun, 7 Oct 2018 22:44:50 +0000 (18:44 -0400)
commit6d16821712ba699749882921777d27396c93a39f
treec4e87d585c538369c46f4d3dc2e6e9021b3e37c6
parent87b5e7c4255796bdd4391cfa2e16959109047531
mds: fix mds damaged due to unexpected journal length

We used first next_safe_pos in pending_safe to update journal's safe_pos, but
it might not be flushed at this time, so journal's header may get incorrect
write_pos in some case, which could cause mds damaged.

This fix is trying to use current min next_safe_pos in pending_safe to update
journal's safe_pos.

Signed-off-by: Zhi Zhang <zhangz.david@outlook.com>
(cherry picked from commit d17790f299c282dff9c28569b10c46a54b4cfd51)

Conflicts:
src/osdc/Journaler.cc : Resolved in _finish_flush
src/osdc/Journaler.cc