Unable to create subnets in Vnet using terraform

Chaitanya kumar 1 Reputation point

When I try to create Vnet, Subnets, NAT Gateway, Route tables from terraform script I'm getting following error.
Error: Error Creating/Updating Subnet "private-1" (Virtual Network "myvpc" / Resource Group "acceptanceTestResourceGroup2"): network.SubnetsClient#CreateOrUpdate: Failure sending request: StatusCode=400 -- Original Error: Code="SubscriptionNotRegisteredForFeature" Message="Subscription 60471ca2-f532-4ac9-8736-d89df5c2b54d is not registered for feature Microsoft.Network/AllowMultipleAddressPrefixesOnSubnet required to carry out the requested operation." Details=[]
Kindly check this error and reply back ASAP.

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
7,201 questions
{count} votes

4 answers

Sort by: Most helpful
  1. Andriy Bilous 11,011 Reputation points MVP

    What is the value for variable var.public_cidr?
    May you please share also your variables.tf file?

    3 people found this answer helpful.

  2. George Gildenhuys 1 Reputation point

    How did you fix this?

    I am getting feature Microsoft.Network/AllowMultipleAddressPrefixesOnSubnet when using either terraform or azcli:

    az network vnet subnet create --address-prefixes --name dynamicsubnet --resource-group Networking --vnet-name sandboxukso-private

    0 comments No comments

  3. NarenderSingh 61 Reputation points


    What was the solution of it? I am also getting the same error where I have 4 subnets in the variable list in my variable.tf?

    0 comments No comments

  4. Hagen Rahn 1 Reputation point

    Currently the required resource provider is not available for public access, GA or pre. so using this feature is not possible, if you are not working as MS developer.
    I have created a bug report to update terraform docu: https://github.com/hashicorp/terraform-provider-azurerm/issues/17052

    0 comments No comments