Fedora Linux Support Community & Resources Center

Go Back   FedoraForum.org > Fedora 17/18 > Servers & Networking
FedoraForum Search

Forgot Password? Join Us!

Servers & Networking Discuss any Fedora server problems and Networking issues such as dhcp, IP numbers, wlan, modems, etc.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 14th November 2008, 10:10 PM
bluespruce Offline
Registered User
 
Join Date: Nov 2008
Posts: 3
Local manual DNS settings won't stick; ISP keeps overwriting, please help!

The title pretty much says it all. I already unchecked the 'aquire dns settings automatically' box, yet every time I put in the DNS servers I would LIKE to use, save the settings and reconnect, I find they've reverted to the ISP standard! It's really become quite infuriating.

This started about a week-10 days ago and has become more and more resistant to my efforts to change them.

Many thanks in advance to anyone able to keep me from pulling my hair out
Reply With Quote
  #2  
Old 17th November 2008, 03:25 PM
bluespruce Offline
Registered User
 
Join Date: Nov 2008
Posts: 3
It was suggested to me on another forum that I should try to chmod the file to write protect it. How do I do that? What file should I chmod?
Reply With Quote
  #3  
Old 17th November 2008, 03:55 PM
aleph's Avatar
aleph Offline
Banned (for/from) behaving just like everybody else!
 
Join Date: Jul 2007
Location: Beijing, China
Posts: 1,307
Quote:
Originally Posted by bluespruce View Post
The title pretty much says it all. I already unchecked the 'aquire dns settings automatically' box, yet every time I put in the DNS servers I would LIKE to use, save the settings and reconnect, I find they've reverted to the ISP standard! It's really become quite infuriating.

This started about a week-10 days ago and has become more and more resistant to my efforts to change them.

Many thanks in advance to anyone able to keep me from pulling my hair out
I suggest you create a file (as root) in the /etc directory with name "dhclient-INTERFACE.conf" where INTERFACE is the connection's network interface (e.g. eth0). Put the following line in the file:
Code:
supersede domain-name-servers DNS1, DNS2, DNS3;
where DNS1-3 are your preferred DNS servers. You don't have to use all three of them. Usually putting two there is fine.

After that, restart the network service, and see if it works.
__________________
I believe in nerditarianism. I read FedoraForum for the Fedora-related posts.
Reply With Quote
  #4  
Old 18th November 2008, 12:18 PM
ibbo's Avatar
ibbo Offline
Registered User
 
Join Date: Jun 2005
Location: Leeds
Posts: 1,264
you can also edit you /etc/rc.local file and add

Code:
echo # DNS config >  /etc/resolve.conf
echo nameserver PRIMARY_DNS >> /etc/resolve.conf
echo nameserver SECONDRY_DNS >> /etc/resolve.conf
echo nameserver TERIATRY_DNS >> /etc/resolve.con
This basically overwrites your resolve.conf (which stores your DNS settings) and adds your preferred DNS servers instead.

Just run /etc/rc.local after you edit it. It runs by itself after your machine has booted up so you edit and leave it unless your DNS changes.

aleph
Nice one. You learn something new every day.

Ibbo
__________________
A Hangover Lasts A Day, But Our Drunken Memories Last A Lifetime
--
Linux user #349545
(GNU/Linux)iD8DBQBAzWjX+MZAIjBWXGURAmflAKCntuBbuKCWenpm XoA7LNydllVQOwCfdjyzXscddzQvlhBedAcD7qfKmHo==zx0H
Reply With Quote
  #5  
Old 18th November 2008, 03:35 PM
vallimar Offline
Registered User
 
Join Date: Jul 2008
Posts: 800
Quote:
Originally Posted by bluespruce View Post
It was suggested to me on another forum that I should try to chmod the file to write protect it. How do I do that? What file should I chmod?
Just for reference, they were talking about the immutable flag.
This is enabled by doing: chmod +i <file>
Reply With Quote
  #6  
Old 18th November 2008, 08:16 PM
bluespruce Offline
Registered User
 
Join Date: Nov 2008
Posts: 3
Quote:
Originally Posted by vallimar View Post
Just for reference, they were talking about the immutable flag.
This is enabled by doing: chmod +i <file>
actually, to be specific, he said to chmod +x the file /etc/resolv.conf "so its not rewriteable" (however, this is coming from a freebsd user, so neither of us are sure how accurate the info is)

What is the immutable flag?

Sorry I haven't been able to give any feedback, I haven't had the time to sit down at my own computer in a bit, but I really appreciate the suggestions!

I'll be sure to let you guys know as soon as I get things back up and running

Last edited by bluespruce; 18th November 2008 at 08:17 PM. Reason: left something out
Reply With Quote
  #7  
Old 19th November 2008, 11:22 AM
ibbo's Avatar
ibbo Offline
Registered User
 
Join Date: Jun 2005
Location: Leeds
Posts: 1,264
The immutable flag denotes whether a file can be modified or not. +i = immutable = no modifiable. -i is the opposite.

chmod +i file on a file that is modified at boot time (or will attempt to be modified) will no doubt issue complaint after complaint. Thus it is not the correct way to do it and the alternative options listed above should be taken up instead.

I.E

edit rc.local
or
the option given by aleph

It always better to do it right that to hack it out. hack it out and you will have to hack it again at some stage.

Ibbo
__________________
A Hangover Lasts A Day, But Our Drunken Memories Last A Lifetime
--
Linux user #349545
(GNU/Linux)iD8DBQBAzWjX+MZAIjBWXGURAmflAKCntuBbuKCWenpm XoA7LNydllVQOwCfdjyzXscddzQvlhBedAcD7qfKmHo==zx0H
Reply With Quote
Reply

Tags
dhcp, dns

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Ipv4 Manual settings,firefox headphones billy123 Fedora 12 Alpha, Beta & Release Candidates 0 23rd September 2009 09:05 AM
NIC GUI card settings don't stick markdx Fedora Focus 1 20th February 2009 12:24 AM
Is Fedore/Linux a manual stick shift car? vbelenky Fedora Focus 17 17th December 2007 10:52 PM
What keeps overwriting/modifying yum(ex).conf? jsmaye Using Fedora 7 27th April 2005 02:31 PM
YUM updates overwriting config files? jferguso Using Fedora 0 25th October 2004 10:13 PM


Current GMT-time: 18:41 (Sunday, 19-05-2013)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat