Storage
CSI features
67 / 82

Storage plugins follow a standard interface, and modern drivers add operational superpowers.

Like CRI and CNI, CSI lets any vendor plug in. The same PVC YAML works on Persistent Disk, EBS, Ceph or Longhorn.

pvc icon

Snapshot

A point-in-time copy of a PVC using the backend's native snapshot. The basis of backups and quick restores.

kind: VolumeSnapshot
spec:
  source: {persistentVolumeClaimName: data-pg-0}
pvc icon

Clone and restore

Create a new PVC pre-populated from a snapshot or another PVC. Spin up a copy of production data for debugging.

kind: PersistentVolumeClaim
spec:
  dataSource: {kind: VolumeSnapshot, name: snap1}
pvc icon

Expansion

Grow a PVC in place by editing its requested size. Needs allowVolumeExpansion: true on the class. You cannot shrink.

$ kubectl edit pvc data-pg-0
# spec.resources.requests.storage: 50Gi

StatefulSet ties it together

volumeClaimTemplates gives each replica its own PVC (data-pg-0, data-pg-1) that stays bound to that ordinal across restarts and rescheduling.

A snapshot is not an application backup

It captures disk blocks, which may be mid-write for a database. Use quiescing hooks or Velero with pre and post hooks (Deck 6), and keep copies off the cluster.