【发布时间】:2021-04-16 10:53:42
【问题描述】:
我在终止集群中的命名空间时遇到问题,它在命名空间 JSON 中显示了许多参数。我点击了这个链接https://medium.com/@craignewtondev/how-to-fix-kubernetes-namespace-deleting-stuck-in-terminating-state-5ed75792647e
"spec": {},
"status": {
"conditions": [
{
"lastTransitionTime": "2021-01-11T08:41:48Z",
"message": "All resources successfully discovered",
"reason": "ResourcesDiscovered",
"status": "False",
"type": "NamespaceDeletionDiscoveryFailure"
},
{
"lastTransitionTime": "2021-01-11T08:41:48Z",
"message": "All legacy kube types successfully parsed",
"reason": "ParsedGroupVersions",
"status": "False",
"type": "NamespaceDeletionGroupVersionParsingFailure"
},
{
"lastTransitionTime": "2021-01-11T08:41:48Z",
"message": "All content successfully deleted, may be waiting on finalization",
"reason": "ContentDeleted",
"status": "False",
"type": "NamespaceDeletionContentFailure"
},
{
"lastTransitionTime": "2021-01-11T08:42:09Z",
"message": "All content successfully removed",
"reason": "ContentRemoved",
"status": "False",
"type": "NamespaceContentRemaining"
},
{
"lastTransitionTime": "2021-01-11T08:41:48Z",
"message": "All content-preserving finalizers finished",
"reason": "ContentHasNoFinalizers",
"status": "False",
"type": "NamespaceFinalizersRemaining"
}
],
"phase": "Terminating"
}
}```
【问题讨论】:
-
当 webhook 仍然处于活动状态时,我已经看到了这一点。在这种情况下,删除命名空间大约需要 30 分钟。你等了多久?
-
自 215 分钟后仍显示终止
-
@SaikatChakrabortty 不,即使我尝试了
kubectl delete ns fleet-system --grace-period=0 --force --namespace -n fleet-systemwarning: Immediate deletion does not wait for confirmation that the running resource has been terminated. The resource may continue to run on the cluster indefinitely.也无济于事:删除集群范围的资源,而不是提供的命名空间命名空间“fleet-system”强制删除并卡在这里-- ----
标签: kubernetes namespaces amazon-eks rancher