Skip to main content
RunBook Academy

CephXXIII · ReplicationReplication

Choosing size: what each value actually buys

Advanced⏱ ~18 minceph

What you'll learn

  • Quantify the failure tolerance of each size value
  • Compute the raw capacity cost of a size choice
  • Reason about recovery windows and correlated failure
  • Justify a size choice for a given cluster and workload

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

size is the most expensive number in your cluster: it multiplies every byte you buy. Getting it right is worth real money, and getting it wrong in the cheap direction is worth real data.

The three candidates

sizemin_sizeFailures tolerated with I/ORaw per usable byteUsable of 1 PB raw
210 (see below)2.0500 TB
2202.0500 TB
3213.0333 TB
4224.0250 TB

The column that matters is the third: how many OSDs in a PG’s acting set can fail while the PG still serves I/O.

Why size 2 does not work

size 2, min_size 2 blocks I/O on any single failure. That is not a production posture; a routine disk failure becomes an outage.

size 2, min_size 1 keeps serving, and this is where it gets dangerous. With one copy left, every write goes to a single OSD. Lose it before recovery completes and those writes are gone. Worse, if the two OSDs diverge — each accepting writes during a partition — Ceph has no way to determine which history is authoritative, because there is no third copy to break the tie.

Use size 2 only for data you can regenerate: caches, scratch, intermediate build artefacts.

Why size 3 is the default

Three copies gives you a genuine failure budget:

  • One failure: full I/O, reduced redundancy, recovery starts
  • Two failures: I/O blocked (with min_size 2), data intact
  • A majority always exists to arbitrate divergence

And the recovery window matters as much as the count. After one failure a size-3 pool has two copies while it rebuilds. The rebuild takes hours. A second failure during those hours is not far-fetched — disks from the same batch, in the same rack, at the same temperature, fail together far more often than independence would predict.

When size 4 is justified

Four copies at 4× capacity is expensive, and it buys tolerance of two concurrent failures with continued I/O. It is justified when:

  • Recovery windows are long (very large OSDs, slow rebuild)
  • Failure correlation is high (single rack, shared power, one disk batch)
  • The data cannot be regenerated and the RPO is zero

For most clusters the money is better spent on more failure domains — a fourth rack, a second power feed — than on a fourth copy. Correlated failure is what actually kills clusters, and independence is cheaper to buy than redundancy.

Quiz

Knowledge check · 4 questions

  1. Q1. Why is size 2 with min_size 1 considered dangerous rather than merely reduced-redundancy?

  2. Q2. A 900 TB raw cluster at size 3 provides roughly 300 TB of usable capacity before accounting for fill headroom.

  3. Q3. Decide between size 4 and additional failure domains.

    A 500 TB raw cluster on 18 TB HDDs sits in a single rack on one power feed. Rebuild of a failed OSD takes about 14 hours. The data is regulatory records with a zero-RPO requirement. Budget exists for either a fourth replica or a second rack with independent power.

  4. Q4. Why does a cluster of many small OSDs tend to be more durable than one of few large OSDs at the same size setting?

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

Production discipline

Record the size decision and its justification alongside the pool definition, including the correlated-failure assumptions it rests on — those assumptions change when the cluster moves racks or grows. Report capacity to stakeholders in usable terms with the fill headroom already subtracted, and re-derive the number whenever size or the EC profile changes.

Cross-course references

  • Kubernetes: replicas across zones versus more replicas in one zone is the identical trade-off
  • Linux: RAID 6 versus RAID 10 turns on the same rebuild-window reasoning