/30 subnet
A /30 fixes the first 30 bits of the address and leaves 2 for hosts. That gives 4 addresses and subnet mask 255.255.255.252.
Example: 192.168.1.0/30
- CIDR block
- 192.168.1.0/30
- Network address
- 192.168.1.0
- Broadcast address
- 192.168.1.3
- Usable host range
- 192.168.1.1 – 192.168.1.2
- Total addresses
- 4
- Usable hosts
- 2
- Subnet mask
- 255.255.255.252
- Wildcard mask
- 0.0.0.3
- Mask in binary
- 11111111.11111111.11111111.11111100
Check another address in the subnet calculator.
Where you see a /30
- It is the traditional size for a point-to-point link between two routers: one network address, two hosts and one broadcast address.
What fits inside a /30
Splitting 192.168.1.0/30 into /32 blocks starts with 192.168.1.0/32, 192.168.1.1/32, 192.168.1.2/32, 192.168.1.3/32.
How many fit in a larger block
- A /8 holds 4,194,304 blocks of /30.
- A /16 holds 16,384 blocks of /30.
- A /24 holds 64 blocks of /30.
A /30 in the cloud
| Provider | Usable addresses |
|---|---|
| AWS VPC | Not allowed: the smallest subnet is /28 |
| Azure Virtual Network | Not allowed: the smallest subnet is /29 |
| Google Cloud VPC | Not allowed: the smallest subnet is /29 |
Each provider reserves addresses in every subnet: AWS VPC 5, Azure Virtual Network 5, Google Cloud VPC 4 (primary range).
Questions
How many hosts are in a /30 subnet?
A /30 has 4 addresses. Two are reserved for the network and broadcast addresses, which leaves 2 usable hosts.
What is the subnet mask for a /30?
The subnet mask for a /30 is 255.255.255.252, written in binary as 11111111.11111111.11111111.11111100. The wildcard mask is 0.0.0.3.
What is an example of a /30 range?
192.168.1.0/30 runs from 192.168.1.0 to 192.168.1.3. Hosts use 192.168.1.1 to 192.168.1.2, and 192.168.1.3 is the broadcast address.