Ubuntu Forums ubuntu.com - launchpad.net - ubuntu help  

Go Back   Ubuntu Forums > The Ubuntu Forum Community > Forum Archive > Main Support Categories > Networking & Wireless
Register Reset Password Forum Help Forum Council Search Today's Posts Mark Forums Read

Hello, Unregistered You are browsing a READ only archive of the main support categories pre 4/21/2008. You will not be able to post or reply any threads in this section.

Networking & Wireless
Having problems getting connected to the internet or getting your wireless card to work? Ask here.

 
Thread Tools Display Modes
Old November 30th, 2004   #1
ILikePretzels
First Cup of Ubuntu
 
Join Date: Nov 2004
Beans: 1
Network settings keep resetting

In the Network Settings menu, I made some changes to the DNS servers and search domains. After I restarted my computer, the changes were gone. I then created a profile and saved it with the same information. Upon rebooting again, the current network profile had gone back to "Unknown".

How can I make my changes stick around permanently?
ILikePretzels is offline   Reply With Quote
Old December 7th, 2004   #2
wallijonn
Quad Shot of Ubuntu
 
wallijonn's Avatar
 
Join Date: Oct 2004
Location: Phoenix
Beans: 437
Re: [resolved] Network settings keep resetting

Isn't that part of /etc/resolv.conf ?
wallijonn is offline   Reply With Quote
Old December 11th, 2004   #3
dkitty
Just Give Me the Beans!
 
Join Date: Dec 2004
Beans: 69
Ubuntu 6.06
Re: [resolved] Network settings keep resetting

I'm having the same problem. I tried editing resolv.conf but as the file says...

DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN

Any other ideas?
dkitty is offline   Reply With Quote
Old December 26th, 2004   #4
mpjbrennan
First Cup of Ubuntu
 
Join Date: Dec 2004
Beans: 5
Re: [resolved] Network settings keep resetting

I got my settings to persist by commenting out the function make_resolv_conf() in /etc/dhcp3/dhclient-script.

patrick
mpjbrennan is offline   Reply With Quote
Old January 8th, 2005   #5
AndyGates
5 Cups of Ubuntu
 
AndyGates's Avatar
 
Join Date: Nov 2004
Location: UK
Beans: 22
Re: [resolved] Network settings keep resetting

Quote:
Originally Posted by mpjbrennan
I got my settings to persist by commenting out the function make_resolv_conf() in /etc/dhcp3/dhclient-script.

patrick
Weird, I tried that and it still changed them back! Any other ideas?
AndyGates is offline   Reply With Quote
Old January 8th, 2005   #6
billputer
5 Cups of Ubuntu
 
billputer's Avatar
 
Join Date: Jan 2005
Location: Salem, OR
Beans: 23
Ubuntu 6.06
Send a message via AIM to billputer
Re: [resolved] Network settings keep resetting

I was having the same problem, but editing out make_resolv_conf() fixed it. Good luck.
billputer is offline   Reply With Quote
Old March 9th, 2005   #7
AndyGates
5 Cups of Ubuntu
 
AndyGates's Avatar
 
Join Date: Nov 2004
Location: UK
Beans: 22
Re: [resolved] Network settings keep resetting

I have a nice bodgy solution which seems to stick

The file /etc/resolvconf/resolv.conf.d/base contains entries which will always be added, regardless of what resolv.conf also adds. It's empty by default. If you edit it:

sudo gedit /etc/resolvconf/resolv.conf.d/base

And add lines for your nameserver(s):

nameserver xxx.xxx.xxx.xxx
nameserver xxx.xxx.xxx.xxx


Then when resolvconf runs on startup, it will produce a resolv.conf file something like this:

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver xxx.xxx.xxx.xxx
nameserver xxx.xxx.xxx.xxx
nameserver 127.0.0.1
nameserver yyy.yyy.yyy.yyy


...and that works.
AndyGates is offline   Reply With Quote
Old April 16th, 2005   #8
dkitty
Just Give Me the Beans!
 
Join Date: Dec 2004
Beans: 69
Ubuntu 6.06
Re: [resolved] Network settings keep resetting

When resolv.conf was rewritten each time on startup I think it kept grabbing my Actiontec DSL modem's IP as a DNS entry. So I had a DNS entry along the lines of:

Code:
17.xxx.xxx.xx
And it wasn't working. Each time on reboot I had to delete that line from resolv.conf, open the network(ing) settings panel and do it there, or switch to a network profile (also via the network settings panel) that had valid DNS entries. It was a pain to do each time.

At first when I read mpjbrennan's suggestion to comment the make_resolv_conf function out of /etc/dhcp3/dhclient-script I only commented out the first line of it. Yeah, I'm a n00b. But I eventually found this post which detailed it a bit further. I smacked my forehead quite a bit when I first read it.

After properly commenting out the make_resolv_conf function and then writing my ISP's DNS entries into the network settings panel, I don't have any worries. Resolv.conf is no longer rewritten with my modem's IP at startup and I have instant internet access after I boot. Dig it.

Last edited by dkitty; April 16th, 2005 at 01:23 PM..
dkitty is offline   Reply With Quote
Old December 23rd, 2005   #9
dbreese
First Cup of Ubuntu
 
Join Date: Dec 2005
Beans: 4
Re: [resolved] Network settings keep resetting

Just came across this post and wanted to give advice on what I've done to fix this actiontec dsl modem dns issue.

The dhclient3 client runs /etc/dhcp3/dhclient-script can be extended by simply creating your own scripts under /etc/dhcp3/dhclient-*-hooks.d/. Check out the man pages for dhclient-script ($ man 8 dhclient-script) and read the HOOKS section.

What I did was just dropped the following script in as an exit hook, so it is executed after the /etc/resolv.conf is updated.

All this hack does is strip out the 192.168.1.1 crap that really doesn't work anyways.

Code:
$ cat /etc/dhcp3/dhclient-exit-hooks.d/check_actiontec_dns
BAD_IP=192.168.1.1
echo `date`: checking dns ordering for actiontec woes
grep ${BAD_IP} /etc/resolv.conf > /dev/null
if [ $? == 0 ]; then
        echo removing actiontec dns entry
        grep -v ${BAD_IP}  /etc/resolv.conf > /tmp/resolv.conf
        mv /tmp/resolv.conf /etc/resolv.conf
fi
One thing that may break for you is if you go to another wifi access point that is NOT actiontec and it only has a single 192.168.1.1 dns entry. If it did, then you'd end up with an empty /etc/resolv.conf file! Just use this script as a base....

Hope this helps,
Dustin
dbreese is offline   Reply With Quote
Old February 1st, 2008   #10
archon256
First Cup of Ubuntu
 
Join Date: May 2006
Beans: 6
Re: [resolved] Network settings keep resetting

I realised that my router was resetting the DNS to the wrong 192.168.1.1 every 10 seconds and even if I wrote via Network Settings (KDE) or directly into resolv.conf to use an alternative good one (194.72.6.51) after 10 seconds it got overwritten again to the 192.168.1.1 I was getting desperate and furious. Windows machines kept the alternate DNS in IP configuration without problems.
Then I found out (through a OpenSuse Live CD and YAST configuration) that to turn off the setting DNS via DHCP I had to change the resolv.conf instead of

search -name-
nameserver 192.168.1.1

to

domain site
nameserver 192.168.1.1
nameserver 194.72.6.51

That helped, since then the DNS stays as it should and my internet is working 100%
archon256 is offline   Reply With Quote

Bookmarks

Thread Tools
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


All times are GMT -4. The time now is 10:23 AM.


vBulletin ©2000 - 2010, Jelsoft Enterprises Ltd. Ubuntu Logo, Ubuntu and Canonical © Canonical Ltd. Tango Icons © Tango Desktop Project. lingonberry