An administrator needs to change the DNS domain search order of a single Linux host to localize it better. Which of the following files should the administrator edit?
Correct Answer C. /etc/nsswitch.conf
Linux Changing DNS Search Order
Under Linux you need to use /etc/nsswitch.conf file which is used by system databases and Name Service Switch configuration file.
Open /etc/nsswitch.conf file using text editor:
# vi /etc/nsswitch.conf
Look for hosts:
hosts: files dns mdns4
Set above order as per your requirement. Close and save the file.
we can configure /etc/nsswitch.conf to define if we are going to use a static file like /etc/hosts to resolve names first, a DNS resolver as a second choice and even maybe a NIS server as a third.
Personally, the way I've always done it (RHEL, OEL, CentOS) is
IF I wanted to change the domain search order, that's /etc/resolv.conf
IF I wanted to make sure it reads the /etc/hosts file FIRST before DNS, then that's /etc/nsswitch.conf
Just my $.02
The referenced url doesn't show how to change the DNS domain search order. It shows how to configure the different resources we have in a Linux server to resolve name.
Yes, we can configure /etc/nsswitch.conf to define if we are going to use a static file like /etc/hosts to resolve names first, a DNS resolver as a second choice and even maybe a NIS server as a third.
But that is not a proper answer for the question.
Rigth answer is "A". You can change the domain search order for DNS, just reordering the "domain" entries in /etc/resolv.conf.
upvoted 2 times
...
This section is not available anymore. Please use the main Exam Page.XK0-004 Exam Questions
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
Dan_Dan_The_Data_Center_Man
Highly Voted 3 years, 6 months agoDidi31
3 years, 3 months agoDiaaEmara
Most Recent 2 years, 5 months agovirtualko
2 years, 8 months agoo0o0
3 years, 12 months agorjrpaz
4 years ago