Stephen Gran on 7 Jun 2004 15:01:02 -0000 |
On Mon, Jun 07, 2004 at 10:29:05AM -0400, Jeff Abrahamson said: > My internal DNS mysteriously stopped working this morning. It only > affected unqualified local machine names. > > I got things mostly working by adding a couple lines to /etc/hosts. > But I'd like to figure out what went wrong and what I should really do > about it. > > My /etc/resolv.conf file says this: [snip] > On 192.168.0.5, where most of this should happen, /etc/resolv.conf > says [snip] Both snipped because they look fine. > Then I have db.purple: [snip] Which looks fine except for the localhost entry - that might confuse things, since bind also by default has a db.127 with this information. It shouldn't really hurt, though. > Here's the signature of the problem (one failed dig, one successful). > Seems that it's querying the wrong name server when I don't qualify. > jeff@asterix:jeff $ dig diderot [nothing] > jeff@asterix:jeff $ dig diderot.purple.com [normal] Does 'host' work as expected? I am not sure of the differences in implementation, but I see similar thing here - dig doesn't return anything on unqualified names for my internal DNS, but host does. I get the impression dig doesn't read resolv.conf for anything but nameservers. There is the command line switch +domain used ike so: dig gashuffer +domain=lobefin.net which does work as expected. Here is what I see: steve:~$ dig gashuffer ; <<>> DiG 9.2.4rc2 <<>> gashuffer ;; global options: printcmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 12970 ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0 ;; QUESTION SECTION: ;gashuffer. IN A ;; AUTHORITY SECTION: . 2221 IN SOA A.ROOT-SERVERS.NET. NSTLD.VERISIGN-GRS.COM. 2004060601 1800 900 604800 86400 ;; Query time: 2 msec ;; SERVER: 192.168.0.1#53(192.168.0.1) ;; WHEN: Mon Jun 7 10:53:21 2004 ;; MSG SIZE rcvd: 102 steve:~$ dig gashuffer.lobefin.net ; <<>> DiG 9.2.4rc2 <<>> gashuffer.lobefin.net ;; global options: printcmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 11437 ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 2 ;; QUESTION SECTION: ;gashuffer.lobefin.net. IN A ;; ANSWER SECTION: gashuffer.lobefin.net. 604800 IN A 192.168.0.5 ;; AUTHORITY SECTION: lobefin.net. 604800 IN NS mail.lobefin.net. lobefin.net. 604800 IN NS hadrian.lobefin.net. ;; ADDITIONAL SECTION: mail.lobefin.net. 604800 IN A 216.158.52.98 hadrian.lobefin.net. 604800 IN A 192.168.0.1 ;; Query time: 2 msec ;; SERVER: 192.168.0.1#53(192.168.0.1) ;; WHEN: Mon Jun 7 10:53:24 2004 ;; MSG SIZE rcvd: 128 steve:~$ host gashuffer gashuffer.lobefin.net A 192.168.0.5 But things work as expected: steve:~$ ping gashuffer PING gashuffer.lobefin.net (192.168.0.5): 56 data bytes 64 bytes from 192.168.0.5: icmp_seq=0 ttl=64 time=0.2 ms 64 bytes from 192.168.0.5: icmp_seq=1 ttl=64 time=0.1 ms --- gashuffer.lobefin.net ping statistics --- 2 packets transmitted, 2 packets received, 0% packet loss round-trip min/avg/max = 0.1/0.1/0.2 ms steve:~$ With: search lobefin.net domain lobefin.net nameserver 192.168.0.1 in resolv.conf HTH, -- -------------------------------------------------------------------------- | Stephen Gran | Fame is a vapor; popularity an | | steve@lobefin.net | accident; the only earthly certainty is | | http://www.lobefin.net/~steve | oblivion. -- Mark Twain | -------------------------------------------------------------------------- Attachment:
pgpHFMwdgWtat.pgp
|
|