Free CompTIA Network+ IP Addressing and Subnetting Questions and Answers — Questions and Answers
Question 1: A network technician is setting up a small office network and needs to select an appropriate private IPv4 address range. Which of the following IP addresses is a valid, non-routable private IP address according to RFC 1918?
- 172.16.50.1 (Correct answer)
- 169.254.10.10
- 172.32.15.2
- 100.64.20.5
Correct answer: 172.16.50.1
RFC 1918 defines specific ranges for private, non-routable IP addresses. The Class B private range is 172.16.0.0 to 172.31.255.255. The address 172.16.50.1 falls within this range. 169.254.10.10 is an APIPA address, 172.32.15.2 is outside the private range, and 100.64.20.5 is part of the shared address space for carrier-grade NAT (CGN).
Question 2: A user reports they cannot access the internet, but they can access local file shares. A technician checks the user's IP configuration and finds the IPv4 address is 169.254.100.5. What is the MOST likely cause of this issue?
- The static IP address is misconfigured.
- The computer has a duplicate IP address on the network.
- The computer failed to obtain an IP address from a DHCP server. (Correct answer)
- The default gateway is offline.
Correct answer: The computer failed to obtain an IP address from a DHCP server.
The IP address 169.254.100.5 is an Automatic Private IP Addressing (APIPA) address. Windows and other operating systems assign these addresses when a device is configured for DHCP but cannot contact a DHCP server. This allows for local network communication but no internet access.
Question 3: A network administrator needs to create a subnet that can support at least 50 host devices. Which of the following CIDR notations provides the required number of host addresses while minimizing wasted addresses?
- /27
- /25
- /28
- /26 (Correct answer)
Correct answer: /26
A /26 CIDR notation leaves 6 bits for the host portion (32 - 26 = 6). The number of usable hosts is calculated as 2^6 - 2 = 62. This meets the requirement of 50 hosts. A /27 provides only 30 hosts (2^5 - 2), a /28 provides 14 hosts (2^4 - 2), and a /25 provides 126 hosts (2^7 - 2), which is more than necessary and wastes more addresses than /26.
Question 4: Given a host with the IP address 192.168.10.70 and a subnet mask of 255.255.255.224, what is the broadcast address for this subnet?
- 192.168.10.63
- 192.168.10.95 (Correct answer)
- 192.168.10.255
- 192.168.10.127
Correct answer: 192.168.10.95
The subnet mask 255.255.255.224 (/27) creates subnets with a block size of 32 in the last octet (256 - 224 = 32). The subnets are 192.168.10.0, 192.168.10.32, 192.168.10.64, etc. The IP 192.168.10.70 falls into the 192.168.10.64 subnet. The next subnet starts at .96, so the broadcast address for the .64 subnet is the address right before it, which is 192.168.10.95.
Question 5: Which of the following represents a valid Class C default subnet mask?
- 255.0.0.0
- 255.255.0.0
- 255.255.255.0 (Correct answer)
- 255.255.255.255
Correct answer: 255.255.255.0
In classful networking, a Class C network uses the first three octets (24 bits) for the network portion and the last octet (8 bits) for the host portion. This corresponds to a default subnet mask of 255.255.255.0.
Question 6: A network is designed using the IP address space 10.10.0.0/22. How many usable IP addresses are available for hosts on this network?
- 510
- 254
- 2046
- 1022 (Correct answer)
Correct answer: 1022
A /22 CIDR notation means that 22 bits are used for the network portion of the address. In a 32-bit IPv4 address, this leaves 10 bits for the host portion (32 - 22 = 10). The total number of host addresses is 2^10 = 1024. Since the network address and the broadcast address are reserved, the number of usable addresses is 1024 - 2 = 1022.
A network technician is setting up a small office network and needs to select an appropriate private IPv4 address range.
Which of the following IP addresses is a valid, non-routable private IP address according to RFC 1918?