]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/os/seastore: add safety clamp to adaptive hard_limit and crash_floor 69083/head
authorShai Fultheim <shai.fultheim@gmail.com>
Fri, 29 May 2026 09:26:39 +0000 (12:26 +0300)
committerShai Fultheim <shai.fultheim@gmail.com>
Fri, 29 May 2026 09:26:39 +0000 (12:26 +0300)
Signed-off-by: Shai Fultheim <shai.fultheim@gmail.com>
src/crimson/os/seastore/async_cleaner.cc

index e72b3d9d7d92107148dc4dbb89376494e1e3b339..f0e36f82da113a6016063f603aca5d9c5c931ffa 100644 (file)
@@ -1176,7 +1176,8 @@ void SegmentCleaner::maybe_adjust_thresholds()
 
   double crash_floor =
       static_cast<double>(named_writers) * segment_ratio;
-  new_hard_limit = std::max(new_hard_limit, crash_floor);
+  crash_floor = std::min(crash_floor, 0.95);
+  new_hard_limit = std::min(std::max(new_hard_limit, crash_floor), 0.95);
 
   // Apply lazy decay covering elapsed time (allows gc_max to gradually fall
   // when workload eases) so peaks fade even when the background process was