IP Addressing & CIDR

What it is

Classless Inter-Domain Routing (CIDR) is the notation Azure uses for all IP ranges (10.0.0.0/24), and IP addressing is how a VNet and its subnet carve up and assign IPv4/IPv6 addresses. Azure resources get both private addresses (inside a VNet) and optionally public addresses (reachable from the internet).

Why it exists

You need a convention to state how big a network is and which addresses a resource may use. CIDR compresses “netmask + network” into one string so Azure can validate that subnets fit inside a VNet and don’t overlap.

Key ideas

  • CIDR /N/value = number of fixed (network) bits. /24 = 256 addresses, of which ~251 usable in Azure after reserved gateway/DNS/broadcast.
  • Private (RFC 1918) ranges commonly used: 10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16. Azure allows any private range, including custom ones like 192.168.0.0/24; VMs inherit from there.
  • Public IP — assigned by you (static/standard) or Azure (dynamic/basic SKU), tied to a NIC/PIP/load balancer.
  • IPv6 — Azure supports IPv6 on VNets/subnets (dual-stack) for public and some private scenarios.
  • IP address types: public (internet) vs private (VNet-internal); dynamic vs static IP allocation.

Key facts (memorize)

  • Default subnet usable range = 2^(32-N) − 5 (Azure reserves 5 per subnet: 4 first + 1 last).
  • A VNet can have at most 1 default (and up to ~400 total) address ranges; subnets must fit within one range.
  • Private IP addresses can be static (reserved) or dynamic; a dynamic private IP reassigned on VM restart unless it’s a NIC-level static.

How it fits

cidr-ip-addressing.svg

Exam notes

  • Always confirm no overlap between VNet ranges and peered VNets / ExpressRoute/corporate ranges — overlap breaks peering and routing.
  • Use the smallest subnet that fits to conserve address space (exam likes subnet sizing questions, e.g. how many /24s fit in a /16 → 256).
  • Public IP SKUs: Basic vs Standard; Standard requires explicit outbound and works with load balancers.

Home · subnet · vnet · azure-dns · network-watcher

📘 Source: Microsoft Learn — Cidr Ip Addressing