Skip to main content
RunBook Academy

CephXCI · Adding Storage NodesAdding Storage Nodes

Pre-check: devices and capacity

Intermediate⏱ ~17 mincephsmartctllsblk

What you'll learn

  • Verify devices are present and available
  • Confirm device health before deployment
  • Check device class detection
  • Plan the OSD layout including DB devices

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

A device that fails in its first month costs a replacement and a rebalance. Most such devices were detectably marginal before deployment.

Devices present and available

# the host whose new devices are being checked:
HOST=ceph-07

lsblk -o NAME,SIZE,TYPE,ROTA,MODEL,SERIAL
ceph orch device ls "$HOST" --wide
HOST     PATH      TYPE  SIZE  AVAILABLE  REJECT REASONS
ceph-07  /dev/sdb  hdd   16T   Yes
ceph-07  /dev/sdc  hdd   16T   No         LVM detected
# clear a device with stale metadata
ceph orch device zap ceph-07 /dev/sdc --force

Health before deployment

for d in /dev/sd{b..m}; do
  printf '%-10s ' "$d"
  smartctl -H "$d" | grep -i 'overall-health' || echo "no SMART"
done
# the attributes that matter, on every device
for d in /dev/sd{b..m}; do
  echo "== $d"
  smartctl -A "$d" | awk '$1 ~ /^(5|187|197|198|199)$/ {print "   ", $2, $10}'
done
FindingAction
Any pending sectorsdo not deploy; replace
Any reallocated sectorsinvestigate; likely replace
Non-zero uncorrectabledo not deploy
Power-on hours already higha used drive; confirm it was intended
NVMe percentage used above zero on a new driveconfirm it is new
# NVMe
for d in /dev/nvme{0..3}n1; do
  nvme smart-log "$d" | grep -iE 'critical_warning|percentage_used|media_errors'
done

A new drive with non-zero endurance consumed or existing reallocations was not new, and deploying it starts its service life already degraded.

Device class detection

# after adding, but worth anticipating
lsblk -o NAME,ROTA
ROTA=1 → detected as hdd
ROTA=0 → detected as ssd or nvme by transport
# correct a misdetection after adding
ID=12
ceph osd crush set-device-class ssd osd.${ID}

Devices behind certain controllers report rotational incorrectly, so checking ROTA beforehand predicts whether a correction will be needed.

Planning the OSD layout

service_type: osd
service_id: ceph-07-hdd
placement:
  host_pattern: 'ceph-07'
spec:
  data_devices:
    rotational: 1
  db_devices:
    rotational: 0
  db_slots: 6
DB device sizing:
  a common guideline is a few percent of the data device per OSD
  undersized DB spills over to the data device, negating the benefit
  one NVMe serving too many OSDs becomes a bottleneck and a failure domain
# check for spillover on existing OSDs to validate the sizing
ceph health detail | grep -i BLUEFS_SPILLOVER
ceph osd df tree | head

Quiz

Knowledge check · 4 questions

  1. Q1. Why is an undersized DB device worse than having no DB device?

  2. Q2. A pending sector on a brand-new drive is grounds for a warranty claim rather than for deploying the drive and watching it.

  3. Q3. Pre-check devices on a new node.

    A new node has twelve HDDs and two NVMe devices intended as DB devices. The node was delivered as a complete build.

  4. Q4. What does checking `ROTA` before deployment tell you?

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

Production discipline

Read SMART on every device before deployment and reject any with pending, reallocated, or uncorrectable sectors — the failure is already determined and deploying it costs a repair and a replacement. Verify DB device sizing against the OSD count; spillover produces worse tail latency than having no DB device.

Cross-course references

  • Kubernetes: node readiness checks before joining serve the same purpose
  • Linux: burn-in and SMART verification before deploying drives is long-standing practice