]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
cephfs-journal-tool:: Don't reset the journal trim position 65577/head
authorKotresh HR <khiremat@redhat.com>
Thu, 18 Sep 2025 06:41:11 +0000 (06:41 +0000)
committerKotresh HR <khiremat@redhat.com>
Thu, 18 Sep 2025 18:12:03 +0000 (18:12 +0000)
If the fs had to go through journal recovery and reset,
the cephfs-journal-tool resets the journal trim position
because of which the old unused journal objects just stay
forever in the metadata pool. The patch fixes the issue.
Now, the old stale journal objects are trimmed during the
regular trimming cycle helping to recover space in the
metadata pool.

Fixes: https://tracker.ceph.com/issues/69708
Signed-off-by: Kotresh HR <khiremat@redhat.com>
src/tools/cephfs/Resetter.cc

index 92996fd968507adc4154b1b9d8a942b936d54fff..33d3b57a91dcbfcfde64c33ed0ac706ecd0872bc 100644 (file)
@@ -119,7 +119,6 @@ int Resetter::reset()
   journaler.set_read_pos(new_start);
   journaler.set_write_pos(new_start);
   journaler.set_expire_pos(new_start);
-  journaler.set_trimmed_pos(new_start);
   journaler.set_writeable();
 
   cout << "writing journal head" << std::endl;