Wednesday, January 25, 2023

Kubernetes pods stuck in terminating state

 First try to do the following:

kubectl delete pod -n <namespace>  <pod name> --force --grace-period=0


If that does not work then edit the pod, like:

kubectl edit pod -n <namespace>  <pod name>


And remove the finalizers section and save

finalizers:
- <something here>