Dear Matir,
Yes, I know. The search line in the resolv.conf is there, because I need it. I need to be able to enter a short name and the system should complete it with the domain name (adelior.local in my case). Anyway, I tried taking the search line out and it does not work either. This is what happens then:
bridgetown:/etc # ping ontario
ping: unknown host ontario
bridgetown:/etc # host ontario
Host ontario not found: 2(SERVFAIL)
bridgetown:/etc # ping ontario.adelior.local
ping: unknown host ontario.adelior.local
bridgetown:/etc # host ontario.adelior.local
ontario.adelior.local has address 192.168.5.55
bridgetown:~ # tcpdump -l -n -i eth0 'port 53'
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on eth0, link-type EN10MB (Ethernet), capture size 96 bytes
15:30:09.305776 IP 192.168.5.23.32933 > 192.168.5.11.53: 7074+ A? ontario. (25)
15:30:09.306088 IP 192.168.5.11.53 > 192.168.5.23.32933: 7074 ServFail 0/0/0 (25)
15:30:09.307000 IP 192.168.5.23.32933 > 192.168.5.18.53: 7074+ A? ontario. (25)
15:30:09.318846 IP 192.168.5.18.53 > 192.168.5.23.32933: 7074 NXDomain 0/1/0 (100)
15:30:09.328835 IP 192.168.5.23.32933 > 192.168.5.11.53: 37114+ A? ontario. (25)
15:30:09.329216 IP 192.168.5.11.53 > 192.168.5.23.32933: 37114 ServFail 0/0/0 (25)
15:31:10.107025 IP 192.168.5.23.32933 > 192.168.5.11.53: 55886+ A? ontario.adelior.local. (39)
15:31:10.107547 IP 192.168.5.11.53 > 192.168.5.23.32933: 55886* 1/0/0 A[|domain]
Then again, the following does work fine:
bridgetown:/etc # ping
www.adelior.be
PING
www.adelior.be (81.188.22.52) 56(84) bytes of data.
64 bytes from kinshasa.adelior.local (81.188.22.52): icmp_seq=1 ttl=128 time=1.02 ms
64 bytes from kinshasa.adelior.local (81.188.22.52): icmp_seq=2 ttl=128 time=0.851 ms
64 bytes from kinshasa.adelior.local (81.188.22.52): icmp_seq=3 ttl=128 time=0.862 ms
---
www.adelior.be ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2001ms
rtt min/avg/max/mdev = 0.851/0.913/1.027/0.084 ms
bridgetown:/etc # host
www.adelior.be
www.adelior.be has address 81.188.22.52
15:34:35.438282 IP 192.168.5.23.32933 > 192.168.5.11.53: 4554+ A?
www.adelior.be. (32)
15:34:35.438731 IP 192.168.5.11.53 > 192.168.5.23.32933: 4554 1/0/0 A 81.188.22.52 (48)
15:34:35.440513 IP 192.168.5.23.32933 > 192.168.5.11.53: 4555+ PTR? 52.22.188.81.in-addr.arpa. (43)
15:34:35.440931 IP 192.168.5.11.53 > 192.168.5.23.32933: 4555* 2/0/0[|domain]
15:34:56.042134 IP 192.168.5.23.32933 > 192.168.5.11.53: 17529+ A?
www.adelior.be. (32)
15:34:56.042529 IP 192.168.5.11.53 > 192.168.5.23.32933: 17529 1/0/0 A 81.188.22.52 (48)
And when I enter
search adelior.local adelior.be
in the resolv.conf, the following ping does work, but ping to any machine on the local network still not resolves the name.
bridgetown:/etc # ping www
PING
www.adelior.be (81.188.22.52) 56(84) bytes of data.
64 bytes from kinshasa.adelior.local (81.188.22.52): icmp_seq=1 ttl=128 time=1.02 ms
64 bytes from kinshasa.adelior.local (81.188.22.52): icmp_seq=2 ttl=128 time=0.851 ms
64 bytes from kinshasa.adelior.local (81.188.22.52): icmp_seq=3 ttl=128 time=0.862 ms
So it looks like ping (or any other command -- I tried telnet, ftp, etc.) does not even invoke DNS resolution if the fully qualified name (either explicitely specified or inferred from using the search) is on the local domain. How come?
Thanks for your help,
Jantje.