LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 05-04-2009, 07:46 AM   #1
ahmed_as8
Member
 
Registered: Nov 2008
Location: Egypt
Distribution: Ubuntu, SuSE
Posts: 101

Rep: Reputation: 16
resolv.conf changes automatically in Ubuntu


Hi all I am Using Ubuntu 8.10 & 9.04 & am joining a windows domain network .. everytime I change the nameserver of the resolv.conf .. it changes again automatically after I reconnect to network .. I am installing the Samba package of the Ubuntu .. is that the reason or anything else .. Thanks.
 
Old 05-04-2009, 08:02 AM   #2
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Linux Mint
Posts: 8,504

Rep: Reputation: 884Reputation: 884Reputation: 884Reputation: 884Reputation: 884Reputation: 884Reputation: 884
Hi,

Add your settings to /etc/dhcp3/dhclient.conf
 
Old 05-04-2009, 08:03 AM   #3
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 728Reputation: 728Reputation: 728Reputation: 728Reputation: 728Reputation: 728Reputation: 728
If you are using DHCP, you can configure your system to use fixed addresses for DNS*---or to get the addresses using DHCP. If is somewhere in the network configuration menus/utilities.

*Domain Name Service----the DNS servers are what is listed in resolv.conf
 
Old 05-08-2009, 07:00 AM   #4
steve_s
LQ Newbie
 
Registered: Sep 2007
Posts: 12

Rep: Reputation: 1
I have just resolved a similar problem after installing fc10.

It seems that the Network Manager causes resolv.conf to be clobbered when no DHCP is available. NM is supposed to update resolv.conf if the ifcfg-eth0 contains directive PEERDNS=yes. When DHCP tells it what servers to use, it uses those. If DHCP is unavailable NM reads ifcfg-eth0 for DNS directives and uses those instead. If no DHCP and no DNS directives are available then the update of resolv.conf should not take place - but it does, placing null values for DNS into resolv.conf.

I fixed this by writing DNS directives into ifcfg-eth0. I suppose equally one could block all NM activity with NM_CONTROLLED=no, or you could block updating resolv.conf with PEERDNS=no. I did it my way so that I could easily use DHCP when it becomes available.

On FC10 if, you have not set up any named network configuration profiles, the files read by NM are in /etc/sysconfig/networking/profiles/default/

Last edited by steve_s; 05-08-2009 at 07:01 AM. Reason: improved clarity
 
  


Reply

Tags
manager, network, resolvconf


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
/etc/resolv.conf getting automatically written over....HELP PLEASE! cbradlea Linux - Newbie 7 10-09-2007 08:02 PM
DNS Hosts.conf or resolv.conf problem mac_casey Suse/Novell 0 03-26-2006 09:21 AM
/etc/resolv.conf Pedroski Linux - Networking 1 06-22-2004 10:03 AM
resolv.conf?? wrat Linux - Newbie 3 06-14-2004 04:37 PM
resolv.conf is not updated automatically metalyric Linux - Networking 9 06-04-2004 05:51 AM


All times are GMT -5. The time now is 12:05 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration