nslookup.html revision 60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2
0N/A<!--
1008N/A - Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
1008N/A -
1008N/A - Permission to use, copy, modify, and distribute this software for any
1008N/A - purpose with or without fee is hereby granted, provided that the above
1008N/A - copyright notice and this permission notice appear in all copies.
1008N/A -
1008N/A - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
1008N/A - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
1008N/A - AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
1008N/A - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
1008N/A - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
1008N/A - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
1008N/A - PERFORMANCE OF THIS SOFTWARE.
1008N/A-->
1008N/A<html>
1008N/A<head>
1008N/A<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
1008N/A<title>nslookup</title>
1008N/A<meta name="generator" content="DocBook XSL Stylesheets V1.68.1">
1008N/A</head>
1008N/A<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
1008N/A<a name="id2456619"></a><div class="titlepage"></div>
1008N/A<div class="refnamediv">
1008N/A<h2>Name</h2>
1008N/A<p>nslookup &#8212; query Internet name servers interactively</p>
1008N/A</div>
0N/A<div class="refsynopsisdiv">
0N/A<h2>Synopsis</h2>
0N/A<div class="cmdsynopsis"><p><code class="command">nslookup</code> [<code class="option">-option</code>] [name | -] [server]</p></div>
0N/A</div>
1008N/A<div class="refsect1" lang="en">
1008N/A<a name="id2514032"></a><h2>DESCRIPTION</h2>
1008N/A<p><span><strong class="command">Nslookup</strong></span>
1008N/A is a program to query Internet domain name servers. <span><strong class="command">Nslookup</strong></span>
1008N/A has two modes: interactive and non-interactive. Interactive mode allows
1008N/A the user to query name servers for information about various hosts and
1008N/A domains or to print a list of hosts in a domain. Non-interactive mode
1008N/A is
0N/A used to print just the name and requested information for a host or
0N/A domain.
0N/A </p>
0N/A</div>
0N/A<div class="refsect1" lang="en">
0N/A<a name="id2514048"></a><h2>ARGUMENTS</h2>
0N/A<p>
0N/A Interactive mode is entered in the following cases:
0N/A </p>
0N/A<div class="orderedlist"><ol type="a">
0N/A<li><p>
0N/A when no arguments are given (the default name server will be used)
0N/A </p></li>
0N/A<li><p>
1008N/A when the first argument is a hyphen (-) and the second argument is
1008N/A the host name or Internet address of a name server.
1008N/A </p></li>
0N/A</ol></div>
1008N/A<p>
1008N/A </p>
1008N/A<p>
1008N/A Non-interactive mode is used when the name or Internet address of the
1008N/A host to be looked up is given as the first argument. The optional second
1008N/A argument specifies the host name or address of a name server.
1008N/A </p>
1008N/A<p>
1008N/A Options can also be specified on the command line if they precede the
1008N/A arguments and are prefixed with a hyphen. For example, to
1008N/A change the default query type to host information, and the initial
1008N/A timeout to 10 seconds, type:
1008N/A </p>
1008N/A<div class="informalexample"><pre class="programlisting">
1008N/Anslookup -query=hinfo -timeout=10
0N/A</pre></div>
1008N/A<p>
1008N/A </p>
0N/A</div>
1008N/A<div class="refsect1" lang="en">
0N/A<a name="id2514089"></a><h2>INTERACTIVE COMMANDS</h2>
0N/A<div class="variablelist"><dl>
1008N/A<dt><span class="term">host [<span class="optional">server</span>]</span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A Look up information for host using the current default server or
1008N/A using server, if specified. If host is an Internet address and
1008N/A the query type is A or PTR, the name of the host is returned.
1008N/A If host is a name and does not have a trailing period, the
0N/A search list is used to qualify the name.
0N/A </p>
1008N/A<p>
1008N/A To look up a host not in the current domain, append a period to
1008N/A the name.
1008N/A </p>
1008N/A</dd>
1008N/A<dt><span class="term"><code class="constant">server</code> <em class="replaceable"><code>domain</code></em></span></dt>
1008N/A<dd><p></p></dd>
0N/A<dt><span class="term"><code class="constant">lserver</code> <em class="replaceable"><code>domain</code></em></span></dt>
0N/A<dd><p>
0N/A Change the default server to <em class="replaceable"><code>domain</code></em>; <code class="constant">lserver</code> uses the initial
1008N/A server to look up information about <em class="replaceable"><code>domain</code></em>, while <code class="constant">server</code> uses
1008N/A the current default server. If an authoritative answer can't be
1008N/A found, the names of servers that might have the answer are
1008N/A returned.
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">root</code></span></dt>
1008N/A<dd><p>
1008N/A not implemented
0N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">finger</code></span></dt>
1008N/A<dd><p>
1008N/A not implemented
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">ls</code></span></dt>
1008N/A<dd><p>
1008N/A not implemented
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">view</code></span></dt>
1008N/A<dd><p>
1008N/A not implemented
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">help</code></span></dt>
1008N/A<dd><p>
1008N/A not implemented
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">?</code></span></dt>
1008N/A<dd><p>
0N/A not implemented
0N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">exit</code></span></dt>
1008N/A<dd><p>
1008N/A Exits the program.
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">set</code>
0N/A <em class="replaceable"><code>keyword[<span class="optional">=value</span>]</code></em></span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A This command is used to change state information that affects
1008N/A the lookups. Valid keywords are:
1008N/A </p>
0N/A<div class="variablelist"><dl>
1008N/A<dt><span class="term"><code class="constant">all</code></span></dt>
1008N/A<dd><p>
1008N/A Prints the current values of the frequently used
1008N/A options to <span><strong class="command">set</strong></span>.
1008N/A Information about the current default
1008N/A server and host is also printed.
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">class=</code><em class="replaceable"><code>value</code></em></span></dt>
0N/A<dd>
1008N/A<p>
1008N/A Change the query class to one of:
1008N/A </p>
0N/A<div class="variablelist"><dl>
1008N/A<dt><span class="term"><code class="constant">IN</code></span></dt>
1008N/A<dd><p>
1008N/A the Internet class
1008N/A </p></dd>
0N/A<dt><span class="term"><code class="constant">CH</code></span></dt>
0N/A<dd><p>
0N/A the Chaos class
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">HS</code></span></dt>
1008N/A<dd><p>
1008N/A the Hesiod class
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">ANY</code></span></dt>
1008N/A<dd><p>
1008N/A wildcard
1008N/A </p></dd>
1008N/A</dl></div>
1008N/A<p>
1008N/A The class specifies the protocol group of the information.
1008N/A
1008N/A </p>
1008N/A<p>
1008N/A (Default = IN; abbreviation = cl)
1008N/A </p>
1008N/A</dd>
1008N/A<dt><span class="term"><code class="constant">
1008N/A <em class="replaceable"><code>[<span class="optional">no</span>]</code></em>debug</code></span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A Turn debugging mode on. A lot more information is
1008N/A printed about the packet sent to the server and the
1008N/A resulting answer.
1008N/A </p>
1008N/A<p>
1008N/A (Default = nodebug; abbreviation = [<span class="optional">no</span>]deb)
1008N/A </p>
1008N/A</dd>
1008N/A<dt><span class="term"><code class="constant">
1008N/A <em class="replaceable"><code>[<span class="optional">no</span>]</code></em>d2</code></span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A Turn debugging mode on. A lot more information is
1008N/A printed about the packet sent to the server and the
1008N/A resulting answer.
1008N/A </p>
1008N/A<p>
1008N/A (Default = nod2)
1008N/A </p>
1008N/A</dd>
1008N/A<dt><span class="term"><code class="constant">domain=</code><em class="replaceable"><code>name</code></em></span></dt>
1008N/A<dd><p>
1008N/A Sets the search list to <em class="replaceable"><code>name</code></em>.
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">
1008N/A <em class="replaceable"><code>[<span class="optional">no</span>]</code></em>search</code></span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A If the lookup request contains at least one period but
1008N/A doesn't end with a trailing period, append the domain
1008N/A names in the domain search list to the request until an
1008N/A answer is received.
1008N/A </p>
1008N/A<p>
1008N/A (Default = search)
1008N/A </p>
1008N/A</dd>
1008N/A<dt><span class="term"><code class="constant">port=</code><em class="replaceable"><code>value</code></em></span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A Change the default TCP/UDP name server port to <em class="replaceable"><code>value</code></em>.
1008N/A </p>
1008N/A<p>
1008N/A (Default = 53; abbreviation = po)
1008N/A </p>
1008N/A</dd>
1008N/A<dt><span class="term"><code class="constant">querytype=</code><em class="replaceable"><code>value</code></em></span></dt>
1008N/A<dd><p></p></dd>
1008N/A<dt><span class="term"><code class="constant">type=</code><em class="replaceable"><code>value</code></em></span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A Change the top of the information query.
1008N/A </p>
1008N/A<p>
1008N/A (Default = A; abbreviations = q, ty)
1008N/A </p>
1008N/A</dd>
1008N/A<dt><span class="term"><code class="constant">
1008N/A <em class="replaceable"><code>[<span class="optional">no</span>]</code></em>recurse</code></span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A Tell the name server to query other servers if it does not
1008N/A have the
1008N/A information.
1008N/A </p>
1008N/A<p>
1008N/A (Default = recurse; abbreviation = [no]rec)
1008N/A </p>
1008N/A</dd>
1008N/A<dt><span class="term"><code class="constant">retry=</code><em class="replaceable"><code>number</code></em></span></dt>
1008N/A<dd><p>
1008N/A Set the number of retries to number.
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">timeout=</code><em class="replaceable"><code>number</code></em></span></dt>
1008N/A<dd><p>
1008N/A Change the initial timeout interval for waiting for a
1008N/A reply to number seconds.
1008N/A </p></dd>
1008N/A<dt><span class="term"><code class="constant">
1008N/A <em class="replaceable"><code>[<span class="optional">no</span>]</code></em>vc</code></span></dt>
1008N/A<dd>
1008N/A<p>
1008N/A Always use a virtual circuit when sending requests to the
1008N/A server.
1008N/A </p>
1008N/A<p>
1008N/A (Default = novc)
1008N/A </p>
1008N/A</dd>
1008N/A</dl></div>
1008N/A<p>
1008N/A </p>
1008N/A</dd>
1008N/A</dl></div>
1008N/A</div>
1008N/A<div class="refsect1" lang="en">
1008N/A<a name="id2516999"></a><h2>FILES</h2>
1008N/A<p><code class="filename">/etc/resolv.conf</code>
1008N/A </p>
1008N/A</div>
1008N/A<div class="refsect1" lang="en">
1008N/A<a name="id2517011"></a><h2>SEE ALSO</h2>
1008N/A<p><span class="citerefentry"><span class="refentrytitle">dig</span>(1)</span>,
1008N/A <span class="citerefentry"><span class="refentrytitle">host</span>(1)</span>,
1008N/A <span class="citerefentry"><span class="refentrytitle">named</span>(8)</span>.
1008N/A </p>
1008N/A</div>
1008N/A<div class="refsect1" lang="en">
1008N/A<a name="id2517045"></a><h2>Author</h2>
1008N/A<p>
1008N/A Andrew Cherenson
1008N/A </p>
1008N/A</div>
1008N/A</div></body>
1008N/A</html>
1008N/A