Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
6a2c8b0
PREREQ: Protect against downlevel OSDs joining the cluster after upgrade
JonBailey1993 May 5, 2026
ee043a4
PREREQ: doc: modify release checklist to ensure its not possible to a…
JonBailey1993 Jul 9, 2026
80545b0
PREREQ: mon/OSDMonitor: refuse the boot of OSDs older than any requir…
aainscow Oct 29, 2026
0cc420d
doc/dev: update the design of erasure coded stretch clusters
aainscow Oct 13, 2026
64a3372
doc/rados: document pools stretched over zones
aainscow Oct 13, 2026
d1fa46d
osd: add num_zones and replica to pg_pool_t
aainscow Oct 8, 2026
b95c4f5
osd/OSDMap: make per-shard primary-first undo follow nonprimary_shards
aainscow Apr 14, 2026
f430467
os/Transaction: add remap_shard()
aainscow Apr 14, 2026
0d7d001
crush, erasure-code: build CRUSH rules for pools over several zones
Ericmzhang Apr 30, 2026
5c83f30
osd, mon, mgr: apply min_size to each zone of a stretch pool
Ericmzhang Jul 29, 2026
c0340e1
mon: build replicated rules over zones
Ericmzhang May 28, 2026
4f5907f
mon: create pools over zones
aainscow Oct 9, 2026
29586fe
mon/ConfigMap: report the section that gives a value
aainscow Apr 28, 2026
5cb8e41
mon: add ceph osd pool default set and get
aainscow Oct 9, 2026
ef0de35
mon: change a pool's num_zones and replica
kamoltat Oct 7, 2026
5ad37cc
mon: stretch mode over per-pool num_zones
aainscow Oct 13, 2026
ba104e1
mon: commit the upgrade to pools over zones
aainscow Oct 9, 2026
206a075
test/osd: extend the EC test fixtures to pools over zones
aainscow Oct 12, 2026
ab0d029
osdc: route split reads by zone
aainscow Oct 5, 2026
91fcdec
osd: match written_shards and shard_versions by relative shard
aainscow Oct 13, 2026
3647595
osd/scrubber: check EC deep scrub CRCs within and across zones
aainscow Sep 23, 2026
dd21316
osd: support erasure coded pools over zones in the EC backend
aainscow Sep 23, 2026
956de1e
osd/PeeringState: choose acting sets for stretched EC pools
kamoltat Jun 5, 2026
ab2c427
osd: catch up complete EC backfill targets from the log
aainscow Oct 12, 2026
8d587ad
test/osd: add zone failover tests for stretched EC pools
aainscow Oct 9, 2026
7e9446a
osd: add cross-zone perf counters for stretched pools
Ericmzhang Oct 13, 2026
5cde71f
scripts: add a zone thrasher for vstart stretch clusters
CJamesIBM Sep 15, 2026
52c67c7
mgr/dashboard: set the copies of a pool over zones as replica
aainscow Oct 26, 2026
507d8de
FIXUP: osdc: route split reads by zone
aainscow Nov 9, 2026
373e7ff
FIXUP: doc/rados: document pools stretched over zones
aainscow Nov 9, 2026
e3feca0
FIXUP: osdc: route split reads by zone
aainscow Nov 10, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions PendingReleaseNotes
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,41 @@
be removed in the X release. People wanting to continue using
Elasticsearch can populate it with bucket notifications. The
upcoming S3 Inventory feature also covers some of the use case.

* RADOS: Erasure-coded (FastEC) and replicated pools can be stretched over two
zones, one pool at a time, with ``ceph osd pool create --num_zones 2`` or
``ceph osd pool set <pool> num_zones 2``. See "Upgrading from Earlier
Releases" in :ref:`stretch_mode`.

- When ``require_osd_release`` is raised to this release, each pool of a
cluster stretched with ``ceph mon enable_stretch_mode`` gets two zones and
a ``min_size`` counted in each zone (2 becomes 1, 3 becomes 2).
- From then on, ``osd_pool_default_size`` counts the copies in each zone of
a stretched pool, replacing ``mon_stretch_pool_size``. Only the value in
the ``global`` section of the configuration database is converted. A value
set in a Monitor's ``ceph.conf`` or in a ``mon`` section is not, and gives
new pools that many copies in each zone. The new
``POOL_DEFAULT_CONFIG_OVERRIDE`` health warning reports such a value:
remove it.

* RADOS: ``ceph osd pool create`` takes named parameters, such as
``--pool_type``, ``--replica``, ``--k`` and ``--m``, and still accepts the
positional ones. A parameter that is not given comes from a pool creation
default, which ``ceph osd pool default set`` and ``ceph osd pool default
get`` manage. See :ref:`pool-creation-defaults`.

* RADOS: An erasure code profile or CRUSH rule, other than the defaults, is
now deleted with the last pool that uses it. Scripts that reuse one after
deleting its pools must create it again.

* RADOS: Changing an erasure code profile that a pool uses now needs
``--yes-i-really-mean-it``: ``--force`` is no longer enough.

* RADOS: When ``require_osd_release`` is raised to this release, each
erasure-coded pool that uses the ``default`` erasure code profile gets a
profile of its own, such as ``mypool-k2-m2``, as does each new pool created
without a named profile.

* RGW: The default value of ``rgw_rest_conn_connect_to_resolved_ips`` changed
from ``false`` to ``true``.

Expand Down
8 changes: 8 additions & 0 deletions doc/dev/osd_internals/ceph_test_rados.rst
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ Synopsis
[--pool-snaps]
[--balance-reads]
[--localize-reads]
[--crush-location <loc>]
[--offlen_randomization_ratio <0-100>]
[--write-fadvise-dontneed]
[--max-attr-len <bytes>]
Expand Down Expand Up @@ -161,6 +162,13 @@ Read Routing
Set ``LIBRADOS_OPERATION_LOCALIZE_READS`` on read operations,
preferring the closest replica.

``--crush-location <loc>``
Set the client's CRUSH location for zone-aware reads (e.g.,
``datacenter=zone-0``). The location is applied via
``crush_location`` in the librados configuration and influences
which OSD shard handles split reads on EC pools. Has no effect
unless the cluster is configured for zone-aware placement.

``--offlen_randomization_ratio <n>``
Percentage chance (0–100) that a read uses a randomized offset
instead of reading from offset 0. Default: ``50``.
Expand Down
4,464 changes: 2,960 additions & 1,504 deletions doc/dev/osd_internals/erasure_coding/ec_stretch_cluster.rst

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions doc/dev/release-checklists.rst
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ Mon
- [x] common/options/global.yaml.in remove `mon_debug_no_require_X-2`
- [x] mon/OSDMonitor.cc `create_initial`: adjust new `require_osd_release`, and add associated `mon_debug_no_require_X`
- [x] mon/OSDMonitor.cc `preprocess_boot`: adjust "disallow boot of " condition to disallow X if `require_osd_release` < X-2.
- [x] common/ceph_releases.cc `ceph_release_server_feature`: return `SERVER_X` for X, so that `preprocess_boot` refuses OSDs of earlier releases once `require_osd_release` is X (`unittest_features` fails until it does)
- [x] mon/OSDMonitor.cc: adjust "osd require-osd-release" to (1) allow setting X, and (2) check that all mons *and* OSDs have X
- [x] mon/MonCommands.h: adjust "osd require-osd-release" allows options to include X
- [x] qa/workunits/cephtool/test.sh: adjust `require-osd-release` test
Expand Down
291 changes: 273 additions & 18 deletions doc/man/8/ceph.rst

Large diffs are not rendered by default.

8 changes: 8 additions & 0 deletions doc/rados/configuration/pool-pg-config-ref.rst
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,22 @@ See :ref:`pg-autoscaler`.
.. confval:: mon_delta_reset_interval
.. confval:: osd_crush_chooseleaf_type
.. confval:: osd_crush_initial_weight
.. confval:: osd_pool_default_type
.. confval:: osd_pool_default_crush_rule
.. confval:: osd_pool_erasure_code_stripe_unit
.. confval:: osd_pool_default_size
.. confval:: osd_pool_default_num_zones
.. confval:: osd_pool_default_zone_failure_domain
.. confval:: osd_pool_default_osd_failure_domain
.. confval:: osd_pool_default_root
.. confval:: osd_pool_default_class
.. confval:: osd_pool_default_min_size
.. confval:: osd_pool_default_pg_num
.. confval:: osd_pool_default_pgp_num
.. confval:: osd_pool_default_pg_autoscale_mode
.. confval:: osd_pool_default_flags
.. confval:: osd_pool_default_flag_bulk
.. confval:: osd_pool_default_crimson
.. confval:: osd_max_pgls
.. confval:: osd_min_pg_log_entries
.. confval:: osd_max_pg_log_entries
Expand Down
45 changes: 42 additions & 3 deletions doc/rados/operations/crush-map.rst
Original file line number Diff line number Diff line change
Expand Up @@ -741,6 +741,9 @@ The relevant erasure-code profile properties are as follows:
a CRUSH MSR rule being created.
* **crush-device-class**: the device class on which to place data [default:
none, which means that all devices are used].
* **crush-zone-failure-domain**: the CRUSH bucket type of the zones of a pool
or rule over more than one zone [default:
:confval:`osd_pool_default_zone_failure_domain`].
* **k** and **m** (and, for the ``lrc`` plugin, **l**): these determine the
number of erasure-code shards, affecting the resulting CRUSH rule.

Expand All @@ -749,12 +752,47 @@ The relevant erasure-code profile properties are as follows:

.. prompt:: bash $

ceph osd crush rule create-erasure {name} {profile-name}
ceph osd crush rule create-erasure {name} {profile-name} [{num_zones}]

``num_zones`` (default ``1``) is the number of zones that the rule spans. A
rule over more than one zone places the ``k+m`` shards in each of
``num_zones`` buckets of the profile's ``crush-zone-failure-domain`` type, or
of :confval:`osd_pool_default_zone_failure_domain` if the profile does not set
one.

.. note:: When creating a new pool, it is not necessary to create the rule
explicitly. If only the erasure-code profile is specified and the rule
argument is omitted, then Ceph will create the CRUSH rule automatically.

Replicated CRUSH rules over zones
---------------------------------

Ceph generates a CRUSH rule for each replicated pool that is stretched over
zones without being given one: by ``ceph osd pool create {pool-name}
--num_zones 2``, by ``ceph osd pool set {pool-name} num_zones 2``, and by
``ceph mon enable_stretch_mode``. The generated
rule has this form, from the pool's ``replica`` and the
:confval:`osd_pool_default_root`, :confval:`osd_pool_default_zone_failure_domain`,
:confval:`osd_pool_default_osd_failure_domain` and
:confval:`osd_pool_default_class` defaults, unless the command gives them::

rule {pool-name} {
id 2
type replicated
step take {root}
step choose firstn {num_zones} type {zone_failure_domain}
step chooseleaf firstn {replica} type {osd_failure_domain}
step emit
}

If ``{osd_failure_domain}`` is ``osd``, the rule uses ``step choose firstn``
instead of ``step chooseleaf firstn``.

A rule shared by several pools, or a rule over three or more zones for an
individual stretch pool (see :ref:`individual_stretch_pools`), is written by hand: get the
CRUSH map with ``ceph osd getcrushmap``, decompile it with ``crushtool -d``, add
a rule of the form above with an unused ``id``, compile it with ``crushtool
-c`` and set it with ``ceph osd setcrushmap``.

.. _rados-crush-msr-rules:

Expand All @@ -776,8 +814,9 @@ OSDs and clients are required to support the CRUSH_MSR feature bit
Deleting rules
--------------

To delete rules that are not in use by pools, run a command of the following
form:
The Monitors delete a rule automatically when the last pool that uses it is
deleted or given another rule, unless it is the default replicated rule. To
delete a rule that no pool uses, run a command of the following form:

.. prompt:: bash $

Expand Down
91 changes: 83 additions & 8 deletions doc/rados/operations/erasure-code-profile.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,62 @@ same time.
erasure-code-shec
erasure-code-clay

.. _erasure-code-profile-lifecycle:

Profile lifecycle
=================

An erasure code profile is deleted with the last pool that uses it.

A profile is created in one of two ways:

* explicitly, with ``ceph osd erasure-code-profile set`` (see below), before
creating the pool that uses it, or
* automatically, when an erasure-coded pool is created without a profile name
(or with ``default``). The pool gets a profile of its own, named
``{pool-name}-k{k}-m{m}``: a copy of the ``default`` profile with the
``k``, ``m`` and CRUSH options given on the command line. For example, the
following command creates a profile named ``ecpool-k4-m2`` and a pool that
uses it:

.. prompt:: bash $

ceph osd pool create ecpool erasure --k 4 --m 2

If a profile of that name already exists with the same contents, it is used.
If it exists with other contents, the command fails: remove that profile, or
name it with ``--erasure_code_profile``.

The ``default`` profile is a template that no pool uses. It holds what a pool
gets when it names no profile, including its placement: ``crush-root``,
``crush-zone-failure-domain``, ``crush-failure-domain`` and
``crush-device-class`` (empty for no class). The profile always has these
four: a key it lacks is filled in from :confval:`osd_pool_default_root`,
:confval:`osd_pool_default_zone_failure_domain`,
:confval:`osd_pool_default_osd_failure_domain` or
:confval:`osd_pool_default_class` when the profile is created or set again.
``ceph osd pool default set --k {k} --m {m}``
changes its ``k`` and ``m`` and keeps its other keys. While the default pool
type is ``erasure``, ``ceph osd pool default set`` writes ``--root``,
``--zone_failure_domain``, ``--osd_failure_domain``, ``--class`` and
``--no-class`` into it, instead of into the options. It refuses ``--k`` and
``--m`` while the default pool type is ``replicated``, unless it is also given
``--pool_type erasure``, which makes every later pool that names no type an
erasure-coded pool.
``ceph osd erasure-code-profile set default ...`` replaces the whole profile:
with ``osd_pool_default_erasure_code_profile`` and the keys given, or with only
the keys given if they name another plugin. Pools created before the change
keep their own copies.

When the last pool that uses a profile is deleted, the profile is deleted as
well, however it was created. The ``default`` profile is never deleted in this
way. Every erasure-coded pool gets a CRUSH rule of its own, named after the
pool, unless it is given one; a CRUSH rule is likewise deleted when the last
pool that uses it is deleted.

To create another pool with a profile whose last pool has been deleted, set the
profile again first.

osd erasure-code-profile set
============================

Expand All @@ -51,7 +107,8 @@ To create a new erasure code profile::
[{plugin=plugin}] \
[{stripe_unit=stripe_unit}] \
[{key=value} ...] \
[--force]
[--force] \
[--yes-i-really-mean-it]

Where:

Expand Down Expand Up @@ -86,7 +143,10 @@ Where:
created. The stripe_width of a pool using this profile
will be the number of data chunks multiplied by this
stripe_unit. See :ref:`rados_ops_erasure_coding_optimizations`
for more information.
for more information. ``ceph osd pool create`` refuses a
profile whose stripe_unit is not a multiple of 4K unless
``--yes-i-really-mean-it`` is given, and always for a pool
over zones.


:Type: String
Expand All @@ -102,12 +162,22 @@ Where:

``--force``

:Description: Override an existing profile by the same name, and allow
setting a non-4K-aligned stripe_unit. Overriding an existing
profile can be dangerous, and thus ``--yes-i-really-mean-it``
must be used as well.
:Description: Allow setting a non-4K-aligned stripe_unit. With
``--yes-i-really-mean-it``, also allow a ``blaum_roth``
profile whose ``w+1`` is not prime.

:Type: String
:Type: Boolean
:Required: No.

``--yes-i-really-mean-it``

:Description: Override a profile that a pool uses. OSDs read a pool's
profile whenever they load its PGs, so changing the ``k``,
``m`` or plugin of a profile that a pool uses corrupts the
pool's data. A profile that no pool uses, such as
``default``, can be changed without it.

:Type: Boolean
:Required: No.

osd erasure-code-profile rm
Expand All @@ -119,7 +189,12 @@ To remove an erasure code profile::

If the profile is referenced by a pool, the deletion will fail.

.. warning:: Removing an erasure code profile using ``osd erasure-code-profile rm`` does not automatically delete the associated CRUSH rule associated with the erasure code profile. It is recommended to manually remove the associated CRUSH rule using ``ceph osd crush rule remove {rule-name}`` to avoid unexpected behavior.
It is rarely necessary to remove a profile, because a profile is deleted
automatically with the last pool that uses it (see
:ref:`erasure-code-profile-lifecycle`). Removing a profile that does not exist
succeeds and reports that the profile does not exist.

.. warning:: Removing an erasure code profile using ``osd erasure-code-profile rm`` does not delete a CRUSH rule created from it. A rule that a pool used is deleted with the last pool that uses it. To remove a rule that no pool has used, run ``ceph osd crush rule rm {rule-name}``.

osd erasure-code-profile get
============================
Expand Down
11 changes: 10 additions & 1 deletion doc/rados/operations/erasure-code.rst
Original file line number Diff line number Diff line change
Expand Up @@ -62,12 +62,18 @@ profile can be displayed with this command:

::

crush-device-class=
crush-failure-domain=host
crush-root=default
crush-zone-failure-domain=datacenter
k=2
m=2
plugin=isa
crush-failure-domain=host
technique=reed_sol_van

The ``crush-*`` keys are where erasure-coded pools that name no profile are
placed (see :ref:`pool-creation-defaults`).

.. note::
The profile just displayed is for the *default* erasure-coded pool, not the
*simplest* erasure-coded pool. These two pools are not the same:
Expand Down Expand Up @@ -252,6 +258,9 @@ unsupported combination of plugin and technique, such as CLAY, LRC, or
SHEC, is blocked with an error message.

The default stripe unit is 4K which works well for standard EC pools.
A pool over two zones (``num_zones`` 2) is always optimized. Its stripe unit
is 16K unless :confval:`osd_pool_erasure_code_stripe_unit` is set or its
profile sets ``stripe_unit``.
The stripe unit must be a multiple of 4 KiB for optimizations to be
enabled; enabling the flag on a pool with any other stripe unit is
rejected.
Expand Down
Loading
Loading