DNSQRY
[/?]
[/LARGEUDP[+|-]]
[/RECURSIVE[+|-]]
[/TCP[+|-]]
[/UDP[+|-]]
[/SERVERIP address]
[/SERVER name]
[/SERVICE name]
[/WELLKNOWNPORT port]
[/CLIENTIP address]
[/CLIENTPORT port]
[/IP6[+|-]]
type
name
The DNSQRY command is a thin command-line wrapper around a lightweight DNS client. It sends a query to the given server and waits for responses. It prints both the query and the response(s) in a compact, yet human-readable, form.
DNSQRY passes the name argument through the standard name qualification procedure.
DNSQRY has the same timeout algorithm as other DNS clients in the Internet Utilities.
DNSQRY is a superior alternative to NSLOOKUP (the query tool provided with BIND and hence supplied with IBM OS/2).
Its output format is more compact than that of NSLOOKUP.
It does not contain subtle quirks that make it different to ordinary clients.
NSLOOKUP contains its own DNS client code, entirely separate from the DNS
client code used by applications, and which operates slightly differently.
(For example, it uses %ETC%\RESOLV2 only, whereas the DNS
client used by applications actually uses both %ETC%\RESOLV
and %ETC%\RESOLV2, in that order.)
DNSQRY, in comparison, uses the same DNS client code as the DNS client library DLL does.
It does not have the problems that NSLOOKUP has that are caused by its trying to be clever.
NSLOOKUP cannot be used to query non-recursive servers (such as the root DNS servers), because it "helpfully" tries to look up the name of the server before doing anything else, and exits with an error, without even trying the query that it was actually asked to try, if that initial lookup fails. DNSQRY only queries exactly what it is asked to query — no more, and no less.
/RECURSIVE/TCP/UDP