If you run an Azure environment, you may occasionally encounter issues with virtual machines that fail to start. One standard error message you might encounter is “Failed to start virtual machine DIVECORP-AZU-01. Error: Allocation failed. If you are trying to add a new VM to an Availability Set or update/resize an existing VM in an Availability Set, please note that such Availability Set allocation is scoped to a single cluster. Therefore, the cluster may be out of capacity. Please read more about improving the likelihood of allocation success at http://aka.ms/allocation-guidance.” This error message can be particularly frustrating to deal with, but there are steps you can take to troubleshoot and resolve the issue.

Identifying the Issue

The first step in troubleshooting this error is to identify the root cause. In this case, the issue occurred when attempting to resize a disk that was part of a virtual machine in an availability set. After the VM was restored with Azure Backup, it failed to start with the “Allocation failed” error message.

Resolving the Issue

To resolve this issue, we contacted Microsoft support and were advised to stop and deallocate every VM in the availability set. This effectively shut down all the VMs in the availability set and allowed them to be restarted cleanly. Once all the VMs were deallocated and restarted, the issue was resolved, and the VM in question could start up without issue.

It is essential to remember that when working with virtual machines in an availability set, allocation is scoped to a single cluster, and the cluster can run out of capacity. To avoid allocation issues, follow best practices for managing and optimizing your Azure environment.

Conclusion

While encountering errors like “Allocation failed” can be frustrating, there are steps you can take to troubleshoot and resolve the issue. In this case, we resolved the issue by stopping and deallocating all the VMs in the affected availability set. Remember to remember best practices when managing your Azure environment and to contact Microsoft support if you need additional assistance. By staying vigilant and proactive in your Azure management, you can help prevent issues like this from occurring in the first place.

Thanks,

Cristal Kawula MVP