mediumMultiple ChoiceObjective-mapped
XK0-006 Practice Question: A system administrator is troubleshooting a DNS…
A system administrator is troubleshooting a DNS resolution issue. The command `dig example.com` returns a response, but `ping example.com` fails with 'ping: example.com: Name or service not known'. Which of the following is the most likely cause?
⚠ Common exam trap
CompTIA often tests the distinction between tools that use the system resolver (like `ping`, `ssh`, `curl`) and those that perform their own DNS resolution (like `dig`, `nslookup`, `host`), trapping candidates who assume all tools use the same resolution path.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
The system resolver is using different DNS servers than dig
The `dig` command bypasses the system resolver and queries the DNS server directly, so it can resolve the name even if the resolver is misconfigured. `ping` uses the system resolver (glibc's `gethostbyname` or `getaddrinfo`), which may be configured to use different DNS servers (e.g., via NetworkManager, systemd-resolved, or a local caching resolver). This mismatch causes `ping` to fail while `dig` succeeds.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
An incorrect entry in /etc/hosts
Why it's wrong here
Would affect both commands if present.
- ✗
The Name Service Cache Daemon (nscd) is not running
Why it's wrong here
Would affect both if caching were expected.
- ✓
The system resolver is using different DNS servers than dig
Why this is correct
dig uses resolver settings in /etc/resolv.conf but may use its own; inconsistent config can cause this.
- ✗
The DNS server is not configured in /etc/resolv.conf
Why it's wrong here
Then dig would also fail.
- ✗
A firewall is blocking ICMP packets
Why it's wrong here
Firewall would affect ping after resolution.
Visual reference
Go deeper
Related to this question
Learn chapter
Process Management and System Monitoring
Key term
systemd
systemd is a system and service manager for Linux operating systems that initializes and manages processes, services, and system resources after the kernel boots.
Key term
Service
A service is a software component or system that performs a specific function and is available to be used by other programs or users over a network.
About these practice questions
One of 979 original XK0-006 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This XK0-006 practice question is part of Courseiva's free CompTIA certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the XK0-006 exam.