DNS unreliable with a Linksys ADSL2MUE adsl modem

Derek Broughton news at pointerstop.ca
Mon Dec 26 15:39:11 UTC 2005


neil woolford wrote:

> I have a Linksys ADSL2MUE modem, connected to a Linksys WRT54G
> wireless/wired router.
> 
> When I first set this up, back in May this year, I found that there was
> a problem with DNS and DHCP using Ubuntu (Hoary back then, Breezy now).
> 
> I have set the modem to act as a DHCP server, this hands out address
> leases to wired and wireless machines without apparent problems.  It
> also sets the DNS to its own address (192.168.1.1).  If my laptop is
> running Windows 98 this works fine.  Under Ubuntu I don't get a DNS
> service on any of my machines.
> 
> The fix that has worked for me so far is one that others have also used
> with this and other modems, it is to edit /etc/dhcp3/dhclient.conf so
> that the line "prepend domain-name-servers" is uncommented (active) and

I'd call that a work-around rather than a fix.

> I recently found a link which suggests a more elegant method.
>
http://johnwilger.com/articles/2005/12/13/ubuntu-5-10-breezy-badger-update-dns-when-obtaining-dhcp-lease-on-windows-network
> 
> Basically what is suggested is to edit dhclient.conf so that the line
> with "send host-name" is uncommented and set to your hostname.  For me
> the following line works fine.
> 
> send host-name "localhost.localdomain";
> 
> Naturally this also works with the actual literal hostname.

I don't understand how that can have _any_ effect on whether DNS works
(_especially_ if you actually used localhost.localdomain).  This sends a
hostname to the DHCP server, so that the DHCP server will add it to its own
DNS.  In my case, then, my wireless router is "saxon.pointerstop.ca" at
192.168.22.1.  My wife's windows machine is named "morgen" and from my own
machine I can find "morgen.pointerstop.ca".  Before adding "send hostname"
to my dhclient.conf, I couldn't find my own machine - "othello".  Now:

 derek at othello:~$ nslookup othello
  Server:         192.168.22.1
  Address:        192.168.22.1#53
  Name:   othello.pointerstop.ca
  Address: 192.168.22.105

However, it doesn't change your DNS settings at all, it just makes others on
your subnet able to find you by name.

> My problem?  This works on the first machine I tried it on, but not on
> the subsequent two (both also running Breezy).  They still require the
> cruder fix of prepending fixed DNS addresses.  Does anyone have any idea
> what might be going on here?

At a guess, I'd suggest something else is overwriting your resolv.conf after
DHCP.  Unfortunately there are a lot of things that could do it.  What does
"nslookup" show as the server address it's using?  If it does have the
correct address, do you have port #53 firewalled?

If the DNS server address is wrong, do you have resolvconf installed?  I'd
suggest removing that, at least temporarily, as it _will_ overwrite your
resolv.conf, and you don't need it to while you're connected to this
router.  You might try using "watch" to see if you can see what's happening
to resolv.conf.
-- 
derek





More information about the ubuntu-users mailing list