Kubectl cleanup pods

In this article let’s discuss about Kubectl cleanup pods. Let’s go through the following methods without any delay.

Method 1:

kubectl delete pod podname

If you are facing any issues with the above approach then try the alternative that is given below. It may look similar but have a try!

Method 2 :

# I deleted the resources in the below order and it worked for me.

# To get all the resources.

kubectl get pods,services,deployments,jobs,daemonset

# Delete the resources like below:

kubectl delete deployments 
kubectl delete services 
kubectl delete pods  --namespace=
kubectl delete daemonset 

Hope the above solution works.

Realted Posts : How to move word backwards console unix