Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 30 May 2003 22:13:35 GMT
From:      Mark <admin@asarian-host.net>
To:        "Laszlo Vagner" <george@vagner.com>, <questions@freebsd.org>
Subject:   Re: how to stop resolv.conf from being updated
Message-ID:  <200305302213.H4UMDYRM075476@asarian-host.net>
References:  <3ED79E49.30803@vagner.com>

next in thread | previous in thread | raw e-mail | index | archive | help
----- Original Message ----- 
From: "Laszlo Vagner" <george@vagner.com>
To: <questions@freebsd.org>
Sent: Friday, May 30, 2003 8:09 PM
Subject: how to stop resolv.conf from being updated


> I am using DHCP on a cable modem and my
> providers nameserver really sucks
> but changing my resolv.conf repairs
> the lookups for a little while then it gets
> set back to them upon bootup.
>
> how do i make it stay the way i set it.


Using brute force to prevent /etc/resolv.conf from being changed (with a
suggested chmod or chflags) is, imho, not the way. Play by the book, and put
something like this in /etc/resolv.conf:

prepend domain-name "my.nameserver.net ";
prepend domain-name-servers 194.0.0.1;
supersede domain-name "my.nameserver.net "

The trailing spaces ARE intentional. That worked like a charm for me, and
will "survive" a reboot. Substitute your own ISP, of course.

- Mark



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200305302213.H4UMDYRM075476>