]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: Remove usage of unsupported objstores for QoS 59285/head
authorAishwarya Mathuria <amathuri@redhat.com>
Thu, 13 Jul 2023 18:05:42 +0000 (23:35 +0530)
committerKonstantin Shalygin <k0ste@k0ste.ru>
Sat, 11 Jan 2025 07:15:23 +0000 (14:15 +0700)
mClock is supported on Bluestore and a check is currently done to eliminate other unsupported object stores.
With Filestore no longer in the code base, this check can be removed.
In addition, make sure that osd bench will no longer run on setups with memstore.

Fixes: https://tracker.ceph.com/issues/59531
Signed-off-by: Aishwarya Mathuria <amathuri@redhat.com>
(cherry picked from commit 18043c5e88d241f43b8fd23a8cbc1b15a3854de9)

Conflicts:
  - file: src/osd/OSD.cc
    comment: `OSD::maybe_override_cost_for_qos()` was removed as part of the backport
      that included mClock changes for PG delete operation

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

index 75087cea2d22062b005bcc5ea99a0a1f23073fde..0b5636df9703be1fae4a7698837f43d7980c3662 100644 (file)
@@ -10078,7 +10078,7 @@ void OSD::maybe_override_max_osd_capacity_for_qos()
   // osd bench test. This is later used to setup mclock.
   if ((op_queue_type_t::mClockScheduler == osd_op_queue_type()) &&
       (cct->_conf.get_val<bool>("osd_mclock_skip_benchmark") == false) &&
-      (!unsupported_objstore_for_qos())) {
+      (store->get_type() != "memstore")) {
     std::string max_capacity_iops_config;
     bool force_run_benchmark =
       cct->_conf.get_val<bool>("osd_mclock_force_run_benchmark_on_init");
@@ -10182,8 +10182,7 @@ bool OSD::maybe_override_options_for_qos(const std::set<std::string> *changed)
 {
   // Override options only if the scheduler enabled is mclock and the
   // underlying objectstore is supported by mclock
-  if (op_queue_type_t::mClockScheduler == osd_op_queue_type() &&
-      !unsupported_objstore_for_qos()) {
+  if (op_queue_type_t::mClockScheduler == osd_op_queue_type()) {
     static const std::map<std::string, uint64_t> recovery_qos_defaults {
       {"osd_recovery_max_active", 0},
       {"osd_recovery_max_active_hdd", 3},
@@ -10284,8 +10283,7 @@ void OSD::maybe_override_sleep_options_for_qos()
 {
   // Override options only if the scheduler enabled is mclock and the
   // underlying objectstore is supported by mclock
-  if (op_queue_type_t::mClockScheduler == osd_op_queue_type() &&
-      !unsupported_objstore_for_qos()) {
+  if (op_queue_type_t::mClockScheduler == osd_op_queue_type()) {
     // Override the various sleep settings
     // Disable recovery sleep
     cct->_conf.set_val("osd_recovery_sleep", std::to_string(0));
@@ -10370,14 +10368,6 @@ void OSD::mon_cmd_set_config(const std::string &key, const std::string &val)
   monc->start_mon_command(vcmd, {}, nullptr, nullptr, on_finish);
 }
 
-bool OSD::unsupported_objstore_for_qos()
-{
-  static const std::vector<std::string> unsupported_objstores = { "filestore" };
-  return std::find(unsupported_objstores.begin(),
-                   unsupported_objstores.end(),
-                   store->get_type()) != unsupported_objstores.end();
-}
-
 op_queue_type_t OSD::osd_op_queue_type() const
 {
   /**
index 44976e33bf3b7e88395595fcffedbf86d2b17e81..a54d49975eb9fd7707a62b11d6cd2c9aab9f1e5f 100644 (file)
@@ -2038,7 +2038,6 @@ private:
                          double *elapsed,
                          std::ostream& ss);
   void mon_cmd_set_config(const std::string &key, const std::string &val);
-  bool unsupported_objstore_for_qos();
 
   void scrub_purged_snaps();
   void probe_smart(const std::string& devid, std::ostream& ss);