Kubernetes Persistent Volumes and Claims
In a distrubuted system, storage isn't simple to manage without a good abstraction, kubernetes offer an object called persistent volume to let pod to reclaim storage for persisting data. In the pod definition you can define your volume type with another object called persistentVolumeClaim where you can define type size and many other things. There are different phase in the persistent storage lifecycle: Provisioning : when an administrator create a Persistent Volume or a cloud resource dynamically request Binding : when a PVC is created k8s control loop watch if there are Persisten Volume matching the PVC and bind them together. Use : when the bound volume is mounted in to the pod Releasing : whene the POD is done and an API request is sent to delete the related bound PVC, the volume in this stage remains Reclaim : there are three options related to this state: - Retain: keep data interact and allow an administrato to handle data from storage - Delete: te...