diff options
author | Yingxin <yingxin.cheng@intel.com> | 2022-07-29 03:31:19 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-29 03:31:19 +0200 |
commit | a73b295d6bbf8cd17fdad59124102e703127e31b (patch) | |
tree | 1dde780fc63ab927b5730e62c1a578b0049de26d /src/crimson/os/seastore/journal | |
parent | Merge pull request #47275 from myoungwon/wip-rbm-cleanup (diff) | |
parent | crimson/os/seastore: set tail to the last-known journal head under the full trim (diff) | |
download | ceph-a73b295d6bbf8cd17fdad59124102e703127e31b.tar.xz ceph-a73b295d6bbf8cd17fdad59124102e703127e31b.zip |
Merge pull request #47291 from cyx1231st/wip-seastore-journal-head
crimson/os/seastore: fixes to trimming
Reviewed-by: Myoungwon Oh <myoungwon.oh@samsung.com>
Diffstat (limited to 'src/crimson/os/seastore/journal')
-rw-r--r-- | src/crimson/os/seastore/journal/segment_allocator.cc | 2 | ||||
-rw-r--r-- | src/crimson/os/seastore/journal/segmented_journal.cc | 8 |
2 files changed, 2 insertions, 8 deletions
diff --git a/src/crimson/os/seastore/journal/segment_allocator.cc b/src/crimson/os/seastore/journal/segment_allocator.cc index 81c937bfda9..b96032f9e89 100644 --- a/src/crimson/os/seastore/journal/segment_allocator.cc +++ b/src/crimson/os/seastore/journal/segment_allocator.cc @@ -68,8 +68,6 @@ SegmentAllocator::do_open(bool is_mkfs) }; dirty_tail = mkfs_seq; alloc_tail = mkfs_seq; - segment_provider.update_journal_tails( - dirty_tail, alloc_tail); } else { ceph_assert(dirty_tail != JOURNAL_SEQ_NULL); ceph_assert(alloc_tail != JOURNAL_SEQ_NULL); diff --git a/src/crimson/os/seastore/journal/segmented_journal.cc b/src/crimson/os/seastore/journal/segmented_journal.cc index 3e32ada9eb1..e7d0559648d 100644 --- a/src/crimson/os/seastore/journal/segmented_journal.cc +++ b/src/crimson/os/seastore/journal/segmented_journal.cc @@ -199,12 +199,8 @@ SegmentedJournal::scan_last_segment( decode(tail_delta, delta.bl); auto start_seq = locator.write_result.start_seq; INFO("got {}, at seq {}", tail_delta, start_seq); - if (tail_delta.alloc_tail == JOURNAL_SEQ_NULL) { - tail_delta.alloc_tail = start_seq; - } - if (tail_delta.dirty_tail == JOURNAL_SEQ_NULL) { - tail_delta.dirty_tail = start_seq; - } + ceph_assert(tail_delta.dirty_tail != JOURNAL_SEQ_NULL); + ceph_assert(tail_delta.alloc_tail != JOURNAL_SEQ_NULL); segment_provider.update_journal_tails( tail_delta.dirty_tail, tail_delta.alloc_tail); } |