Query Internet name servers
nslookup [-options] [host-to-find ]
host [server ] Look up information for host using the current default server or using server,
if specified. If host is an Internet address and the query type is A or PTR ,
the name of the host is returned. If host is a name and does not have a trailing
period, the default domain name is appended to the name. (This behavior depends
on the state of the set options domain , srchlist , defname , and search.
To look up a host not in the current domain, append a period to the name.
Change the default server to domain ; lserver uses the initial server to look up
information about domain while server uses the current default server.
If an authoritative answer can&qt;&qt;t be found, the names of servers that might have
the answer are returned.
Change the default server to the server for the root of the domain name space.
Currently, the host ns.internic.net is used. (This command is a synonym for
&qt;lserver ns.internic.net&qt;&qt; The name of the root server can be changed with
the &qt;set root &qt;&qt; command.
finger [name ] [> filename ]
finger [name ] [>> filename ] Connects with the finger server on the current host. The current host is
defined when a previous lookup for a host was successful and returned address
information (see the &qt;set querytype=A &qt;&qt; command). The name is optional. > and
>> can be used to redirect output in the usual manner.
ls [option ] domain [> filename ] ls [option ] domain [>> filename ] List the information available for domain , optionally creating or appending
to filename The default output contains host names and their Internet addresses.
Option can be one of the following:
-t querytype list all records of the specified type (see querytype below).
-a list aliases of hosts in the domain; synonym for &qt;-t CNAME &qt;&qt;
-d list all records for the domain; synonym for &qt;-t ANY&qt;&qt;
-h list CPU and operating system information for the domain; synonym for &qt;-t HINFO&qt;&qt;
-s list well-known services of hosts in the domain; synonym for &qt;-t WKS&qt;&qt;
When output is directed to a file, hash marks are printed for every 50 records
received from the server.
Sort and lists the output of previous ls command(s) with more(1).
set keyword [= value ] This command is used to change state information that affects the lookups.
run man nslookup for a full list of valid keywords.
set all Print the current value of the frequently-used options
to set Information about the current default server and host is also printed.
? Print a brief summary of commands.
exit Exit the program.
Nslookup has two modes: interactive and non-interactive.
Interactive mode allows the user to query name servers for information about various hosts and domains or to print a list of hosts in a domain.
Non-interactive mode is used to print just the name and requested information for a host or domain.
The options listed under the &qt;set &qt;&qt; command can be specified in the .nslookuprc file in the user&qt;&qt;s home directory (listed one per line). Options can also be specified on the command line if they precede the arguments and are prefixed with a hyphen.