Technotes for future me

Kubernetes pvc deleting stuck in Terminating state

Please try to troubleshoot and delete remaining resources. Do not force removals unless you know what you are doing. See:

This usually happens because something is preventing a resource from being deleted, causing namespace deletion to be stuck. It is necessary to troubleshoot which resources are failing to be deleted and why.


PVC is probably still attached to node in cluster, check with:

kubectl get volumeattachment

Forcing a Deletion of a Namespace

Patch the PVC to set the “finalizers” setting to null, this allows the final unmount from the node, and the PVC can be deleted.

kubectl patch pvc {PVC_NAME} -p '{"metadata":{"finalizers":null}}'


Last updated on 17 Sep 2021
Published on 31 Aug 2021
Edit on GitHub