An administrator is configuring a new virtual network named `vnet-retail` with an address space of . The administrator needs to configure two subnets within this virtual network:
1. A workload subnet that must support exactly virtual machines, each requiring a dynamic private IP address. The subnet must be configured with the minimum possible address space to satisfy this requirement.
2. A subnet named `AzureBastionSubnet` to deploy Azure Bastion.
What is the maximum number of usable IP addresses that can be allocated to `AzureBastionSubnet`?
- 123Cevap
- B126
- C59
- D62
Cevap
123 usable IP addresses
To support exactly 27 virtual machines, the workload subnet requires 32 total IP addresses because Azure reserves 5 IP addresses in every subnet (the first four and the last one). A /27 prefix provides exactly 32 IP addresses, which is the minimum size that satisfies this requirement. The virtual network has a /24 address space (256 IP addresses). Subtracting the 32 addresses used by the workload subnet leaves 224 IP addresses. Azure Bastion requires a subnet named AzureBastionSubnet with a prefix of at least /26. To maximize the usable addresses, we can allocate a /25 subnet (128 IP addresses) from the remaining space, as a /24 subnet would require 256 addresses and cause an overlap. Subtracting the 5 Azure-reserved IP addresses from the 128 addresses in a /25 subnet yields 123 usable IP addresses.
Adım Adım Çözüm
Anahtar Kavram
Azure Virtual Network subnet sizing constraints and reserved IP addresses