
- From the console, navigate to Storage → StorageClasses.
- If you want a clean demo view, remove any existing StorageClasses you don’t need.
- Click Create StorageClass and provide a name (for example,
localstorageclass) and an optional description.
-
Reclaim policy
Retain— the PV and its underlying data are preserved after the PVC is deleted.Delete— the underlying storage asset is deleted when the PV is released.
-
Volume binding mode
Immediate— provision the volume as soon as the PVC is created.WaitForFirstConsumer— delay provisioning until the PVC is scheduled to a Pod. This lets the scheduler pick a node with matching topology or available local storage.
Use
WaitForFirstConsumer when your storage has node- or zone-local constraints (for example, local PVs or zonal cloud disks). This ensures volumes are provisioned on nodes where the Pods can actually run.- Provisioner — select the CSI or in-tree provisioner that corresponds to your platform. The console lists many built-in and CSI options (AWS, GCP, Azure, Cinder, vSphere, etc.).

- creating matching PersistentVolumes (static provisioning), or
- installing a CSI driver that implements dynamic provisioning for that StorageClass.
- In the console go to Storage → PersistentVolumeClaims and click Create Persistent Volume Claim.
- Select your StorageClass (e.g.,
localstorageclass), give the claim a name (for example,localstorageclass-claim), choose an access mode (commonlyReadWriteOncefor block devices attached to one node), set the requested size (for example, 10 GiB), and select the volume mode (Filesystemis typical).


- If a matching PV is available (or the StorageClass has a working provisioner), the PVC will move to
Bound. - If no PV is available and there is no provisioner (or the provisioner cannot satisfy the request), the PVC will remain
Pending.

If you select “No Provisioner” for a StorageClass, the cluster will not dynamically create PVs for PVCs using that class. You must either create matching PVs manually (static provisioning) or deploy a compatible CSI driver that provides dynamic provisioning.
- StorageClass defines how volumes are provisioned and what provisioner to use.
- Reclaim policy (
RetainvsDelete) controls whether underlying storage is preserved after PVC deletion. - Volume binding mode (
ImmediatevsWaitForFirstConsumer) determines when and where volumes are created — useWaitForFirstConsumerfor topology-aware or local storage. - Always choose a provisioner that matches your underlying infrastructure or install a CSI driver for your storage backend.
- Use
oc get sc,oc describe sc <name>,oc get pvc, andoc get pvto troubleshoot claims and volumes.
- OpenShift dynamic provisioning: https://docs.openshift.com/container-platform/4.8/storage/dynamic_provisioning.html
- Kubernetes Container Storage Interface (CSI): https://kubernetes.io/docs/concepts/storage/container-storage-interface/
- OpenShift storage concepts: https://docs.openshift.com/container-platform/latest/storage/understanding-persistent-storage.html