Add support for force deleting VM when its provisioning state is FAILED #115
Labels
kind/enhancement
Enhancement, improvement, extension
status/closed
Issue is closed (either delivered or triaged)
What would you like to be added:
In Azure if a Virtual Machine has
ProvisionState
set toFailed
then it neither be updated or deleted. In this case the VM is stuck in this state. If the associated resources (NIC, OSDisk and DataDisk) have to be updated to set cascade delete then that will fail as in this state the VM updates are not allowed. Azure will return the following:In these situations, the VM should be deleted, followed by explicit deletion of all associated resources (NIC, OSDisk and DataDisk(s)).
Why is this needed:
This ensures that VM and its associated resources are cleaned up properly.
We have seen multiple issues in Canary [Issue #4358, #4389, #4390, #4377] where VM's were stuck with
ProvisioningState = Failed
for days and nothing could be done to clean them up. Operators would have to manually go and issue delete for the VMs. With this issue we attempt to clean up all resources automatically.The text was updated successfully, but these errors were encountered: