DNS, DHCP, VLANs, and VPNs

7 free practice questions for the CompTIA® A+® Core 1 (220-1201) exam, from the networks and protocols domain. Pick an answer, then open the explanation to check it.

Every question is original and written for Gapwise with AI. Two separate AI reviewers answered each one without seeing the answer key and checked it against the cited public sources. These are not real exam questions.

Question 1

A small company's web server, www.example.com, is given the IPv6 address 2001:db8:10::25. Clients that use IPv6 can't find the server by name, although IPv4 clients can. Which Domain Name System (DNS) record is missing?
  1. A. Text (TXT) record
  2. B. Mail exchanger (MX) record
  3. C. A record
  4. D. AAAA record
Show the answer and explanation

Answer: D. AAAA record

AAAA records hold 128-bit IPv6 addresses, while A records hold IPv4 addresses. A dual-stack server usually needs both under the same name. Here IPv4 lookups work, so the A record is fine, and the gap is the AAAA record.

Why each option is right or wrong

  • A. Incorrect. TXT records hold descriptive text, such as email authentication policies. They don't give clients an address to connect to.
  • B. Incorrect. An MX record tells other mail servers where to deliver email for the domain. Web clients don't use it.
  • C. Incorrect. An A record holds an IPv4 address. IPv4 clients already resolve the name, so the A record exists.
  • D. Correct. An AAAA record stores one IPv6 address for a name. Without it, IPv6 clients have no IPv6 address to use for www.example.com.

References

Question 2

A domain already has the TXT record "v=spf1 mx -all". To approve a new billing service, a technician publishes a second TXT record: "v=spf1 include:billing.example.net -all". Soon after, receivers report a permanent error when they check the domain's Sender Policy Framework (SPF) policy. What should the technician do?
  1. A. Change -all to +all in the second record
  2. B. Move the second record to a subdomain named billing
  3. C. Combine both into one SPF record with mx and the include
  4. D. Replace the TXT records with a mail exchanger (MX) record
Show the answer and explanation

Answer: C. Combine both into one SPF record with mx and the include

SPF allows only one record per name. When a receiver finds two records that start with v=spf1, the check returns a permanent error. The fix is a single record that lists every authorized source, such as "v=spf1 mx include:billing.example.net -all". This mistake is common when a second email service is added.

Why each option is right or wrong

  • A. Incorrect. +all would authorize every host on the internet to send for the domain. It also leaves two SPF records in place, so the error remains.
  • B. Incorrect. An SPF record applies at the name it is published under. A record at a subdomain wouldn't authorize the billing service for the main domain.
  • C. Correct. A name may have only one SPF record. Two records cause a permanent error, so the mechanisms must be merged into one record.
  • D. Incorrect. SPF must be published as a TXT record. An MX record names the inbound mail host and can't carry an SPF policy.

References

Question 3

A company's outbound mail server adds a DomainKeys Identified Mail (DKIM) signature to every message it sends for example.com. Where does a receiving server get the key it uses to check that signature?
  1. A. From a TXT record under _domainkey in the signer's domain
  2. B. From a certificate issued by a public certificate authority
  3. C. From the signing domain's mail exchanger (MX) record
  4. D. From a key file attached to the body of each message
Show the answer and explanation

Answer: A. From a TXT record under _domainkey in the signer's domain

DKIM signs each message with the sending domain's private key and puts the signature in a header field. The receiver reads the selector and domain from that header and queries a TXT record such as selector._domainkey.example.com for the public key. A valid signature shows that the domain took responsibility for the message and that the signed content wasn't changed.

Why each option is right or wrong

  • A. Correct. DKIM public keys are published as DNS TXT records under the _domainkey subdomain. The receiver queries the signer's domain for that record.
  • B. Incorrect. DKIM deliberately avoids depending on certificate authorities. The key comes straight from the signing domain's DNS.
  • C. Incorrect. MX records name the hosts that accept inbound mail. They don't carry keys.
  • D. Incorrect. The signature travels in a message header field. A key sent with the message would prove nothing, since anyone could attach one.

References

Question 4

A conference center's guest Wi-Fi uses a Dynamic Host Configuration Protocol (DHCP) pool of about 200 addresses with a seven-day lease. Each day about 300 different visitors connect, and most stay a few hours. By midweek, new guests can't get an address. Which change BEST fixes this?
  1. A. Create reservations for the regular visitors' devices
  2. B. Add an exclusion range inside the guest pool
  3. C. Shorten the lease duration to a few hours
  4. D. Give the guest network a second DNS server
Show the answer and explanation

Answer: C. Shorten the lease duration to a few hours

Dynamic allocation lets a DHCP server reuse an address once its lease expires. With week-long leases, each departed visitor's address stays tied up for days, so a busy guest network runs dry. Matching the lease length to how long devices really stay frees addresses quickly. Long leases suit stable office desktops; short leases suit high-turnover guest networks.

Why each option is right or wrong

  • A. Incorrect. Reservations tie fixed addresses to known devices. They would use up even more of the pool and don't help one-time guests.
  • B. Incorrect. An exclusion range removes addresses from what the server can hand out, which makes the shortage worse.
  • C. Correct. Short leases expire soon after visitors leave, so the server can reuse those addresses for new guests the same day.
  • D. Incorrect. Name resolution isn't the problem. Guests can't get an IP address at all, so DNS settings won't help.

References

Question 5 Multiple answers

A company plans to publish a Domain-based Message Authentication, Reporting, and Conformance (DMARC) policy for its domain. DMARC builds on other email authentication methods. Which TWO methods produce the authenticated domain identifiers that DMARC checks? (Select two.)
  1. A. Sender Policy Framework (SPF)
  2. B. Mail exchanger (MX) preference values
  3. C. DomainKeys Identified Mail (DKIM)
  4. D. Canonical name (CNAME) aliases
  5. E. AAAA records of the sending host
Show the answer and explanation

Answers: A. Sender Policy Framework (SPF); C. DomainKeys Identified Mail (DKIM)

DMARC passes a message when the domain in the visible From address aligns with a domain that SPF or DKIM has validated. SPF validates the envelope sender's domain against the sending host. DKIM validates a domain's cryptographic signature. That is why domain owners set up SPF and DKIM first, then publish DMARC.

Why each option is right or wrong

  • A. Correct. A validated SPF domain from the message is one of the authenticated identifiers DMARC uses.
  • B. Incorrect. MX preference only orders a domain's inbound mail hosts. It authenticates nothing about a sender.
  • C. Correct. The signing domain from a validated DKIM signature is the other authenticated identifier DMARC uses.
  • D. Incorrect. CNAME records create name aliases. They don't validate who sent a message.
  • E. Incorrect. An AAAA record maps a name to an IPv6 address. It doesn't authenticate the sender's domain.

Reference

Question 6

A technician runs a name lookup for intranet.example.com from a workstation. The reply lists the address 2001:db8:40::15 for that name. Which Domain Name System (DNS) record type supplied this address?
  1. A. A record
  2. B. Pointer (PTR) record
  3. C. Canonical name (CNAME) record
  4. D. AAAA record
Show the answer and explanation

Answer: D. AAAA record

AAAA records map a host name to an IPv6 address, while A records map a name to an IPv4 address. The name hints at the size: an IPv6 address is four times as long as an IPv4 address. A dual-stack host usually has both an A and an AAAA record under the same name, and the client picks which to use.

Why each option is right or wrong

  • A. Incorrect. An A record holds a 32-bit IPv4 address, such as 192.0.2.15. It can't hold an IPv6 address like this one.
  • B. Incorrect. A PTR record works in the other direction. It maps an address back to a name in a reverse lookup.
  • C. Incorrect. A CNAME record maps an alias to another host name. The lookup then needs an address record for that name to get an address.
  • D. Correct. An AAAA record stores one 128-bit IPv6 address for a name, which is what 2001:db8:40::15 is.

Reference

Question 7

A company adds a new floor on its own subnet, 192.168.20.0/24. The router forwards that floor's Dynamic Host Configuration Protocol (DHCP) requests to the existing DHCP server, which serves 192.168.10.0/24. PCs on the new floor get 169.254 addresses, while the old floor still works. What is MOST likely missing?
  1. A. An exclusion range for the new floor's addresses
  2. B. A reservation on the server for each new PC
  3. C. A longer lease duration on the existing scope
  4. D. A scope on the server for 192.168.20.0/24
Show the answer and explanation

Answer: D. A scope on the server for 192.168.20.0/24

A DHCP server picks the address pool by the subnet a request came from, or by the address of the relay that forwarded it. Each subnet needs its own scope, with its address range, mask, lease time, and options such as the default gateway. Here the relay works, but the server has nothing to offer for 192.168.20.0/24, so the PCs fall back to 169.254 addresses.

Why each option is right or wrong

  • A. Incorrect. An exclusion range stops the server from leasing certain addresses. Adding one would hand out fewer addresses, not more.
  • B. Incorrect. Reservations are made inside a scope for specific devices. Without a scope for the new subnet, there's nowhere to put them, and they aren't needed for ordinary PCs.
  • C. Incorrect. Lease length doesn't matter here. The existing scope's addresses belong to the other subnet and wouldn't work on the new floor anyway.
  • D. Correct. A scope is the range of addresses and options for one subnet. With no scope for the new subnet, the server has no addresses to offer those PCs.

References