InterviewHubPRO
Section Overview
Q21

Question 21 of 50

Part 2: Kubernetes Architecture & Core Workloads (11 - 25)

42%
DevOps & Kubernetes (50 Qs)•Part 2: Kubernetes Architecture & Core Workloads (11 - 25)

Persistent Volumes (PV), PVC, StorageClass, and the Container Storage Interface (CSI).

Kubernetes Storage Subsystem

Kubernetes abstracts physical storage infrastructure through a 3-tier declarative model: StorageClass, PersistentVolumeClaim (PVC), and PersistentVolume (PV) managed via the Container Storage Interface (CSI).

sql
[ Developer Request ]
        |
        v
+-------------------------------+
|  PersistentVolumeClaim (PVC)  | -> Demands 100Gi, ReadWriteOnce
+-------------------------------+
        |
        v
+-------------------------------+
|       StorageClass (CSI)      | -> aws-ebs-csi-driver, gp3, dynamic provisioner
+-------------------------------+
        |
        v (Calls Cloud Provider Storage API)
+-------------------------------+
|     PersistentVolume (PV)     | -> Provisions actual EBS Volume / SAN LUN
+-------------------------------+
        |
        v (Attached to EC2 & Mounted into Pod filesystem)
[ Pod /var/lib/data Mount ]

Access Modes Breakdown

Access ModeCLI NotationArchitecture & Support
ReadWriteOnceRWOCan be mounted as read-write by a single node. Typical for block storage (AWS EBS, GCP Persistent Disk, Azure Managed Disks).
ReadOnlyManyROXCan be mounted as read-only by many nodes simultaneously.
ReadWriteManyRWXCan be mounted as read-write by many nodes simultaneously. Requires network filesystems (NFS, AWS EFS, CephFS).
ReadWriteOncePodRWOP(Kubernetes 1.22+) Restricts access to a single Pod across the entire cluster.

Reclaim Policies

  • Delete (Default in cloud): When the PVC is deleted, the underlying PV and cloud storage disk are automatically permanently destroyed.
  • Retain: When the PVC is deleted, the PV remains in Released state. The underlying physical storage and data are preserved for manual recovery.