Skip to main content
RunBook Academy

CephCXV · Cluster-Wide Capacity IncidentCluster-Wide Capacity Incident

When the imbalance is the emergency

Advanced⏱ ~18 minceph

What you'll learn

  • Establish whether the incident is volume or distribution
  • Model a redistribution before executing it
  • Choose correctly between the two kinds of reweight
  • Sequence rebalancing around the thresholds that block it

Prerequisites

None — start here.

Verified against Ceph Tentacle 20.2.x · Ceph Squid 19.2.x (supported previous) · cephadm matches the verified Ceph release · podman 4.x · csi-rbd and csi-cephfs current · RBD / CephFS / RGW current (matches Ceph release) · Linux kernel 5.15+ (5.10 minimum) · Ubuntu 24.04 LTS (Ceph host baseline) · Debian 12 (Bookworm) (Ceph host baseline) · Rocky Linux / RHEL / AlmaLinux 9.x (Ceph host baseline) · Proxmox VE 9.x (cross-course integration) · Kubernetes 1.31+ (cross-course integration) · 2026-08-18

Not yet marked complete on this device.

Why this matters in production

If the fullest OSD is 20 points above the average, roughly a fifth of the cluster’s capacity is unreachable behind a distribution problem. Redistribution recovers it in an hour without buying anything.

Volume or distribution

ceph osd df | tail -3
MIN/MAX VAR: 0.71/1.28  STDDEV: 6.42
TOTAL       470 TiB  341 TiB  129 TiB     72.55
ReadingDiagnosis
STDDEV under 3, average near the ratiovolume — rebalancing cannot help
STDDEV above 6, MAX VAR above 1.2distribution — recoverable capacity exists
MAX VAR high on one host onlya host-level anomaly, often a failed disk replaced with a smaller one
High STDDEV within one device class onlythat class needs the attention, not the cluster
ceph balancer status
ceph balancer eval
ceph osd df tree | grep -E 'host|TOTAL'

Model it before it moves

ceph osd test-reweight-by-utilization 110 0.05 8
ceph balancer mode upmap
ceph balancer off
ceph balancer optimize plan-a
ceph balancer show plan-a
ceph balancer eval plan-a
`optimize` produces a plan without applying it, `show` prints the
individual upmap changes it contains, and `eval` scores the result. None
of the three moves a byte.
ceph balancer execute plan-a
ceph balancer rm plan-a

The two reweights are different things

ceph osd reweightceph osd crush reweight
Changesthe 0–1 override in the osdmapthe leaf’s weight in the CRUSH tree
Range0 to 1, cannot increase shareany value, can increase share
Reset byceph osd in and out transitionsnothing automatic
Effect on parentsnoneparent bucket weights change too
Set byreweight-by-utilizationthe operator, deliberately
ceph osd reweight-by-utilization 110 0.05 8
ceph osd reweight osd.37 1.0            # undo one
ceph osd crush reweight osd.37 8.0      # a deliberate capacity correction

Sequencing around the thresholds

ceph osd dump | grep -E 'full_ratio|nearfull_ratio'
ceph osd df | sort -k17 -n | tail -3
BlockerEffect on rebalancing
Source OSD above backfillfullit can still send data out
Target OSD above backfillfullbackfill into it is refused
Any PG not active+cleanthe balancer defers optimisation
Misplaced above target_max_misplaced_ratiothe balancer throttles itself
ceph config get mgr target_max_misplaced_ratio
ceph osd set-require-min-compat-client luminous   # required once, for upmap

Quiz

Knowledge check · 4 questions

  1. Q1. A rebalance starts, moves a little, then stalls with PGs in `backfill_toofull`. What happened?

  2. Q2. The balancer in upmap mode can equalise utilisation more tightly than reweighting can.

  3. Q3. Recover capacity from a skewed cluster during an incident.

    `ceph osd df` reports MIN/MAX VAR 0.71/1.28 and STDDEV 6.42 with the cluster at 72% average and the fullest OSD at 93%. Clients on one pool are near blocked.

  4. Q4. What is the difference between `ceph osd reweight` and `ceph osd crush reweight`?

Passing score: 75%. Answers are checked in this browser.

Production discipline

Read STDDEV and MIN/MAX VAR before choosing a remedy — rebalancing a volume problem wastes the only hours you have. Model every redistribution with balancer optimize and show before executing, and clear the backfillfull blocker first, because a plan that stalls halfway leaves the cluster more skewed than when it started.

Cross-course references

  • Kubernetes: a descheduler rebalances pods but cannot create capacity that does not exist
  • Linux: a filesystem that is 70 percent full can still be out of space in one allocation group