1
2
3 
4
5
6
7<html><head><title>nmblookup (1)</title>
8
9<link rev="made" href="mailto:samba@samba.org">
10</head>
11<body>
12
13<hr>
14
15<h1>nmblookup (1)</h1>
16<h2>Samba</h2>
17<h2>23 Oct 1998</h2>
18
19
20    
21<p><a name="NAME"></a>
22<h2>NAME</h2>
23    nmblookup - NetBIOS over TCP/IP client used to lookup NetBIOS names
24<p><a name="SYNOPSIS"></a>
25<h2>SYNOPSIS</h2>
26     
27<p><strong>nmblookup</strong> [<a href="nmblookup.1.html#minusM">-M</a>] [<a href="nmblookup.1.html#minusR">-R</a>] [<a href="nmblookup.1.html#minusS">-S</a>] [<a href="nmblookup.1.html#minusr">-r</a>] [<a href="nmblookup.1.html#minusA">-A</a>] [<a href="nmblookup.1.html#minush">-h</a>] [<a href="nmblookup.1.html#minusB">-B broadcast address</a>] [<a href="nmblookup.1.html#minusU">-U unicast address</a>] [<a href="nmblookup.1.html#minusd">-d debuglevel</a>] [<a href="nmblookup.1.html#minuss">-s smb config file</a>] [<a href="nmblookup.1.html#minusi">-i NetBIOS scope</a>] [<a href="nmblookup.1.html#minusT">-T</a>] <a href="nmblookup.1.html#name">name</a>
28<p><a name="DESCRIPTION"></a>
29<h2>DESCRIPTION</h2>
30    
31<p>This program is part of the <strong>Samba</strong> suite.
32<p><strong>nmblookup</strong> is used to query NetBIOS names and map them to IP
33addresses in a network using NetBIOS over TCP/IP queries. The options
34allow the name queries to be directed at a particular IP broadcast area
35or to a particular machine. All queries are done over UDP.
36<p><a name="OPTIONS"></a>
37<h2>OPTIONS</h2>
38    
39<p><dl>
40<p><a name="minusM"></a>
41<p></p><dt><strong><strong>-M</strong></strong><dd> Searches for a master browser by looking up the 
42NetBIOS name <a href="nmblookup.1.html#name"><strong>name</strong></a> with a type of 0x1d. If <a href="nmblookup.1.html#name"><strong>name</strong></a>
43is <code>"-"</code> then it does a lookup on the special name <code>__MSBROWSE__</code>.
44<p><a name="minusR"></a>
45<p></p><dt><strong><strong>-R</strong></strong><dd> Set the recursion desired bit in the packet to do a
46recursive lookup. This is used when sending a name query to a machine
47running a WINS server and the user wishes to query the names in the
48WINS server.  If this bit is unset the normal (broadcast responding)
49NetBIOS processing code on a machine is used instead. See rfc1001,
50rfc1002 for details.
51<p><a name="minusS"></a>
52<p></p><dt><strong><strong>-S</strong></strong><dd> Once the name query has returned an IP address then do a
53node status query as well. A node status query returns the NetBIOS names 
54registered by a host.
55<p><a name="minusr"></a>
56<p></p><dt><strong><strong>-r</strong></strong><dd> Try and bind to UDP port 137 to send and receive UDP
57datagrams. The reason for this option is a bug in Windows 95 where it
58ignores the source port of the requesting packet and only replies to
59UDP port 137. Unfortunately, on most UNIX systems root privilage is
60needed to bind to this port, and in addition, if the
61<a href="nmbd.8.html"><strong>nmbd</strong></a> daemon is running on this machine it also
62binds to this port.
63<p><a name="minusA"></a>
64<p></p><dt><strong><strong>-A</strong></strong><dd> Interpret &lt;name&gt; as an IP Address and do a node status
65query on this address.
66<p><a name="minush"></a>
67<p></p><dt><strong><strong>-h</strong></strong><dd> Print a help (usage) message.
68<p><a name="minusB"></a>
69<p></p><dt><strong><strong>-B broadcast address</strong></strong><dd> Send the query to the given broadcast
70address. Without this option the default behavior of nmblookup is to
71send the query to the broadcast address of the network
72interfaces as either auto-detected or defined in the 
73<a href="smb.conf.5.html#interfaces"><strong>interfaces</strong></a> parameter of the 
74<a href="smb.conf.5.html"><strong>smb.conf (5)</strong></a> file.
75<p><a name="minusU"></a>
76<p></p><dt><strong><strong>-U unicast address</strong></strong><dd> Do a unicast query to the specified
77address or host <code>"unicast address"</code>. This option (along with the
78<a href="nmblookup.1.html#minusR"><strong>-R</strong></a> option) is needed to query a WINS server.
79<p><a name="minusd"></a>
80<p></p><dt><strong><strong>-d debuglevel</strong></strong><dd> debuglevel is an integer from 0 to 10.
81<p>The default value if this parameter is not specified is zero.
82<p>The higher this value, the more detail will be logged about the
83activities of <strong>nmblookup</strong>. At level 0, only critical errors and
84serious warnings will be logged.
85<p>Levels above 1 will generate considerable amounts of log data, and
86should only be used when investigating a problem. Levels above 3 are
87designed for use only by developers and generate HUGE amounts of
88data, most of which is extremely cryptic.
89<p>Note that specifying this parameter here will override the <a href="smb.conf.5.html#loglevel"><strong>log
90level</strong></a> parameter in the <a href="smb.conf.5.html"><strong>smb.conf
91(5)</strong></a> file.
92<p><a name="minuss"></a>
93<p></p><dt><strong><strong>-s smb.conf</strong></strong><dd> This parameter specifies the pathname to the
94Samba configuration file, <a href="smb.conf.5.html"><strong>smb.conf</strong></a>. 
95This file controls all aspects of
96the Samba setup on the machine.
97<p><a name="minusi"></a>
98<p></p><dt><strong><strong>-i scope</strong></strong><dd> This specifies a NetBIOS scope that <strong>nmblookup</strong> will use
99to communicate with when generating NetBIOS names. For details on the
100use of NetBIOS scopes, see rfc1001.txt and rfc1002.txt. NetBIOS scopes
101are <em>very</em> rarely used, only set this parameter if you are the
102system administrator in charge of all the NetBIOS systems you
103communicate with.
104<p><a name="minusT"></a>
105<p></p><dt><strong><strong>-T</strong></strong><dd> This causes any IP addresses found in the lookup to be
106looked up via a reverse DNS lookup into a DNS name, and printed out
107before each <code>"IP address   NetBIOS name"</code> pair that is the normal
108output.
109<p><a name="name"></a>
110<p></p><dt><strong><strong>name</strong></strong><dd> This is the NetBIOS name being queried. Depending upon
111the previous options this may be a NetBIOS name or IP address. If a
112NetBIOS name then the different name types may be specified by
113appending <code>#&lt;type&gt;</code> to the name. This name may also be <code>"*"</code>,
114which will return all registered names within a broadcast area.
115<p></dl>
116<p><a name="EXAMPLES"></a>
117<h2>EXAMPLES</h2>
118    
119<p><strong>nmblookup</strong> can be used to query a WINS server (in the same way
120<strong>nslookup</strong> is used to query DNS servers). To query a WINS server,
121<strong>nmblookup</strong> must be called like this:
122<p><code>nmblookup -U server -R 'name'</code>
123<p>For example, running :
124<p><code>nmblookup -U samba.org -R IRIX#1B'</code>
125<p>would query the WINS server samba.org for the domain master
126browser (1B name type) for the IRIX workgroup.
127<p><a name="VERSION"></a>
128<h2>VERSION</h2>
129    
130<p>This man page is correct for version 2.0 of the Samba suite.
131<p><a name="SEEALSO"></a>
132<h2>SEE ALSO</h2>
133    
134<p><a href="samba.7.html"><strong>samba (7)</strong></a>, <a href="nmbd.8.html"><strong>nmbd (8)</strong></a>,
135<a href="smb.conf.5.html"><strong>smb.conf (5)</strong></a>
136<p><a name="AUTHOR"></a>
137<h2>AUTHOR</h2>
138    
139<p>The original Samba software and related utilities were created by
140Andrew Tridgell <a href="mailto:samba@samba.org"><em>samba@samba.org</em></a>. Samba is now developed
141by the Samba Team as an Open Source project similar to the way the
142Linux kernel is developed.
143<p>The original Samba man pages were written by Karl Auer. The man page
144sources were converted to YODL format (another excellent piece of Open
145Source software, available at
146<a href="ftp://ftp.icce.rug.nl/pub/unix/"><strong>ftp://ftp.icce.rug.nl/pub/unix/</strong></a>)
147and updated for the Samba2.0 release by Jeremy Allison.
148<a href="mailto:samba@samba.org"><em>samba@samba.org</em></a>.
149<p>See <a href="samba.7.html"><strong>samba (7)</strong></a> to find out how to get a full
150list of contributors and details on how to submit bug reports,
151comments etc.
152<p></body>
153</html>
154