Announcement

Collapse
No announcement yet.

/etc/resolve.conf and DHCP with bad DNS

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    /etc/resolve.conf and DHCP with bad DNS

    Hello and thanks for reading this post.

    I have an ISP (cable network) with a really bad DNS server that dies often and never works well on the best of days. I have now started using OpenDNS and it makes a HUGE difference.

    The problem is that every time I bring my system (laptop) out of suspend or reboot, my new entries in /etc/resolve.conf are wiped out and I get the bad DNS's back in the file.

    I've tried to comment out the old ones---doesn't work.
    I've tried to make the file read only---doesn't work.

    How can I keep my OpenDNS IP's without loosing them in this file without borking my system?

    I am still running dapper here with all the security updates.

    Thanks so much for any assist!
    --<br />wishing you well

    #2
    Re: /etc/resolve.conf and DHCP with bad DNS

    Since you are using DHCP, there's not much to be done, because it is the nature of DHCP to update your resolv.conf to whatever the server sends.
    You can hard set the DNS in your ifcfg-eth0 file, but because of DHCP, I don't know if it is fully overwritten upon connecting. The DNS in this script bypasses the resolv.conf file. I don't remember the syntax, but it is something like DNS=IP.

    Comment


      #3
      Re: /etc/resolve.conf and DHCP with bad DNS

      maybe this works for you:

      edit /etc/dhcp3/dhclient.conf

      go to the line that says:
      #prepend domain-name-servers 127.0.0.1;

      and add a line there:
      prepend domaine-name-servers 208.67.222.222, 208.67.220.220;
      Once your problem is solved please edit the first post of your topic and add [SOLVED] in front of the subject. In that way, others can benefit from your experience!

      Comment

      Working...
      X