Spot instances fail validation with InvalidTemplateDeployment

Jonathan Ragan-Kelley 6 Reputation points
2020-08-08T21:47:45.317+00:00

My first attempts to create spot VMs (using the web UI) are universally failing at the final validation step with:

{"code":"InvalidTemplateDeployment","message":"The template deployment failed with error: 'The resource with id: '/subscriptions/.../resourceGroups/builder_group/providers/Microsoft.Compute/virtualMachines/builder' failed validation with message: 'The requested size for resource '/subscriptions/.../resourceGroups/builder_group/providers/Microsoft.Compute/virtualMachines/builder' is currently not available in location 'eastus' zones '' for subscription '...'. Please try another size or deploy to a different location or zones. See https://aka.ms/azureskunotavailable for details.'.'."}

This applies in every zone I have tried. My quota listings show 350 vCPUs for nearly all VM types (including all I am trying), and 350 "spot CPUs" (these don't seem to be broken out by VM type). This validation failure does not occur using otherwise identical settings but with a non-spot instance.

What else do I need to check? What other quotas or subscription changes might I need to request from support to be able to create spot instances?

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,102 questions
{count} vote

2 answers

Sort by: Most helpful
  1. Didier3001 971 Reputation points Microsoft Employee
    2020-08-09T08:22:56+00:00

    Hi @Jonathan Ragan-Kelley

    You were right, Quota is the first thing to check. With Azure Spot VMs there are few more limitations that are not all visible and clear.

    1. Which type of Azure Subscriptions are you using? For example, it won't work with MSDN subscriptions. For CSP, you need to contact your Partner so that they can enable this for you. You can identify the details under "Subscription", then look for "Offer ID" and match it here: https://azure.microsoft.com/en-us/support/legal/offer-details/
    2. Some VMs are not available, B Series and any VM on "sales" (promo)

    Just to be 100% clear, how did you try to deploy them on the Azure Portal? Using a Template or just by going to "create a VM" on the portal?

    --I hope this helps. Please Accept it as an answer and "Up-Vote" the answer or message(s) that helped you so that it can help others in the community looking for help on similar topics

    Regards,
    Didier3001


  2. Didier3001 971 Reputation points Microsoft Employee
    2020-08-09T19:49:36.07+00:00

    Only a couple of subscriptions are supported for spot VM and I can't be 100% 0143p is one of them. Its a sponsored subscription so maybe. As you can see below, sponsored subscription seems to be supported:
    https://learn.microsoft.com/en-us/azure/virtual-machines/windows/spot-vms#limitations

    https://azure.microsoft.com/en-us/offers/ms-azr-0143p/

    I would open a case using that link:
    https://azure.microsoft.com/en-us/support/create-ticket/

    And provide

    1. Azure subscription number
    2. Offer id : 0143p
    3. Both links I provided

    --I hope this helps. Please Accept it as an answer and "Up-Vote" the answer or message(s) that helped you so that it can help others in the community looking for help on similar topics

    Regards,
    Didier3001