From 2e1141e43980a0a44b18159860ebf9cc38316435 Mon Sep 17 00:00:00 2001 From: Aishwarya Mathuria Date: Fri, 12 Mar 2021 16:57:40 +0530 Subject: [PATCH] mon: Modifying trim logic to change paxos_service_trim_max dynamically Currently, the Paxos Service trim logic is bounded by a max value (paxos_service_trim_max). This change dynamically modifies the max value when the number of logs to be trimmed is higher than paxos_service_trim_max. The paxos_service_trim_max_multiplier has been added in case we want to increase paxos_service_trim_max by a certain factor. If this option is enabled we get a new upper bound when trim sizes are high. Fixes: https://tracker.ceph.com/issues/50004 Signed-off-by: Aishwarya Mathuria --- doc/rados/configuration/mon-config-ref.rst | 10 +++++++- src/common/options.cc | 11 ++++++-- src/mon/PaxosService.cc | 29 +++++++++++++++------- 3 files changed, 38 insertions(+), 12 deletions(-) diff --git a/doc/rados/configuration/mon-config-ref.rst b/doc/rados/configuration/mon-config-ref.rst index fbf50b53de99..02e9b6b79dc6 100644 --- a/doc/rados/configuration/mon-config-ref.rst +++ b/doc/rados/configuration/mon-config-ref.rst @@ -766,7 +766,15 @@ Trimming requires that the placement groups are ``active+clean``. :Default: ``500`` -``mon_mds_force_trim_to`` +``paxos service trim max multiplier`` + +:Description: The factor by which paxos service trim max will be multiplied + to get a new upper bound when trim sizes are high (0 disables it) +:Type: Integer +:Default: ``20`` + + +``mon mds force trim to`` :Description: Force monitor to trim mdsmaps to this point (0 disables it. dangerous, use with care) diff --git a/src/common/options.cc b/src/common/options.cc index 8003b4bdcb60..c325e03d69fb 100644 --- a/src/common/options.cc +++ b/src/common/options.cc @@ -2281,16 +2281,23 @@ std::vector