Kubernetes Storage
Kubernetes storage provides persistent data to pods through volumes, persistent volume claims, and storage classes backed by CSI drivers. It manages the lifecycle of storage resources so stateful applications retain their data across restarts and rescheduling.
itCloud native tools and technologies | OpenSkills.info
Recommended first:kubernetes-fundamentals
Course pathWalk it in order
Look it upDip in anytime
Go furtherLeaves this page
Don't Panic
Don't Panic — Kubernetes Storage
Kubernetes storage is the arrangement that lets a Pod keep files when its containers restart, without asking the application to know which disk, share, or driver lives beneath it. Containers are excellent at forgetting things. Storage gives them a more useful hobby.
The problem has two parts. A container's writable layer vanishes with the container, and two containers in one Pod do not automatically share their files. A volume is a directory that Kubernetes makes available to the Pod's containers, each at the path it needs. For scratch space, configuration files, or a handoff between two containers, an ephemeral volume is enough. For a database, queue, or anything whose loss would cause a very long afternoon, the volume must outlive the Pod.
Durable storage hangs from three pieces. A PersistentVolumeClaim, or PVC, says what the workload needs: capacity, access mode, and perhaps a class. A PersistentVolume, or PV, represents the concrete storage that can meet it. A StorageClass is the recipe that tells Kubernetes which provisioner and parameters to use when a claim needs a new volume. The claim is the portable request; the volume is the infrastructure answer. Kubernetes performs the introduction and then gets out of the way, which is polite but does leave the two to manage their relationship.
The surprise is that the convenient words carry sharp edges. ReadWriteOnce means one node may write, not one Pod. WaitForFirstConsumer delays provisioning until Kubernetes knows where the Pod can run, avoiding a volume created in the wrong zone. And Delete is not a housekeeping label; it can remove the underlying storage after its claim goes away. The platform can orchestrate the lifecycle, but it cannot make the backend's durability or recovery behavior less real.
Start with the Intro when the claim, class, and volume arrangement still feels like three identical boxes with excellent branding. Use the Slides for the lifecycle and the access-mode traps. Keep the Cheatsheet nearby when a PVC is Pending, a volume needs expansion, or a StatefulSet leaves data behind. Then follow the Reference tab into the Kubernetes documentation for the exact driver and backend behavior your cluster provides.
Where this skill leads
Relevant careers
See how this topic contributes to broader role-level skill maps.
Sources
- https://kubernetes.io/docs/concepts/storage/
Supports
- Scope of Kubernetes storage — long-term and temporary storage for Pods
- Concept-page taxonomy (volumes, persistent volumes, classes, snapshots, capacity)
- https://kubernetes.io/docs/concepts/storage/volumes/
Supports
- Problems volumes solve — container file loss on crash/restart, sharing between containers
- Volume as a directory mounted per-container
- Volume types — emptyDir, configMap, secret, downwardAPI, hostPath (with security warnings)
- Migration of in-tree cloud plugins to CSI drivers
- https://kubernetes.io/docs/concepts/storage/persistent-volumes/
Supports
- PV as cluster storage resource; PVC as request; binding one-to-one; Pods mount claims
- Lifecycle — provisioning (static/dynamic), binding, using, releasing, reclaiming
- Access modes — ReadWriteOnce (per node), ReadOnlyMany, ReadWriteMany, ReadWriteOncePod
- Reclaim policies — Delete and Retain
- In-use protection finalizers
- Volume expansion via allowVolumeExpansion; no shrinking
- https://kubernetes.io/docs/concepts/storage/storage-classes/
Supports
- StorageClass fields — provisioner, parameters, reclaimPolicy, mountOptions, volumeBindingMode, allowVolumeExpansion
- Default StorageClass mechanism
- Immediate vs WaitForFirstConsumer binding and multi-zone topology implications
- https://kubernetes.io/docs/concepts/storage/dynamic-provisioning/
Supports
- On-demand PV creation for PVCs referencing a class; self-service storage; default-class behavior
- https://kubernetes.io/docs/concepts/storage/ephemeral-volumes/
Supports
- Pod-lifetime volume categories including generic ephemeral volumes
- https://kubernetes.io/docs/concepts/storage/volume-snapshots/
Supports
- VolumeSnapshot/VolumeSnapshotClass/VolumeSnapshotContent object model via CSI
- Restore by using a snapshot as a PVC dataSource
- https://kubernetes.io/docs/concepts/storage/volume-pvc-datasource/
Supports
- CSI volume cloning via PVC dataSource
- https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/
Supports
- volumeClaimTemplates creating per-ordinal PVCs; retention across rescheduling and deletion; retention policy option
- https://kubernetes.io/blog/2016/10/dynamic-provisioning-and-storage-in-kubernetes/
Supports
- Kubernetes 1.4 introduced beta dynamic provisioning and StorageClass
- https://kubernetes.io/blog/2017/03/dynamic-provisioning-and-storage-classes-kubernetes/
Supports
- Kubernetes 1.6 made dynamic provisioning and StorageClass stable
- https://kubernetes.io/blog/2018/01/introducing-container-storage-interface/
Supports
- Kubernetes 1.9 introduced alpha CSI support
- https://kubernetes.io/blog/2018/04/13/local-persistent-volumes-beta/
Supports
- Local PersistentVolumes beta and WaitForFirstConsumer scheduling
- https://kubernetes.io/blog/2018/10/09/introducing-volume-snapshot-alpha-for-kubernetes/
Supports
- VolumeSnapshot alpha introduction
- https://kubernetes.io/blog/2018/12/03/kubernetes-1-13-release-announcement/
Supports
- CSI general availability in Kubernetes 1.13
- https://kubernetes.io/blog/2019/12/09/kubernetes-1-17-feature-volume-snapshot-moves-to-beta/
Supports
- VolumeSnapshot beta in Kubernetes 1.17
- https://kubernetes.io/blog/2020/12/10/kubernetes-1.20-volume-snapshot-moves-to-ga/
Supports
- VolumeSnapshot general availability in Kubernetes 1.20
- https://kubernetes.io/blog/2022/05/05/volume-expansion-ga/
Supports
- Volume expansion general availability in Kubernetes 1.24
- https://kubernetes.io/blog/2023/12/18/read-write-once-pod-access-mode-ga/
Supports
- ReadWriteOncePod general availability in Kubernetes 1.29
- https://aws.amazon.com/ebs/
Supports
- Amazon EBS as a managed block-storage landscape entry
- https://cloud.google.com/products/compute/persistent-disk
Supports
- Google Cloud Persistent Disk as a managed block-storage landscape entry
- https://azure.microsoft.com/products/managed-disks
Supports
- Azure Managed Disks as a managed block-storage landscape entry
- https://portworx.com/
Supports
- Portworx as a Kubernetes-native storage platform landscape entry
- https://longhorn.io/
Supports
- Longhorn as a Kubernetes-native storage platform landscape entry
- https://github.com/ramitsurana/awesome-kubernetes
Supports
- Discovery source for Kubernetes storage ecosystem links
