Non-interactive mode is used when the name or Internet address of the host to be looked up is given as the first argument. The optional second argument specifies the host name or address of a name server.
The options listed under the
``set
''
command below can be specified in
the
.nslookuprc
file in the user's home directory if they are listed
one per line.
Options can also be specified on the command line if they precede
the arguments and are prefixed with a hyphen.
For example, to change the default query type to host information,
and the initial timeout to 10 seconds, type:
nslookup -query=hinfo -timeout=10
EOF
)
or type
exit
.
The command line length must be less than 256 characters.
To treat a built-in command as a host name,
precede it with an escape character
(`\').
N.B.: unrecognized command will be interpreted as a host name.
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.
ns.internic.net
is used.
(This command is a synonym for
``lserver ns.internic.net''.)
The name of the root server can be changed with the
``set root''
command.
A
''
command).
The
name
is optional.
>
and
>>
can be used to redirect output in the usual manner.
CNAME
''.
ANY
''.
HINFO
''.
WKS
''.
When output is directed to a file, hash marks are printed for every 50 records received from the server.
IN
CHAOS
HESIOD
ANY
The class specifies the protocol group of the information.
(Default =
IN
;
abbreviation =
cl)
(Default = nodebug; abbreviation = no[.blm Ppdeb)]
(Default = nod2)
(Default = value from
hostname(1),
/etc/resolv.conf
,
or
LOCALDOMAIN
;
abbreviation =
do)
set srchlist=lcs.MIT.EDU/ai.MIT.EDU/MIT.EDU
sets the domain to lcs.MIT.EDU and the search list to the three names. This command overrides the default domain name and search list of the ``set domain'' command. Use the ``set all'' command to display the list.
(Default = value based on
hostname(1),
/etc/resolv.conf
,
or
LOCALDOMAIN
;
abbreviation =
srchl)
(Default = defname; abbreviation = no[.blm Ppdefname)]
(Default = search; abbreviation = no[.blm Ppsea)]
(Default = 53; abbreviation = po)
A
CNAME
HINFO
MINFO
MX
NS
PTR
SOA
TXT
UINFO
WKS
Other types
(
ANY
, AXFR
, MB
,
MD
, MF
, NULL
)
are described in the RFC-1035 document.
(Default =
A
;
abbreviations =
q, ty)
(Default = recurse; abbreviation = no[.blm Pprec)]
(Default = 4, abbreviation = ret)
(Default = ns.internic.net.; abbreviation = ro)
(Default = 5 seconds; abbreviation = ti)
(Default = novc; abbreviation = no[.blm Ppv)]
(Default = noignoretc; abbreviation = no[.blm Ppig)]
HOSTALIASES
LOCALDOMAIN
/etc/resolv.conf
$HOME/.nslookuprc
/usr/share/misc/nslookup.help
Timed
out
No
response
from
server
No
records
Non-existent
domain
Connection
refused
Network
is
unreachable
Server
failure
Refused
Format
error