[K8S]Check the usage for PV/PVC in Kubernetes

stackoverflow: Is there an efficient way to check the usage for PV/PVC in Kubernetes

image.png

If there's a running pod with mounted PV from the PVC,

kubectl -n  exec  -- df -ah

...will list all file systems, including the mounted volumes, and their free disk space.

实际应用:
kubectl -n mongodb exec mongodb-0 -- df -ah

image.png

你可能感兴趣的:([K8S]Check the usage for PV/PVC in Kubernetes)