This commit was manufactured by cvs2svn to create branch 'SAMBA_3_0'.(This used to...
[samba.git] / docs / docbook / manpages / nmblookup.1.sgml
1 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
2 <refentry id="nmblookup">
3
4 <refmeta>
5         <refentrytitle>nmblookup</refentrytitle>
6         <manvolnum>1</manvolnum>
7 </refmeta>
8
9
10 <refnamediv>
11         <refname>nmblookup</refname>
12         <refpurpose>NetBIOS over TCP/IP client used to lookup NetBIOS 
13         names</refpurpose>
14 </refnamediv>
15
16 <refsynopsisdiv>
17         <cmdsynopsis>
18                 <command>nmblookup</command>
19                 <arg choice="opt">-M</arg>
20                 <arg choice="opt">-R</arg>
21                 <arg choice="opt">-S</arg>
22                 <arg choice="opt">-r</arg>
23                 <arg choice="opt">-A</arg>
24                 <arg choice="opt">-h</arg>
25                 <arg choice="opt">-B &lt;broadcast address&gt;</arg>
26                 <arg choice="opt">-U &lt;unicast address&gt;</arg>
27                 <arg choice="opt">-d &lt;debug level&gt;</arg>
28                 <arg choice="opt">-s &lt;smb config file&gt;</arg>
29                 <arg choice="opt">-i &lt;NetBIOS scope&gt;</arg>
30                 <arg choice="opt">-T</arg>
31                 <arg choice="opt">-f</arg>
32                 <arg choice="req">name</arg>
33         </cmdsynopsis>
34 </refsynopsisdiv>
35
36 <refsect1>
37         <title>DESCRIPTION</title>
38
39         <para>This tool is part of the <ulink url="samba.7.html">
40         Samba</ulink> suite.</para>
41
42         <para><command>nmblookup</command> is used to query NetBIOS names 
43         and map them to IP addresses in a network using NetBIOS over TCP/IP 
44         queries. The options allow the name queries to be directed at a 
45         particular IP broadcast area or to a particular machine. All queries 
46         are done over UDP.</para>
47 </refsect1>
48
49 <refsect1>
50         <title>OPTIONS</title>
51
52         <variablelist>
53                 <varlistentry>
54                 <term>-M</term>
55                 <listitem><para>Searches for a master browser by looking 
56                 up the  NetBIOS name <replaceable>name</replaceable> with a 
57                 type of <constant>0x1d</constant>. If <replaceable>
58                 name</replaceable> is "-" then it does a lookup on the special name 
59                 <constant>__MSBROWSE__</constant>.</para></listitem>
60                 </varlistentry>
61                 
62                 <varlistentry>
63                 <term>-R</term>
64                 <listitem><para>Set the recursion desired bit in the packet 
65                 to do a recursive lookup. This is used when sending a name 
66                 query to a machine running a WINS server and the user wishes 
67                 to query the names in the WINS server.  If this bit is unset 
68                 the normal (broadcast responding) NetBIOS processing code 
69                 on a machine is used instead. See rfc1001, rfc1002 for details.
70                 </para></listitem>
71                 </varlistentry>
72                 
73                 <varlistentry>
74                 <term>-S</term>
75                 <listitem><para>Once the name query has returned an IP 
76                 address then do a node status query as well. A node status 
77                 query returns the NetBIOS names registered by a host.
78                 </para></listitem>
79                 </varlistentry>
80
81
82                 <varlistentry>
83                 <term>-r</term> 
84                 <listitem><para>Try and bind to UDP port 137 to send and receive UDP
85                 datagrams. The reason for this option is a bug in Windows 95 
86                 where it ignores the source port of the requesting packet 
87                 and only replies to UDP port 137. Unfortunately, on most UNIX 
88                 systems root privilege is needed to bind to this port, and 
89                 in addition, if the <ulink url="nmbd.8.html">nmbd(8)</ulink> 
90                 daemon is running on this machine it also binds to this port.
91                 </para></listitem>
92                 </varlistentry>
93
94
95                 <varlistentry>
96                 <term>-A</term>
97                 <listitem><para>Interpret <replaceable>name</replaceable> as 
98                 an IP Address and do a node status query on this address.</para>
99                 </listitem>
100                 </varlistentry>
101
102
103
104                 <varlistentry>
105                 <term>-h</term> 
106                 <listitem><para>Print a help (usage) message.</para></listitem>
107                 </varlistentry>
108
109
110
111                 <varlistentry>
112                 <term>-B &lt;broadcast address&gt;</term> 
113                 <listitem><para>Send the query to the given broadcast address. Without 
114                 this option the default behavior of nmblookup is to send the 
115                 query to the broadcast address of the network interfaces as 
116                 either auto-detected or defined in the <ulink 
117                 url="smb.conf.5.html#INTERFACES"><parameter>interfaces</parameter>
118                 </ulink> parameter of the  <filename>smb.conf (5)</filename> file.
119                 </para></listitem>
120                 </varlistentry>
121
122
123
124                 <varlistentry>
125                 <term>-U &lt;unicast address&gt;</term>
126                 <listitem><para>Do a unicast query to the specified address or 
127                 host <replaceable>unicast address</replaceable>. This option 
128                 (along with the <parameter>-R</parameter> option) is needed to 
129                 query a WINS server.</para></listitem>
130                 </varlistentry>
131                 
132                 
133                 <varlistentry>
134                 <term>-d &lt;debuglevel&gt;</term> 
135                 <listitem><para>debuglevel is an integer from 0 to 10.</para>
136
137                 <para>The default value if this parameter is not specified 
138                 is zero.</para>
139
140                 <para>The higher this value, the more detail will be logged 
141                 about the activities of <command>nmblookup</command>. At level 
142                 0, only critical errors and serious warnings will be logged.</para>
143
144                 <para>Levels above 1 will generate considerable amounts of 
145                 log data, and should only be used when investigating a problem. 
146                 Levels above 3 are designed for use only by developers and 
147                 generate HUGE amounts of data, most of which is extremely cryptic.</para>
148
149                 <para>Note that specifying this parameter here will override 
150                 the <ulink url="smb.conf.5.html#LOGLEVEL"><parameter>
151                 log level</parameter></ulink> parameter in the <filename>
152                 smb.conf(5)</filename> file.</para></listitem>
153                 </varlistentry>
154
155                 <varlistentry>
156                 <term>-s &lt;smb.conf&gt;</term> 
157                 <listitem><para>This parameter specifies the pathname to 
158                 the Samba configuration file, <ulink url="smb.conf.5.html">
159                 smb.conf(5)</ulink>.  This file controls all aspects of
160                 the Samba setup on the machine.</para></listitem>
161                 </varlistentry>
162
163                 <varlistentry>
164                 <term>-i &lt;scope&gt;</term> 
165                 <listitem><para>This specifies a NetBIOS scope that
166                 <command>nmblookup</command> will use to communicate with when 
167                 generating NetBIOS names. For details on the use of NetBIOS 
168                 scopes, see rfc1001.txt and rfc1002.txt. NetBIOS scopes are 
169                 <emphasis>very</emphasis> rarely used, only set this parameter 
170                 if you are the system administrator in charge of all the 
171                 NetBIOS systems you communicate with.</para></listitem>
172                 </varlistentry>
173                 
174                 
175                 <varlistentry>
176                 <term>-T</term> 
177                 <listitem><para>This causes any IP addresses found in the 
178                 lookup to be looked up via a reverse DNS lookup into a 
179                 DNS name, and printed out before each</para>
180                 
181                 <para><emphasis>IP address .... NetBIOS name</emphasis></para>
182                 
183                 <para> pair that is the normal output.</para></listitem>
184                 </varlistentry>
185
186                 <varlistentry>
187                 <term>-f</term>
188                 <listitem><para>
189                 Show which flags apply to the name that has been looked up. Possible 
190                 answers are zero or more of: Response, Authoritative, 
191                 Truncated, Recursion_Desired, Recursion_Available, Broadcast.
192                 </para></listitem>
193                 </varlistentry>
194
195
196                 <varlistentry>
197                 <term>name</term>
198                 <listitem><para>This is the NetBIOS name being queried. Depending 
199                 upon the previous options this may be a NetBIOS name or IP address. 
200                 If a NetBIOS name then the different name types may be specified 
201                 by appending '#&lt;type&gt' to the name. This name may also be
202                 '*', which will return all registered names within a broadcast 
203                 area.</para></listitem>
204                 </varlistentry>
205         </variablelist>
206 </refsect1>
207
208
209 <refsect1>
210         <title>EXAMPLES</title>
211
212                 <para><command>nmblookup</command> can be used to query 
213                 a WINS server (in the same way <command>nslookup</command> is 
214                 used to query DNS servers). To query a WINS server, 
215                 <command>nmblookup</command> must be called like this:</para>
216
217                 <para><command>nmblookup -U server -R 'name'</command></para>
218
219                 <para>For example, running :</para>
220
221                 <para><command>nmblookup -U samba.org -R 'IRIX#1B'</command></para>
222
223                 <para>would query the WINS server samba.org for the domain 
224                 master browser (1B name type) for the IRIX workgroup.</para>
225 </refsect1>
226
227 <refsect1>
228         <title>VERSION</title>
229
230         <para>This man page is correct for version 3.0 of 
231         the Samba suite.</para>
232 </refsect1>
233
234 <refsect1>
235         <title>SEE ALSO</title>
236         <para><ulink url="nmbd.8.html"><command>nmbd(8)</command></ulink>, 
237         <ulink url="samba.7.html">samba(7)</ulink>, and <ulink 
238         url="smb.conf.5.html">smb.conf(5)</ulink>
239         </para>
240 </refsect1>
241
242 <refsect1>
243         <title>AUTHOR</title>
244         
245         <para>The original Samba software and related utilities 
246         were created by Andrew Tridgell. Samba is now developed
247         by the Samba Team as an Open Source project similar 
248         to the way the Linux kernel is developed.</para>
249         
250         <para>The original Samba man pages were written by Karl Auer. 
251         The man page sources were converted to YODL format (another 
252         excellent piece of Open Source software, available at
253         <ulink url="ftp://ftp.icce.rug.nl/pub/unix/">
254         ftp://ftp.icce.rug.nl/pub/unix/</ulink>) and updated for the Samba 2.0 
255         release by Jeremy Allison.  The conversion to DocBook for 
256         Samba 2.2 was done by Gerald Carter</para>
257 </refsect1>
258
259 </refentry>