Interview Prep/Kubernetes/Storage and volumes

After restoring a VolumeSnapshot into a new PVC, the PVC stays Pending with `error getting handle for DataSource Type VolumeSnapshot by Name snap-1: snapshot snap-1 not bound`.

AdvancedTroubleshootingStorage and volumes
Answer

Likely causes → The VolumeSnapshot is not readyToUse: the snapshot controller is not installed, the VolumeSnapshotClass driver is wrong, or the cloud snapshot is still in progress. Snapshots are namespaced, so it must be in the same namespace as the PVC.

Diagnose →

kubectl get volumesnapshot snap-1 -n data -o jsonpath='{.status}' | jq
kubectl get volumesnapshotclass
kubectl get pods -A | grep snapshot-controller

Fix → Install the snapshot CRDs and snapshot-controller (EKS add-on), use the right VolumeSnapshotClass, and wait for readyToUse: true before creating the PVC.

Prevent → Restore drills on a schedule, not only during incidents.

All Kubernetes questions Roadmap: Kubernetes networking, storage & scaling

More on Storage and volumes