Search code examples
azurenetwork-programmingcidrvirtual-address-space

Create App Service Environment Subnet address space issue


I am trying to create a new Azure App Service Environment within an existing virtual network that contains two address spaces. In this case I am trying to create the subnet in the second address space as shown below.

enter image description here

When I then try to create a new Subnet Address Block of 172.31.12.0/25 the Azure Portal tells me that the "Subnet not contained in the address space". Surely this is correct as the CIDR Range is from 172.31.12.0 - 172.31.12.127 for this range.

enter image description here

The sites validation will allow me to create a small range within the 172.31.11.0/24 range but this isn't what I need.

Anyone know what I am missing here?


Solution

  • It's the same error as you on my side. It looks like a restriction or something else like that on the Azure portal. It seems that you only could select the subnet address block from the original address space for the ASE. Even I change to select the Virtual Network Address Block to the second address space and create the subnet in the original address space, this still works.

    enter image description here

    update

    As a workaround, you could create an ASE subnet from the second address space via this ARM template.

    1. Create a second address space in the Azure VNet mynettest enter image description here
    2. Create a subnet2 in this address space. enter image description here
    3. Use the above parameters to deploy the template. Create an ASE in the subnet2. enter image description here