Does bind read /etc/hosts?

Lightner, Jeff JLightner at dsservices.com
Tue Jul 15 17:15:03 UTC 2014


The confusion can come in because some UNIX variants (notably HP-UX) nslookup was modified to honor /etc/nsswitch.conf so it DOES check /etc/hosts if "files" precedes "dns".

However, in most things (e.g. Linux, Solaris) nslookup (and the newer host command) do not look at /etc/hosts regardless of nsswitch.conf setting.



-----Original Message-----
From: bind-users-bounces at lists.isc.org [mailto:bind-users-bounces at lists.isc.org] On Behalf Of Niall O'Reilly
Sent: Tuesday, July 15, 2014 6:57 AM
To: houguanghua
Cc: bind-users at lists.isc.org
Subject: Re: Does bind read /etc/hosts?

At Tue, 15 Jul 2014 10:28:30 +0000,
houguanghua wrote:
>
> Before Bind consults authority NS, does it access /etc/hosts? In my
> testing, it does not even seem to access /etc/hosts.

  That's right.  BIND tools (dig, ...) are DNS tools.
  Local files aren't part of the DNS.

  For more information, please see
http://serverfault.com/questions/498500/why-does-the-host-command-not-resolve-entries-in-etc-hosts

  Best regards,
  Niall O'Reilly
_______________________________________________
Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list

bind-users mailing list
bind-users at lists.isc.org
https://lists.isc.org/mailman/listinfo/bind-users

Athena(r), Created for the Cause(tm)
Making a Difference in the Fight Against Breast Cancer

__________________________________________________________
CONFIDENTIALITY NOTICE: This e-mail may contain privileged

or confidential information and is for the sole use of the intended

recipient(s). If you are not the intended recipient, any disclosure,

copying, distribution, or use of the contents of this information

is prohibited and may be unlawful. If you have received this electronic

transmission in error, please reply immediately to the sender that

you have received the message in error, and delete it. Thank you


More information about the bind-users mailing list