Date: Sun, 14 Jan 2001 18:19:23 -0600 From: Glenn Johnson <glennpj@charter.net> To: Dennis Jun <dennisjun@home.com> Cc: freebsd-questions@FreeBSD.ORG, chat@gtabug.org Subject: Re: DNS caching, DHCP, /etc/resolv.conf Message-ID: <20010114181923.A1318@gforce.homelan.net> In-Reply-To: <001201c07e83$80c5dc00$0300a8c0@wilma>; from dennisjun@home.com on Sun, Jan 14, 2001 at 06:41:22PM -0500 References: <001201c07e83$80c5dc00$0300a8c0@wilma>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Jan 14, 2001 at 06:41:22PM -0500, Dennis Jun wrote: > Hello all! > > I recently setup a DNS caching server with named. I followed the > instructions in Lehey's "The Complete FreeBSD." However I'm on @home > and I my ip settings via dhcp. Thus it resets my /etc/resolv.conf all > the time, that is, it removes my first line of nameserver 127.0.0.1 > I'm wondering how can prevert/remedy this? I guess most people would > suggest a simple script cronned, but is there another solution? Yes there is. You need to create a file called /etc/dhclient-enter-hooks and make it executable. In this file (script) you set the variables that are part of dhclient-script. So for your case you would enter into the dhclient-enter-hooks file: new_domain_name_servers=127.0.0.1 When dhclient-script is run it will pick up the values in dhclient-enter-hooks. For more information, see the manual pages for dhclient and dhclient-script. -- Glenn Johnson glennpj@charter.net To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010114181923.A1318>