Skip to main content
RunBook Academy

CephLXXXVIII · Kubernetes Storage Failure ScenariosKubernetes Storage Failure Scenarios

CSI driver failures and their blast radius

Advanced⏱ ~17 minkubectl

What you'll learn

  • Map each CSI component failure to its effect
  • Recover a failed component safely
  • Recognise when a restart is unsafe
  • Configure for resilience

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

The CSI components have very different blast radii, and restarting the wrong one during an incident makes things worse.

The blast radius

Component downAffectsDoes not affect
Provisioner Deploymentnew PVCs, deletions, expansions, snapshotsrunning pods, existing mounts
Node plugin on one nodemounts and unmounts on that nodeother nodes, existing mounts on that node
Node plugin everywhereall mount and unmount operationsrunning pods with existing mounts
node-driver-registrarkubelet’s knowledge of the driver on that nodeexisting mounts
Ceph itselfeverything eventuallynothing initially

The critical observation: existing mounts survive a node plugin restart. The mount is in the kernel; the plugin is not in the data path once the volume is mounted.

kubectl -n ceph-csi get pods -o wide
kubectl -n ceph-csi get deploy,ds

Recovering the provisioner

kubectl -n ceph-csi logs deploy/csi-rbdplugin-provisioner -c csi-rbdplugin --tail=100
kubectl -n ceph-csi rollout restart deploy/csi-rbdplugin-provisioner
kubectl -n ceph-csi rollout status deploy/csi-rbdplugin-provisioner

Restarting the provisioner is safe: it holds no state that matters, and in-progress operations are retried by the sidecars.

Recovering a node plugin

NODE=stor-04
NODE=${NODE}
kubectl -n ceph-csi delete pod -l app=csi-rbdplugin \
  --field-selector spec.nodeName=$NODE

Restarting a node plugin is safe for existing mounts and interrupts any mount or unmount in progress, which is retried.

# verify it re-registers
kubectl get csinode $NODE -o jsonpath='{.spec.drivers[*].name}'

When a restart is unsafe

SituationWhy
A volume expansion in progressmay leave the filesystem partly resized
An unmount in progress during node drainmay leave a stale attachment
The only provisioner replica during a large batchoperations queue and time out
A node plugin during a snapshot restore clonethe clone continues; the PVC binding retries
# check for in-progress operations first
kubectl get pvc --all-namespaces | grep -v Bound
kubectl get volumeattachment | grep -v true

Most restarts are safe; checking for in-progress operations takes seconds and covers the exceptions.

Configuring for resilience

# provisioner: more than one replica with leader election
replicaCount: 3
# node plugin: appropriate tolerations so it runs everywhere
tolerations:
  - operator: Exists
# priority so it is not evicted under pressure
priorityClassName: system-node-critical

The priority class matters: a node plugin evicted under memory pressure takes every mount operation on that node with it, and it is exactly the component that should not be evicted.

kubectl -n ceph-csi get pods -o jsonpath='{range .items[*]}{.metadata.name}{"\t"}{.spec.priorityClassName}{"\n"}{end}'

Quiz

Knowledge check · 4 questions

  1. Q1. Why do existing mounts survive a CSI node plugin restart?

  2. Q2. A cluster can lose its CSI provisioner entirely and every running pod keeps reading and writing.

  3. Q3. Improve CSI resilience.

    A node came under memory pressure and the CSI node plugin was evicted. Pods rescheduling onto that node could not mount volumes until it was manually restored.

  4. Q4. Which in-progress operations make a CSI restart unsafe?

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

Production discipline

Give the CSI node plugin system-node-critical priority — it is evicted under memory pressure otherwise, which is exactly when workloads are rescheduling and need volumes. Restart CSI components freely for diagnosis; existing mounts are unaffected because the plugin is not in the I/O path.

Cross-course references

  • Kubernetes: critical system components need priority classes to survive pressure
  • Linux: control-plane daemons that establish state can restart without disturbing it