Solved

resolv.conf keeps getting reset, erasing my nameserver ips with localhost info

Posted on 2004-03-23
5
2,079 Views
Last Modified: 2013-11-22
Hello:
I'm recently having a problem with all internet apps, in that the nameserver file /etc/resolv.conf keeps getting reset to:

search homeland.net
nameserver 192.168.1.1  (neither of which actually works, of course!)

instead of what I want it to be, which is:

nameserver 205.152.46.254
nameserver 205.152.144.235

I have a backup file that I keep having to replace the resolv.conf file in order to connect to things, but this is obviously very tedious...Any idea what could be causing this?
0
Comment
Question by:haldrik
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 62

Expert Comment

by:gheist
ID: 10664738
DHCP client software ...
0
 

Author Comment

by:haldrik
ID: 10678240
Thanks for the tip-- I guess what I wanted to know was how to correct this...I'm using whatever the default DHCP client was the default during installation.
0
 
LVL 62

Assisted Solution

by:gheist
gheist earned 30 total points
ID: 10679105
Then it adds nameserver as dhcp server says.
look at "man 5 dhclient.conf"
and then edit the described file to avoid overwriting resolv.conf.
resolver order is mentioned in /etc/nsswitch.conf btw
0
 

Accepted Solution

by:
mjoyner earned 70 total points
ID: 10826657
Put something along these lines into your /etc/dhclient.conf

put in your ethernet card name for rl0
put in your host-name
put in your DNS info instead of 127.0.0.1 (unless you are wanting to run named locally)

interface "rl0" {
        send host-name "yourhost.dynip.com";
        prepend domain-name-servers 127.0.0.1;
}
0
 

Author Comment

by:haldrik
ID: 10856085
Well, I seem to have solved this problem with a combination of the last comment, which I accepted in its entirety, and also by adjusting the /etc/nsswitch.conf file as suggested by gheist (the actual changes I looked up on another site). I am unable to reproduce the error at this point (even by undoing the fixes), so I cant only say that I believe that the point split that I did here is the fairest solution I could think of.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Installing FreeBSD… FreeBSD is a darling of an operating system. The stability and usability make it a clear choice for servers and desktops (for the cunning). Savvy?  The Ports collection makes available every popular FOSS application and packag…
Why Shell Scripting? Shell scripting is a powerful method of accessing UNIX systems and it is very flexible. Shell scripts are required when we want to execute a sequence of commands in Unix flavored operating systems. “Shell” is the command line i…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question