Question

Difficulty: MediumCreate and Configure Virtual Networks and Subnets

An administrator is setting up `vnet-retail-prod` within an Azure subscription using the address space 10.40.0.0/1610.40.0.0/16. The design requires two subnets: one named `snet-app` to accommodate at least 1212 virtual machines, and one named `AzureBastionSubnet` for an Azure Bastion deployment. Which CIDR block prefix sizes represent the minimum requirements for both subnets?

  1. A
    A prefix of /28/28 for `snet-app` and /27/27 for `AzureBastionSubnet`
  2. B
    A prefix of /27/27 for `snet-app` and /27/27 for `AzureBastionSubnet`
  3. A prefix of /27/27 for `snet-app` and /26/26 for `AzureBastionSubnet`Answer
  4. D
    A prefix of /28/28 for `snet-app` and /26/26 for `AzureBastionSubnet`

Answer

A prefix of /27/27 for `snet-app` and /26/26 for `AzureBastionSubnet`
The correct configuration uses a prefix of /27/27 for the application subnet and /26/26 for the Azure Bastion subnet. The application subnet needs to support at least 1212 virtual machines. Since Azure reserves 55 IP addresses in every subnet (the first four and the last one), the subnet must have a total size of at least 12+5=1712 + 5 = 17 IP addresses. A /28/28 prefix provides only 1616 total IP addresses (leaving 1111 usable), which is not enough. A /27/27 prefix provides 3232 total IP addresses (leaving 2727 usable), making it the smallest valid prefix. Additionally, Azure Bastion requires a dedicated subnet named `AzureBastionSubnet` with a prefix of /26/26 or larger.

Step-by-Step Solution

1
Calculate the minimum IP address space required for the application subnet `snet-app` by factoring in the VM requirements and Azure's default IP reservations.
To host 1212 virtual machines, we must add the 55 IP addresses that Azure reserves in every subnet (the first four and the last one). This results in a requirement of at least 12+5=1712 + 5 = 17 total IP addresses.
This determines the minimum total size of the CIDR block for the application subnet.
2
Determine the smallest CIDR block prefix size that can accommodate the required total IP addresses for the application subnet.
A /28/28 subnet provides 23228=162^{32-28} = 16 total IP addresses (1111 usable), which is insufficient. A /27/27 subnet provides 23227=322^{32-27} = 32 total IP addresses (2727 usable), which satisfies the requirement of 1717 total IPs.
This identifies /27/27 as the minimum size for the application subnet.
3
Identify the minimum subnet prefix size constraint for Azure Bastion.
Azure Bastion must be deployed in a dedicated subnet named exactly `AzureBastionSubnet`, and it requires a minimum prefix size of /26/26 (6464 IP addresses).
This applies the platform-specific constraint for Azure Bastion deployments.

Key Concept

Azure Virtual Network subnet sizing rules, specifically the 5 reserved IP addresses per subnet and the minimum /26 prefix size constraint for Azure Bastion subnets.
Rate this question