在部署kuboard控制平台的时候,不规范删除,导致ns状态为Terminating
[root@master01 ~]# kubectl delete namespace kuboard
^C
root@master01 ~]# kubectl get ns
NAME STATUS AGE
default Active 25h
kube-flannel Active 24h
kube-node-lease Active 25h
kube-public Active 25h
kube-system Active 25h
kuboard Terminating 21h
[root@master01 ~]#
尝试1,还是不行
使用 -grace-period=0 --force 参数强行删除,还是不行
[root@master01 ~]# kubectl delete namespace kuboard --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.
namespace "kuboard" force deleted
^C
[root@

在尝试删除kuboard命名空间时遇到问题,状态保持为Terminating。首先尝试使用kubectl的--grace-period=0--force参数强制删除,但未成功。然后通过kubernetes-API来删除:获取命名空间的JSON文件,编辑移除finalizers配置,通过kubectlproxy开启代理,最后使用curl更新API以删除命名空间,成功解决了问题。
最低0.47元/天 解锁文章

被折叠的 条评论
为什么被折叠?



