Re: Name resolution w/ multiple connections
- From: Peter Garrett <peter.garrett@xxxxxxxxxxxxxxx>
- Date: Wed, 28 Feb 2007 11:06:45 +1100
On Tue, 27 Feb 2007 17:55:19 -0500
Anthony Yarusso <tonyyarusso@xxxxxxxxxxxxx> wrote:
So, what I need to know, is how to have both the modem and
wireless LAN connections up at the same time while maintaining
nameserver stuff through the dialup connection (except for things
defined in the hosts file as being local, like "duluth 192.168.1.5")
The DNS settings are being re-written by DHCP from the router. If you want
the nameservers to remain the same, you can override this with an "enter
hooks" file/script. The idea is to pre-empt the replacement of
the /etc/resolv.conf file by your router.
make a file, /etc/dhcp3/dhclient-enter-hooks containing the following:
#!/bin/bash
# Stop overwriting /etc/resolv.conf !
function make_resolv_conf {
echo “Doing nothing to resolv.conf”
}
Make the "script" executable
sudo chmod +x /etc/dhcp3/dhclient-enter-hooks
When you next bring up the wireless interface, your nameservers should
remain unchanged. just make sure you have the ones that you need
in /etc/resolv.conf . It's a funny solution ( a script that explicitly
does nothing), but it works
I use this here to define my own nameserver IPs and avoid having the ISPs
numbers and/or router IP constantly reappearing in /etc/resolv.conf Simply
making /etc/resolv.conf unwritable does not work, because dhcp actually
*replaces* the /etc/resolv.conf file and not just its contents.
Give it a try :-)
Peter
--
ubuntu-users mailing list
ubuntu-users@xxxxxxxxxxxxxxxx
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
- References:
- Name resolution w/ multiple connections
- From: Anthony Yarusso
- Name resolution w/ multiple connections
- Prev by Date: default dapper install, raid, first is swap, unbootable
- Next by Date: Re: Copy everything bar one folder
- Previous by thread: Name resolution w/ multiple connections
- Next by thread: Thunar
- Index(es):
Relevant Pages
|