Host/nslookup/dig queries wrong server

Adam Tkac atkac at redhat.com
Thu Feb 4 14:21:49 UTC 2010


On Wed, Feb 03, 2010 at 03:04:45PM -0000, Duncan Berriman wrote:
> Problem is I am specifying the server on the command line, it is supposed to
> use only that server, not randomly decide because it can't connect to that
> server to try any others it feels like.
> 
> Even the -s option makes no difference.
> 
> It should even been looking at files or dns....

Actually only nslookup and host utilities are affected. Both utilities use
specified server but when they don't get response from it they simply
try servers in /etc/resolv.conf. You are right this is not correct
behavior, it will be fixed in future.

You can use "dig" utility for DNS debugging purposes, in my opinion it
is far more better than host/nslookup (and it works fine):

$ dig @123.123.123.123 google.com

; <<>> DiG 9.3.6-P1-RedHat-9.3.6-6.P1.1 <<>> @123.123.123.123
google.com
; (1 server found)
;; global options:  printcmd
;; connection timed out; no servers could be reached

Regards, Adam

-- 
Adam Tkac, Red Hat, Inc.



More information about the bind-users mailing list