[root@k8s-master coredns]# kubectl get pod
NAME                     READY   STATUS        RESTARTS   AGE
nginx-7bb7cd8db5-5c7z9   1/1     Terminating   0          70m
nginx-7bb7cd8db5-t24hf   1/1     Running       0          57m


[root@k8s-master coredns]# kubectl delete pod nginx-7bb7cd8db5-5c7z9 --grace-period=0 --force

warning: Immediate deletion does not wait for confirmation that the running resource has been terminated. The resource may continue to run on the cluster indefinitely.
pod "nginx-7bb7cd8db5-5c7z9" force deleted


[root@k8s-master coredns]# kubectl get pod
NAME                     READY   STATUS    RESTARTS   AGE
nginx-7bb7cd8db5-t24hf   1/1     Running   0          60m


转载于:https://www.cnblogs.com/zc1741845455/p/11308986.html

Logo

K8S/Kubernetes社区为您提供最前沿的新闻资讯和知识内容

更多推荐