Determining the Number of IP Subnets and Hosts
Created by a valid mask. No CIDR or VLSM.
Use the first octet of the IP address to determine the class of address (A, B, or C).
18.104.22.168 = CLASS B
Use the class of the address to determine which octets are available for hosts.
CLASS B = Network. Network. Host. Host
Look at the host octet(s) in the subnet mask. Use the "Possible Masks" chart to determine which bits are set to one. If no bits are set to one, there are no subnets. If any bits are set to one, proceed to step four.
255.255.255.192 = 11111111 11000000 (host octets only)
Count the total number of ones in the host octet(s) of the subnet mask. Call this number X. Raise 2 to the power of X. Use the "Powers of 2" chart if necessary. This is the number of potential subnets created by the mask. Two of these potential subnets are normally not usable.
11111111 11000000 = 10 ones. 210 = 1,024 - 2 = 1,022 usable subnets created.
Count the total number of zeros in the host octet(s) of the subnet mask. Call this number Y. Raise 2 to the power of Y. Use the "Powers of 2" chart if necessary. This is the number of potential subnets created by the mask. Two of these numbers are never used to address hosts.
11111111 11000000 = 6 zeros. 26 = 64 - 2 = 62 usable host addresses created.