how to stop resolv.conf from being updated
Lowell Gilbert
freebsd-questions-local at be-well.no-ip.com
Fri May 30 11:46:33 PDT 2003
T Kellers <kellers at njit.edu> writes:
> A sledgehammer approach to make it work:
>
> Comment out the following lines from /sbin/dhclient-script
>
> make_resolv_conf() {
> if [ x"$new_domain_name_servers" != x ]; then
> if [ "x$new_domain_name" != x ]; then
> echo search $new_domain_name >/etc/resolv.conf
> else
> rm /etc/resolv.conf
> fi
> for nameserver in $new_domain_name_servers; do
> echo nameserver $nameserver >>/etc/resolv.conf
> done
> fi
> }
Less of a sledgehammer for a similar effect:
prepend domain-name-servers 127.0.0.1;
[or wherever your nameserver should be]
As an option in dhclient.conf(5)
You can use supersede instead, if you *really* don't want to go to the
ISP's servers, even if yours fails.
More information about the freebsd-questions
mailing list