<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:΢ÈíÑźÚ
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>Sorry for what I said isn't very clear. I did know when the /etc/hosts is accessed in the OS.<BR>What I want to know is whether the named access the hosts file. The /etc/hosts file isn't in the client's system, but in the system of Local DNS server where the 'named' task runs. For example:<BR>      In the /etc/hosts file of Local DNS server(LDNS), one line exists as follows:<BR>          10.10.10.1     <a href="http://www.google.com">www.google.com</a>   <BR>     A client querys this LDNS to get the IP of 'www.google.com' (the client may use dig,nslookup command. No host line is configured in /etc/hosts of this client ), what IP will be returned to the client?  Can the LDNS  return 10.10.10.1 defined in the /etc/hosts to the client?  maybe some special configuration in named can support this feature.<BR> <BR>Thanks,<BR>Guanghua<br> <BR><div>> To: houguanghua@hotmail.com<br>> CC: bind-users@isc.org<br>> From: marka@isc.org<br>> Subject: Re: Does bind read /etc/hosts?<br>> Date: Tue, 15 Jul 2014 20:38:12 +1000<br>> <br>> <br>> In message <BAY173-W11D824E324939A1BB89852BBF60@phx.gbl>, houguanghua writes:<br>> > Dear sir/madam,<br>> >  <br>> > Before Bind consults authority NS, does it access /etc/hosts?  In my <br>> > testing,  it does not even seem to access /etc/hosts. But someone tells <br>> > me Bind can access /etc/hosts first. Can you pls tell me how to config <br>> > Bind to access /etc/hosts fist?<br>> >  <br>> > Thanks,<br>> > Guanghua<br>> <br>> No.<br>> <br>> getaddrinfo, gethostbyname etc. however may access /etc/hosts, NIS,<br>> mDNS, DNS and other databases.  You need to read the documentation<br>> that comes with your system for how to control these.<br>> <br>> Mark<br>> -- <br>> Mark Andrews, ISC<br>> 1 Seymour St., Dundas Valley, NSW 2117, Australia<br>> PHONE: +61 2 9871 4742                 INTERNET: marka@isc.org<br></div>                                           </div></body>
</html>