Shrinking a PersistentVolumeClaim in Kubernetes
· 2 min read
To shrink a PersistentVolumeClaim (PVC) in OpenShift or Kubernetes, we need to:
- pause our deployments
- copy its data to a smaller, temporary PVC
- delete the original PVC
- create a new PVC with the original name
- copy the data from the temporary PVC to the new PVC
- restart our deployments