mirror of
https://git.proxmox.com/git/ceph.git
synced 2025-04-28 15:01:36 +00:00
cherry-pick fix for extending OSD log
Reported-by: Laurențiu Leahu-Vlăducu <l.leahu-vladucu@proxmox.com> Suggested-by: Laurențiu Leahu-Vlăducu <l.leahu-vladucu@proxmox.com> Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
b95a2f1b53
commit
71ce71edd9
34
patches/0020-os-bluestore-fix-_extend_log-seq-advance.patch
Normal file
34
patches/0020-os-bluestore-fix-_extend_log-seq-advance.patch
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Pere Diaz Bou <pdiabou@redhat.com>
|
||||||
|
Date: Fri, 29 Sep 2023 13:17:03 +0200
|
||||||
|
Subject: [PATCH] os/bluestore: fix _extend_log seq advance
|
||||||
|
|
||||||
|
when extending the log, the sequence was left on a bad state because it would first create a transaction to update with the current seq number but leave the "real" transaction with the same sequence number which should be `extend_log_transaction.seq + 1`.
|
||||||
|
|
||||||
|
Signed-off-by: Pere Diaz Bou <pdiabou@redhat.com>
|
||||||
|
(cherry picked from commit 63f0a0df14c9d8e68be61e374438bc75cef45a1f)
|
||||||
|
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
|
||||||
|
---
|
||||||
|
src/os/bluestore/BlueFS.cc | 5 +++--
|
||||||
|
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/os/bluestore/BlueFS.cc b/src/os/bluestore/BlueFS.cc
|
||||||
|
index 1c14cd24d1d..eefdc334967 100644
|
||||||
|
--- a/src/os/bluestore/BlueFS.cc
|
||||||
|
+++ b/src/os/bluestore/BlueFS.cc
|
||||||
|
@@ -3108,12 +3108,13 @@ void BlueFS::_extend_log(uint64_t amount) {
|
||||||
|
_pad_bl(bl, super.block_size);
|
||||||
|
log.writer->append(bl);
|
||||||
|
ceph_assert(allocated_before_extension >= log.writer->get_effective_write_pos());
|
||||||
|
- log.t.seq = log.seq_live;
|
||||||
|
|
||||||
|
// before sync_core we advance the seq
|
||||||
|
{
|
||||||
|
std::unique_lock<ceph::mutex> l(dirty.lock);
|
||||||
|
- _log_advance_seq();
|
||||||
|
+ dirty.seq_live++;
|
||||||
|
+ log.seq_live++;
|
||||||
|
+ log.t.seq++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -18,3 +18,4 @@
|
|||||||
0017-mgr-dashboard-remove-ability-to-create-and-check-TLS.patch
|
0017-mgr-dashboard-remove-ability-to-create-and-check-TLS.patch
|
||||||
0018-debian-recursively-adjust-permissions-of-var-lib-cep.patch
|
0018-debian-recursively-adjust-permissions-of-var-lib-cep.patch
|
||||||
0019-ceph-crash-change-order-of-client-names.patch
|
0019-ceph-crash-change-order-of-client-names.patch
|
||||||
|
0020-os-bluestore-fix-_extend_log-seq-advance.patch
|
||||||
|
Loading…
Reference in New Issue
Block a user