]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
osd: Remove check on osd_pg_delete_cost change
authorAishwarya Mathuria <amathuri@redhat.com>
Fri, 9 Feb 2024 07:01:35 +0000 (07:01 +0000)
committerAishwarya Mathuria <amathuri@redhat.com>
Tue, 26 Mar 2024 11:26:03 +0000 (16:56 +0530)
With the new cost estimation technique, we don't need osd_pg_delete_cost to be hard-coded to one particular value.
Hence we can now remove the check we had previously added to prevent users from modifying deletion cost with mClock.

Signed-off-by: Aishwarya Mathuria <amathuri@redhat.com>
(cherry picked from commit 56c681c39a35686368e43e3baabcc7e7c5bd8b72)

src/osd/OSD.cc
src/osd/OSD.h

index b0a6fc9241bb570c9dd25408715a1a3780542cb5..1098e4c66ace30c25b97d7eb304bc27483d3fdee 100644 (file)
@@ -4073,7 +4073,6 @@ int OSD::init()
 
   // Override a few options if mclock scheduler is enabled.
   maybe_override_sleep_options_for_qos();
-  maybe_override_cost_for_qos();
   maybe_override_options_for_qos();
   maybe_override_max_osd_capacity_for_qos();
 
@@ -9886,9 +9885,6 @@ void OSD::handle_conf_change(const ConfigProxy& conf,
       changed.count("osd_recovery_sleep_hybrid")) {
     maybe_override_sleep_options_for_qos();
   }
-  if (changed.count("osd_pg_delete_cost")) {
-    maybe_override_cost_for_qos();
-  }
   if (changed.count("osd_min_recovery_priority")) {
     service.local_reserver.set_min_priority(cct->_conf->osd_min_recovery_priority);
     service.remote_reserver.set_min_priority(cct->_conf->osd_min_recovery_priority);
@@ -10225,15 +10221,6 @@ void OSD::maybe_override_sleep_options_for_qos()
   }
 }
 
-void OSD::maybe_override_cost_for_qos()
-{
-  // If the scheduler enabled is mclock, override the default PG deletion cost
-  // so that mclock can meet the QoS goals.
-  if (op_queue_type_t::mClockScheduler == osd_op_queue_type()) {
-    uint64_t pg_delete_cost = 1048576;
-    cct->_conf.set_val("osd_pg_delete_cost", std::to_string(pg_delete_cost));
-  }
-}
 
 /**
  * A context for receiving status from a background mon command to set
index 5909ad246f736605fd27a68c0aa8b0d7c6e55b82..b294aba7e0f02ff66cd85a4a3a86f50236185121 100644 (file)
@@ -1994,7 +1994,6 @@ private:
   void maybe_override_sleep_options_for_qos();
   bool maybe_override_options_for_qos(
     const std::set<std::string> *changed = nullptr);
-  void maybe_override_cost_for_qos();
   int run_osd_bench_test(int64_t count,
                          int64_t bsize,
                          int64_t osize,