A released PV does not return to the pool¶
Claim — deleting a bound PVC moves its PV to Released, not Available, and no controller will ever move it back on its own. The reclaim policy decides who does.
Topology — pair, still up from the bind predictions, with its six PVs.
Do
- Delete one of the bound PVCs from the bind predictions. Watch its PV.
- State, before checking, what
Releasedmeans thatAvailabledoes not — in terms of theclaimRefstill sitting on the PV object. - Make it
Availableagain. Do it by the mechanism the controller respects, not by deleting and recreating the PV. - Repeat with a PV whose
persistentVolumeReclaimPolicyisDeleterather thanRetain, and withRecycleif the API still accepts it. Note which of the three the cluster actually performs and which is deprecated scaffolding.
Observe
kubectl get pv -o custom-columns=NAME:.metadata.name,STATUS:.status.phase,POLICY:.spec.persistentVolumeReclaimPolicy,CLAIM:.spec.claimRef.name
kubectl get pv <name> -o yaml | grep -A5 claimRef
Expect — Released with a stale claimRef naming a PVC that no longer exists. Clearing that field is what returns the PV to the pool; the Retain policy exists precisely so that a human looks at the data first. Delete removes the PV object and, with a real provisioner, the backing volume too — which is the setting that loses data when a namespace is deleted carelessly.
Write down — the three reclaim policies, which controller acts on each, and one sentence on why Retain is the safe default for a PV you created by hand.
Teardown — leave it up; the claimRef rewrite uses the same PVs.