What is "DNS resolution order" as configured by "/etc/nsswitch.conf" and "/etc/resolv.conf", and how do they interact?
Correct! Well done.
Incorrect.
The correct answer is A) "/etc/nsswitch.conf" sets the order sources like "/etc/hosts" and DNS are consulted for hostname lookups, while "/etc/resolv.conf" configures the actual DNS servers and search domains queried — together determining how "example.com" resolves to an IP
Correct Answer
"/etc/nsswitch.conf" sets the order sources like "/etc/hosts" and DNS are consulted for hostname lookups, while "/etc/resolv.conf" configures the actual DNS servers and search domains queried — together determining how "example.com" resolves to an IP
A common troubleshooting scenario involves checking "/etc/nsswitch.conf" to see if "hosts: files dns" means /etc/hosts entries take precedence over DNS, and checking "/etc/resolv.conf" to verify which DNS servers ("nameserver" lines) are actually being queried.