How to practise subnetting effectively
Subnetting becomes quick only with repetition. Work through a few questions a day, say your reasoning out loud, and use the explanation to find the step you got wrong. Check the answer with the IP subnet calculator when you are unsure, and keep the subnet cheat sheet handy until the block sizes are memorised.
The block-size method
- Convert the prefix to a mask and find the octet where the mask is neither 255 nor 0 (the “interesting octet”).
- Block size = 256 − mask value in that octet. For /26 (255.255.255.192) the block size is 64.
- The network address is the largest multiple of the block size that is ≤ the IP’s value in that octet.
- The broadcast address is the next network address minus 1.
- Usable hosts run from network + 1 to broadcast − 1.
Host 192.168.1.130/26
Block size = 256 − 192 = 64 (networks at 0, 64, 128, 192)
Network = 192.168.1.128
Broadcast = 192.168.1.191
Usable = 192.168.1.129 – 192.168.1.190 (62 hosts)Powers of two to memorise
| Host bits | Addresses | Usable | CIDR |
|---|---|---|---|
| 2 | 4 | 2 | /30 |
| 3 | 8 | 6 | /29 |
| 4 | 16 | 14 | /28 |
| 5 | 32 | 30 | /27 |
| 6 | 64 | 62 | /26 |
| 7 | 128 | 126 | /25 |
| 8 | 256 | 254 | /24 |
Ready to go deeper? Read subnetting explained, then try variable-length planning with the VLSM calculator.