Friday, June 30, 2006
Linksys DNS Timeout Problem
I figured out why the Linksys WRT56G, v5 802.11g wireless router is making DNS queries time out. I used my favorite packet sniffer, called WireShark, to watch what happens when I tell a DNS query program to use my router as the root server. I got very different results from DIG and nslookup.
DIG tries to establish a Transmission Control Protocol (TCP) connection with the router, and the router completely ignores it! Nslookup, on the other hand, uses the connectionless User Datagram Protocol (UDP), and the router responds instantaneously! Voila! Mystery solved!
I'm still looking for a way to make the Linux DNS server use only UDP for queries, but I think I will find it's not possible and it's inadvisable. My understanding is that UDP is fine for short responses, and that TCP is necessary for long responses that get truncated. I bet people who use the Linksys router as their DNS server are unable to reach sites that have long responses.
technorati tags:Linksys, Router, DNS, Timeout, MacOSX, Linux, WRT56G, Problem
Yours,
Joel M. Halpern
On the bright side, I just ordered a WRT54G*L* (where "L" is for Linux). I didn't know Linksys made a Linux device until I read something about it a couple of days after I bought my last Linksys router. At least with 3rd party Linux firmware I'll be able to get things working right. I'll program it myself if I have to.
Another alternative on my Linux server is to scrape the DNS server addresses off the Linksys configuration screen.
Thanks for the comment, Joel.
In practice, I doubt that your provider changes DNS server addressses very often. So manually configuring those addresses (as you are doing) is probably sufficient.
The normal alternative is to arrange for access to two real DNS servers at well known addresses, with arrangements for them to accept recursive calls from you. That costs money, and is often packaged with commercial services.
There has been some work on local service name resolution to complement DNS. Apple has techniques for this. I don't know if anyone else has fielded solutions. The one proposed to the IETF had the problem that it tended to leak into real DNS space. (Microsoft essentially proposed the use of a .local tld, with alternative resolution techniques.)
Yours,
Joel
Linksys Router Support
<< Home