Practice Test 1 | Google Cloud Certified Associate Cloud Engineer | Dumps | Mock Test
Your department head has asked you to create a new custom manual VPC with three subnets having 20 usable IP addresses individually. Which subnet mask suits your requirement?
A. 24
B. 28
C. 18
D. 27
Explanation:
Correct Answer – D
IPv4 consists of 4 octets which sum up to 32 bit.
The formula to calculate the number of hosts is 2 power of n where n is the difference between 32 and subnet mask to be used. In this case, it will be 2 power of 5 = 32 hosts. In each CIDR block, two IPs are reserved: one for the network address and another one for broadcast which leaves us with 30 usable IP addresses.
32 – 27 = 5
2 power of 5 = 32 total IP addresses
32 – 2 = 30 usable IP addresses
Option D is correct: A subnet mask of 27 gives you 30 usable IP addresses.
Option A is incorrect: 24 subnet mask gives you 254 addresses which is more than required.
Option B is incorrect: Subnet mask of 28 leaves you with only 14 usable IPs.
Option C is incorrect: A subnet mask of 18 provides you 16,382 IP addresses.
Reference:
Comments are closed, but trackbacks and pingbacks are open.