Skip to main content
RunBook Academy

CephXC · Scaling OutScaling Out

Adding OSDs to an existing cluster

Intermediate⏱ ~17 mincephcephadm

What you'll learn

  • Add OSDs correctly
  • Verify each step before proceeding
  • Control the resulting rebalance
  • Avoid the common mistakes

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

Adding OSDs is routine and produces a rebalance whose size and timing are under your control if the sequence is right.

Before starting

ceph -s
ceph health detail
ceph osd df | sort -k17 -rn | head -3
ceph orch device ls --wide
Do not start if:
  the cluster is not HEALTH_OK
  a recovery is already running
  another expansion is in progress

Adding capacity during an existing recovery compounds the movement and extends both.

The sequence

# 1. verify the devices are available
# the host being expanded:
HOST=ceph-04

ceph orch device ls "$HOST" --wide
HOST      PATH      TYPE  SIZE  AVAILABLE  REJECT REASONS
ceph-04   /dev/sdb  hdd   16T   Yes
ceph-04   /dev/sdc  hdd   16T   No         Insufficient space, LVM detected

The reject reason names exactly what prevents a device being used.

# 2. clear a device if it has stale data
ceph orch device zap ceph-04 /dev/sdc --force
# 3. add all the host's OSDs together
ceph orch daemon add osd ceph-04:/dev/sdb
ceph orch daemon add osd ceph-04:/dev/sdc
# or, from a spec
ceph orch apply -i osd-spec.yaml
# 4. verify they are up and in
ceph osd tree | grep -A10 ceph-04
ceph -s

Controlling the rebalance

# before adding, if the impact must be bounded
ceph osd set norebalance

# add the OSDs; they come up but no data moves
ceph orch daemon add osd ceph-04:/dev/sdb

# release the movement when ready
ceph osd unset norebalance
# and pace it
ceph config set osd osd_max_backfills 2
ceph config set osd osd_mclock_profile high_client_ops

Adding with norebalance set lets the OSDs be verified as healthy before any data moves onto them.

Watching it

watch -n 30 'ceph -s | grep -E "misplaced|recovery"'
ceph osd df | sort -k17 -n | head -5

The new OSDs filling and the existing ones emptying is the expected pattern.

The common mistakes

MistakeCost
Adding OSDs one at a time over daysa rebalance per addition
Adding during an existing recoverycompounded movement
Adding a device with a different size without weight considerationuneven distribution
Not verifying the device class was detected correctlywrong pools use it
Forgetting to clear norebalanceno data moves; capacity appears unused
ID=12
ceph osd tree | grep -E 'hdd|ssd|nvme'
ceph osd crush get-device-class osd.${ID}

Quiz

Knowledge check · 4 questions

  1. Q1. Why should all of a host's OSDs be added together?

  2. Q2. Ceph always detects an OSD's device class correctly.

  3. Q3. Expand a cluster with new hosts.

    Three new hosts with twelve HDDs each are ready to add to a healthy cluster. The team wants to minimise client impact.

  4. Q4. What does the reject reason in `ceph orch device ls --wide` tell you?

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

Production discipline

Set norebalance before adding OSDs so they come up and can be verified before any data moves onto them, then clear it when ready. Add every OSD of an expansion together — individual additions produce a rebalance each, most moving data to intermediate placements.

Cross-course references

  • Kubernetes: batching node additions avoids repeated rescheduling waves
  • Linux: combining storage changes into one commit avoids intermediate movement