understanding "domain" option in /etc/resolv.conf
In /etc/resolv.conf file one can specify domain option which should refer to local domain name. According to resolv.conf manual "Most queries for names within this domain can use short names relative to the local domain.". In case of such /etc/resolv.conf file:
Code:
domain linuxquestions.org Code:
domain linuxquestions.org |
very good question m4rtin!!
i've never ask that to myself. i use Code:
domain example.tld i'll look at this thread too! thanks! |
|
jefro:
you haven't answered our question: the link you point talks about the classic resolv.conf: Code:
search example.com what is the point of having a line with domain, as can be found on the default resolv.conf of many recent distros? Code:
domain example.com |
I believe the article addresses this case.
"search cyberciti.biz nameserver 202.54.1.10 nameserver 202.54.1.11" Where "search domain.com: The search list is normally determined from the local domain name; by default, it contains only the local domain name. So when you type nslookup www, it will be matched to www.cyberciti.biz" |
Quote:
|
Hmm, I think that quote DOES explain it. It certainly looks like the domain option is ignored for searches in an alternative search value is specified. I *presume* this is a legacy issue, and the search management logic was added in later on without breaking compatibility.
So just DON'T specify a search value and the domain option is totally valid. Personally I would have thought the searches would be searched after the domain value is searched, but if it's coded differently then so be it I guess. |
All times are GMT -5. The time now is 06:45 AM. |