CephXCII · Removing Storage NodesRemoving Storage Nodes
Evacuating a node
What you'll learn
- Distinguish the evacuation methods
- Choose the appropriate one
- Execute an evacuation
- Control its pace
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
Why this matters in production
There are two ways to drain a node and they differ in what happens if the process is interrupted.
The two methods
# method 1: mark the OSDs out
for id in $(ceph osd ls-tree ceph-07); do ceph osd out "$id"; done
# method 2: reduce the CRUSH weight
for id in $(ceph osd ls-tree ceph-07); do ceph osd crush reweight osd.$id 0; done
osd out | CRUSH reweight to 0 | |
|---|---|---|
| Changes | the OSD’s in state | the OSD’s CRUSH weight |
| PG placement | remapped away | recomputed without it |
| If interrupted | ceph osd in restores instantly | reweighting back restores |
| Movement | one pass | one pass |
| Effect on the bucket weight | none | reduces the host’s total |
| Reversibility | immediate | immediate |
# the orchestrator's method, which handles the sequence
ceph orch host drain ceph-07
ceph orch osd rm status
ceph orch host drain marks the OSDs out and removes them once drained,
which is the intended path for a permanent removal.
Which to use
| Intent | Method |
|---|---|
| Permanent removal | ceph orch host drain |
| Temporary evacuation, node returning | ceph osd out, then ceph osd in |
| Gradual drain to limit impact | CRUSH reweight in steps |
| Removing individual OSDs | ceph orch osd rm |
# a gradual drain
for w in 0.75 0.5 0.25 0; do
for id in $(ceph osd ls-tree ceph-07); do
ceph osd crush reweight osd.$id $(echo "16.0 * $w" | bc)
done
while ! ceph health | grep -q HEALTH_OK; do sleep 60; done
done
Stepping the weight down means each step’s movement is bounded and the cluster reaches health between them.
Executing an evacuation
# verify readiness
ceph -s
ceph osd df | sort -k17 -rn | head -3
ceph osd df tree | grep -A15 ceph-07
The remaining OSDs must be able to hold this node's data
without any of them passing backfillfull.
# start
ceph orch host drain ceph-07
# monitor
ceph orch osd rm status
watch -n 60 'ceph -s | grep -E "misplaced|health"'
Controlling the pace
ceph config set osd osd_max_backfills 2
ceph config set osd osd_mclock_profile high_client_ops
# pause if needed
ceph osd set norebalance
# and resume
ceph osd unset norebalance
An evacuation is a backfill like any other and responds to the same throttles.
Quiz
Knowledge check · 4 questions
Q1. What does stepping a CRUSH reweight down in stages achieve?
Q2. An evacuation can be started without checking whether the remaining OSDs can hold the data.
Q3. Evacuate a node for permanent removal.
A node with twelve OSDs holding 18 TB is being decommissioned. The cluster is at 74% average utilisation.
Q4. What distinguishes `ceph osd out` from a CRUSH reweight to zero?
Passing score: 75%. Answers are checked in this browser.
Production discipline
Verify the remaining OSDs can absorb the node’s contents below
backfillfull before starting an evacuation — a stalled drain leaves the
cluster in a worse state than not having started. Use ceph orch host drain for permanent removal and a stepped CRUSH reweight where each
step’s movement must be bounded.
Cross-course references
- Kubernetes: draining a node requires the remaining ones to have capacity
- Linux: removing an array member requires the survivors to hold its data