]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
Merge pull request #70153 from ronen-fr/wip-rf-78124ecN
authorRonen Friedman <rfriedma@redhat.com>
Fri, 17 Jul 2026 13:48:06 +0000 (16:48 +0300)
committerGitHub <noreply@github.com>
Fri, 17 Jul 2026 13:48:06 +0000 (16:48 +0300)
mon: require EC optimizations for Crimson EC pools

Reviewed-by: Alex Ainscow <aainscow@uk.ibm.com>
Reviewed-by: Bill Scales <bill_scales@uk.ibm.com>
1  2 
src/mon/OSDMonitor.cc

index 5da90e1222929f8959380a32755a03c9d82c870e,873d26a1f58764ac8496c70902eb62b7d56ba5e9..b6cf780ea733fc41a56146d86410689aa5e6aafb
@@@ -8653,21 -8651,14 +8658,20 @@@ OSDMonitor::enable_pool_ec_optimization
        }
      }
      p.flags |= pg_pool_t::FLAG_EC_OPTIMIZATIONS;
 +
 +    // Automatically enable omap support in fast EC pools
 +    // Omap is not supported by EC pools in crimson
 +    if (!p.is_crimson() && osdmap.require_osd_release >= ceph_release_t::umbrella) {
 +      p.flags |= pg_pool_t::FLAG_OMAP;
 +    }
    } else {
      if ((p.flags & pg_pool_t::FLAG_EC_OPTIMIZATIONS) != 0) {
-       if (ss) {
-         *ss << "allow_ec_optimizations cannot be disabled once enabled";
-       }
-       return -EINVAL;
+       return tl::unexpected(ErrorNMessage{
+         -EINVAL,
+         "allow_ec_optimizations cannot be disabled once enabled"});
      }
    }
-   return 0;
+   return {};
  }
  
  void OSDMonitor::maybe_enable_pool_split_ops(pg_pool_t &p) {