Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

dig hostname.domain works, dig hostname doesn't

1 view
Skip to first unread message

Hoff

unread,
Nov 26, 2002, 3:02:07 PM11/26/02
to

Hello,

I don't understand why I can use 'dig dad.homenet' to properly resolve
the address but not 'dig dad'. It appears that when the domain is not
specified, the local domain is not searched at all. But, 'host dad'
and 'ping dad' work just fine.
RH7.3, BIND 9.2.0

1102 $ host dad
dad.homenet has address 192.168.1.249
1103 $ dig dad

; <<>> DiG 9.2.0 <<>> dad
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 62119
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0

;; QUESTION SECTION:
;dad. IN A

;; AUTHORITY SECTION:
. 4812 IN SOA A.ROOT-SERVERS.NET.
NSTLD.VERISIGN-GRS.COM. 2002112600 1800 900 604800 86400

;; Query time: 18 msec
;; SERVER: 127.0.0.1#53(localhost)
;; WHEN: Tue Nov 26 12:11:41 2002
;; MSG SIZE rcvd: 96

1104 $ dig dad.homenet

; <<>> DiG 9.2.0 <<>> dad.homenet
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 17684
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 1, ADDITIONAL:
1

;; QUESTION SECTION:
;dad.homenet. IN A

;; ANSWER SECTION:
dad.homenet. 259200 IN A 192.168.1.249

;; AUTHORITY SECTION:
homenet. 259200 IN NS linux2.homenet.

;; ADDITIONAL SECTION:
linux2.homenet. 259200 IN A 192.168.1.200

;; Query time: 13 msec
;; SERVER: 127.0.0.1#53(localhost)
;; WHEN: Tue Nov 26 12:12:10 2002
;; MSG SIZE rcvd: 82

1105 $ ping dad
PING dad.homenet (192.168.1.249) from 192.168.1.200 : 56(84) bytes of
data.
64 bytes from dad.homenet (192.168.1.249): icmp_seq=1 ttl=128
time=0.460 ms

1106 $ cat /etc/resolv.conf
search homenet homenet2
nameserver localhost
1107 $

Mark Damrose

unread,
Nov 26, 2002, 3:35:37 PM11/26/02
to

"Hoff" <goo...@danarily.com> wrote in message
news:as0jvv$594t$1...@isrv4.isc.org...

>
> Hello,
>
> I don't understand why I can use 'dig dad.homenet' to properly resolve
> the address but not 'dig dad'. It appears that when the domain is not
> specified, the local domain is not searched at all. But, 'host dad'
> and 'ping dad' work just fine.
> RH7.3, BIND 9.2.0

$ man dig

+[no]search
Use [do not use] the search list defined by the
searchlist or domain directive in resolv.conf (if
any). The search list is not used by default.


Yang xiao

unread,
Nov 26, 2002, 8:51:42 PM11/26/02
to

goo...@danarily.com (Hoff) wrote in message news:<as0jvv$594t$1...@isrv4.isc.org>...


You are supposed to use FQDN, dig doesn't query your /etc/resolve.conf
for domain suffix.

YANG

0 new messages