Weird DNS behaviour

Rapael Morcha raphael.morcha at gmail.com
Wed Oct 24 10:14:55 UTC 2007


On Wed, Oct 24, 2007 at 07:00:32AM +0300, Edgars Šmits wrote:
> Glad someone took up the challenge...
> 
> Nothing in my resolve.conf:

It's resolv.conf :)

> 
> edgars at gutsy-64:/etc$ more resolv.conf
> # generated by NetworkManager, do not edit!
> nameserver 192.168.0.1
> edgars at gutsy-64:/etc$

Make sure your modem/router if any, has the DNS information. Also make sure there is no local DNS running. If your modem/router doesn't have DNS information, try appending your DNS entries in /etc/resolv.conf as many as you like. If one fails, the other one gets used up. To get information on what is listening in on the network -
$ netstat -tupan
learn more in netstat(8).

E.g., on my Ubuntu machine- 
$ less /etc/resolv.conf
nameserver 208.67.222.222
nameserver 208.67.220.220

My router DNS entries -
$ less /etc/resolv.conf
nameserver 208.67.222.222
nameserver 208.67.220.220

My router processes -
PID  Uid     VmSize Stat Command
75 nobody        628 S    /usr/sbin/ddnsd

DNS is running there.

> > > I'm running DHCP, and other machines with Ubuntu that have been
> > > connected to the same DHCP server have no problems. The problem seems

I don't think this is DHCP problem. As long as your interface gets valid IP address from the DHCP server and your router's up, there shouldn't be a problem.

> > > to be almost transient in nature, a few nights ago I couldn't resolve
> > > www.cbc.ca, today I can, although vmware etc are still not resolving.

I am pretty sure if it's not resolving then it has to be DNS problem. But it's hard to pinpoint without more information. If it works in windows, then its resolving the host probably through your modem/router and not using the local entries. But since I haven't used windows for a while now, I can't say much.

> > > Any ideas where I should start looking? I have managed to work around
> > > the problem using the XP image, but would prefer to figure out what is
> > > causing it and fix it.

Try few situations. Look around tcpdump/ethereal and if you want, try-
* inspecting few packets
* their destination, source 
* ack/nack/rst if any from the server your machine is trying to connect.
* if it hangs in resolving state, then its time to switch your DNS to another one.

This could also be your firewall. Try isolating the problem one by one. It could be lot of factors that come in. It's important in identifying and isolating the sitution. It could be your resolvconf library.i anything is possible. :-)Hard to infer without knowing more.

-- 
Cheers,
Raphael.




More information about the ubuntu-users mailing list