> Hi, > > I have read the man pages, searched a few forums, but I did not found a > way to prevent dhcp to do not change my /etc/resolv.conf. I do not have
You can write a script to fix resolv.conf right after dhclient ruined it. The way to do it is to hook it from /etc/dhclient-exit-hooks (which you'll need to create). Here's mine, which calls two other scripts (not included), one of which only if the IP address actually changed. This one also gets the new servers as arguments. ------------------------------ /etc/dhclient-exit-hooks # nothing to do unless we're bound case ${reason} in BOUND | RENEW | REBIND | REBOOT ) [ -x /etc/set-ntp ] && . /etc/set-ntp if [ -n "${new_domain_name_servers}" ]; then if [ -z "${old_domain_name_servers}" ] || [ x${old_ip_address} != x{$new_ip_address} ]; then [ -x /etc/refresh-named ] && /etc/refresh-named ${new_domain_name_servers} fi fi ;; esac To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-questions" in the body of the message