Open ardixit-msft-la opened 5 months ago
/assign @nawazkh
@ardixit-msft-la could you be more specific what "manual deletion of self-hosted cluster is attempted before deleting through kubectl command" means? This way we can repro.
Specifically, we need more info on repro step 2 above.
Thanks!
cc @nojnhuh
/assign @nawazkh
@ardixit-msft-la could you be more specific what "manual deletion of self-hosted cluster is attempted before deleting through kubectl command" means? This way we can repro.
- Create an AKS cluster managed by CAPZ
- Manually delete <something???>
- Attempt to delete cluster object from CAPI mgmt cluster
- Observe that cluster gets stuck in Deleting state
Specifically, we need more info on repro step 2 above.
Thanks!
cc @nojnhuh
Correct.
Here are the steps.
@ardixit-msft-la Sorry for the delay.
- Create a Self-Hosted cluster managed by CAPZ
- Manually delete the resource group hosting the self-hosted cluster from Azure portal
- Attempt to delete cluster object from CAPI mgmt cluster
- Observe that cluster gets stuck in Deleting state
I dont see the erronous behavior by following the steps shared above. I am using CAPZ main for the repro and K8s: v1.28.5. Can you share the version of CAPZ and Kubernetes where you see this error ?
Also, can you delineate the steps even more? Are the steps 2 and 3 performed immediately one after the other? Or are you waiting for step 2 to finish before executing step 3 ?
Retried with CAPZ v1.13.2 and K8s v1.28.5 but could not repro this issue.
I am using k8s version 1.26.0 and I have the live environment for the same. Please let me know, I can help you with that.
Can you please share the CAPZ version as well?
I am not sure where/how can I find CAPZ version. Can you please help?
I am not sure where/how can I find CAPZ version. Can you please help?
One of the ways is to get the version suffixed to capz-controller-manager-xyz
pod from the management cluster.
The Kubernetes project currently lacks enough contributors to adequately respond to all issues.
This bot triages un-triaged issues according to the following rules:
lifecycle/stale
is appliedlifecycle/stale
was applied, lifecycle/rotten
is appliedlifecycle/rotten
was applied, the issue is closedYou can:
/remove-lifecycle stale
/close
Please send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle stale
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.
This bot triages un-triaged issues according to the following rules:
lifecycle/stale
is appliedlifecycle/stale
was applied, lifecycle/rotten
is appliedlifecycle/rotten
was applied, the issue is closedYou can:
/remove-lifecycle rotten
/close
Please send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle rotten
/kind bug
[Before submitting an issue, have you checked the Troubleshooting Guide?]
What steps did you take and what happened: [A clear and concise description of what the bug is.] In cases where manual deletion of self-hosted cluster is attempted before deleting through kubectl command, the cluster never gets deleted. On reattempting manual deletions, the resources are recreated while the provisioning state of the cluster is shown as deleting. kubectl --kubeconfig C:\Users\ardixit.kube\management get clusters![image](https://github.com/kubernetes-sigs/cluster-api-provider-azure/assets/98077868/d8c2661d-b8d7-4c8e-80aa-3dbd45352dbb)
What did you expect to happen: After the deletion is attempted through the following command
kubectl --kubeconfig C:\Users\ardixit.kube\management delete cluster flexiblec220849
The cluster should be deleted instead of hanging the deleting state. The cluster should not be recreated.
Anything else you would like to add: [Miscellaneous information that will assist in solving the issue.] This issue was reproduced with an AKS setup with 4 cluster, each having 5 user nodepools. The issue is intermittent and happens twice in approx. 10 runs.
Environment:
kubectl version
):/etc/os-release
):