Hi,

...on Tue, Jul 12, 2005 at 02:02:11PM +0200, Rapha??l Berbain wrote:

 > I have a box running bind as a cache+forwarder setup.  It connects to
 > the ISP through DHCP.  When dhclient kicks in, it fetches the
 > ISP-provided DNS IPs and by default puts those in /etc/resolv.conf.
 > Instead of that, I'd like /etc/resolv.conf to point to localhost.
 > I'd also like dhclient to tell bind to use the DNS IPs it got by dhcp
 > as forwarders.  I can think of several ways to keep /etc/resolv.conf
 > pointing to localhost, but I can't find a way to have dhclient update
 > bind's idea of forwarders IPs.

dhclient has the "supersede" option for the first 
part, something like supersede domain-name-servers 127.0.0.1; 
in your interface section, see dhclient.conf(5) for 
details.

For the other part, if you're running your own nameserver, 
why would you want to use forwarders at all? 

The only way to change the bind settings would be through 
a script that does it. But I don't think you could run 
it from dhclient, as there's no way I know of to pass the 
retrieved name server information to a script.

Possibly write a script that requests the name server data 
from the DHCP server independent of dhclient, and update 
the bind config from there.
 
Alex.

Reply via email to