You need to create a new IPv4 subnet on the network. The subnet must support a maximum of 5,000 hosts and must have as few unused addresses as possible.How would you configure DHCP to support this subnet?
A. You should use a subnet mask of 255.255.255.0
B. You should use a subnet mask of 255.255.248.0
C. You should use a subnet mask of 255.255.240.0
D. You should use a subnet mask of 255.255.224.0
E. You should use a subnet mask of 255.255.128.0
F. You should use a subnet mask of 255.255.0.0
The answer is C, but I'm not sure how to to calculate it. Can someone assist?
You need a mask covering the given range. 255.255.240.0 is 4 bytes. First two are all ones and the third is 11110000 in binary. The fourth is all zeros.
The mask as a sequence of these four bytes has then 12 trailing zeros which tell you the amount of addresses you can have. 2^12 = 4096. Therefore I would say the right answer is D which has 13 trailing zeros and a range of 8192 IPs.