KCNA Storage Solutions 4 — Questions and Answers
Question 1: Which CSI sidecar container is responsible for watching VolumeSnapshot objects and triggering snapshot creation via the CSI driver?
- external-provisioner
- external-attacher
- external-snapshotter (Correct answer)
- node-driver-registrar
Correct answer: external-snapshotter
The external-snapshotter sidecar watches VolumeSnapshot CRDs and calls the CSI driver's CreateSnapshot RPC to physically take the snapshot.
Question 2: What is the significance of the 'claimRef' field on a PersistentVolume?
- It lists all pods currently using the PV
- It reserves the PV for a specific PVC, preventing other PVCs from binding to it (Correct answer)
- It specifies the StorageClass for the PV
- It defines the maximum number of pods that can claim the PV
Correct answer: It reserves the PV for a specific PVC, preventing other PVCs from binding to it
The claimRef field on a PV creates a binding reservation to a specific PVC, which is how static provisioning ensures the correct PVC gets the pre-created PV.
Question 3: A PVC remains in 'Pending' state indefinitely. Which is the most likely cause?
- The pod referencing the PVC has too many resource requests
- No PV exists that matches the PVC's storage class, access mode, and size requirements (Correct answer)
- The PVC has an incorrect namespace annotation
- The kubelet on the node restarted recently
Correct answer: No PV exists that matches the PVC's storage class, access mode, and size requirements
A PVC stays Pending when no available PV satisfies all its requirements—storage class, access mode, and requested capacity must all match.
Question 4: Which command can be used to expand the size of an existing PersistentVolumeClaim in Kubernetes?
- kubectl resize pvc my-pvc --size=20Gi
- Edit the PVC spec and increase the storage request value (Correct answer)
- Delete and recreate the PVC with a larger size
- Use kubectl patch node to expand the underlying disk
Correct answer: Edit the PVC spec and increase the storage request value
To expand a PVC, you edit its spec.resources.requests.storage field to a larger value; the StorageClass must have allowVolumeExpansion: true.
Question 5: What is a key advantage of using Container Storage Interface (CSI) over in-tree volume plugins?
- CSI drivers are built into the Kubernetes core binary
- CSI allows storage vendors to develop and release drivers independently of the Kubernetes release cycle (Correct answer)
- CSI plugins run faster because they bypass the kubelet
- CSI eliminates the need for PersistentVolumes entirely
Correct answer: CSI allows storage vendors to develop and release drivers independently of the Kubernetes release cycle
CSI decouples storage driver development from Kubernetes core, so vendors can ship updates without waiting for a Kubernetes release.
Question 6: Which Kubernetes feature enables a pod to use a raw block device rather than a filesystem-based volume?
- volumeMode: Block in the PVC and PV spec (Correct answer)
- accessMode: RawBlock in the PVC spec
- storageType: block in the StorageClass
- hostPath with type: BlockDevice
Correct answer: volumeMode: Block in the PVC and PV spec
Setting volumeMode: Block in both the PV and PVC spec instructs Kubernetes to expose the volume as a raw block device instead of mounting a filesystem.
Question 7: Which of the following best describes a 'Retain' reclaim policy on a PersistentVolume?
- The PV is automatically made available for new PVCs after its PVC is deleted
- The PV and its data are preserved after PVC deletion, but the PV must be manually reclaimed (Correct answer)
- The data is replicated to a backup location before deletion
- The PV is deleted along with its backing storage
Correct answer: The PV and its data are preserved after PVC deletion, but the PV must be manually reclaimed
With the Retain policy, deleting a PVC releases the PV but leaves it in a 'Released' state with its data intact; an administrator must manually reclaim or delete it.
Which CSI sidecar container is responsible for watching VolumeSnapshot objects and triggering snapshot creation via the CSI driver?