View previous topic :: View next topic |
Author |
Message |
albright Advocate
Joined: 16 Nov 2003 Posts: 2588 Location: Near Toronto
|
Posted: Tue Jun 26, 2007 12:59 pm Post subject: force localhost into resolv.conf ... how? |
|
|
I'm stuck on dial up for the next couple of months. Having
a local caching nameserver speeds things up a little bit.
But I find that whenever I connect via dialup my /etc/resolv.conf
is overwritten and the line
Code: | nameserver 127.0.0.1 |
is removed. If I add it again everything works fine (I save about
a quarter second for almost *every* lookup -- hey, it adds
up )
I added
Code: | dhcp_eth0="nodns"
dhcp_eth1="nodns" |
but it had no effect. (Obviously, I want nameservers assigned
by the dialup connection, but I want localhost to remain the
first nameserver ...)
Anybody know how to force my local nameserver line to remain
in resolv.conf? TIA, _________________ .... there is nothing - absolutely nothing - half so much worth
doing as simply messing about with Linux ...
(apologies to Kenneth Graeme) |
|
Back to top |
|
|
Dizzutch Guru
Joined: 09 Nov 2004 Posts: 463 Location: Worcester, MA
|
Posted: Tue Jun 26, 2007 1:05 pm Post subject: |
|
|
a little trick that might work, is that once you have your nameservers from the DHCP server, you add the localhost ot your /etc/resolv.conf and then add
to your /etc/conf.d/net file, which tells dhcpcd to not overwrite your /etc/resolv.conf file. It's a workaround, however if your name servers change you have to remove the line, and release/renew...
_dizz _________________ Help the confused! Adopt an unanswered post!
prepend [solved] to your post title when you feel your issue is resolved.
Worcester Judo |
|
Back to top |
|
|
albright Advocate
Joined: 16 Nov 2003 Posts: 2588 Location: Near Toronto
|
Posted: Tue Jun 26, 2007 2:10 pm Post subject: |
|
|
thanks for the suggestion but it has no effect ...
It is the dial up connection process that is overwriting resolv.conf;
I need a way to prepend "nameserver 127.0.0.1" to resolv.conf
*after* ppp0 comes up ... _________________ .... there is nothing - absolutely nothing - half so much worth
doing as simply messing about with Linux ...
(apologies to Kenneth Graeme) |
|
Back to top |
|
|
|