7aabfa60b22ea12b7498d27fa93463cef0471a32
[sfrench/samba-autobuild/.git] / docs-xml / manpages / nmbd.8.xml
1 <?xml version="1.0" encoding="iso-8859-1"?>
2 <!DOCTYPE refentry PUBLIC "-//Samba-Team//DTD DocBook V4.2-Based Variant V1.0//EN" "http://www.samba.org/samba/DTD/samba-doc">
3 <refentry id="nmbd.8">
4
5 <refmeta>
6         <refentrytitle>nmbd</refentrytitle>
7         <manvolnum>8</manvolnum>
8         <refmiscinfo class="source">Samba</refmiscinfo>
9         <refmiscinfo class="manual">System Administration tools</refmiscinfo>
10         <refmiscinfo class="version">4.1</refmiscinfo>
11 </refmeta>
12
13
14 <refnamediv>
15         <refname>nmbd</refname>
16         <refpurpose>NetBIOS name server to provide NetBIOS 
17         over IP naming services to clients</refpurpose>
18 </refnamediv>
19
20 <refsynopsisdiv>
21         <cmdsynopsis>
22                 <command>nmbd</command>
23                 <arg choice="opt">-D</arg>
24                 <arg choice="opt">-F</arg>
25                 <arg choice="opt">-S</arg>
26                 <arg choice="opt">-i</arg>
27                 <arg choice="opt">-V</arg>
28                 <arg choice="opt">-d &lt;debug level&gt;</arg>
29                 <arg choice="opt">-H &lt;lmhosts file&gt;</arg>
30                 <arg choice="opt">-l &lt;log directory&gt;</arg>
31                 <arg choice="opt">-p &lt;port number&gt;</arg>
32                 <arg choice="opt">-s &lt;configuration file&gt;</arg>
33         </cmdsynopsis>
34 </refsynopsisdiv>
35
36 <refsect1>
37         <title>DESCRIPTION</title>
38         <para>This program is part of the <citerefentry><refentrytitle>samba</refentrytitle>
39         <manvolnum>7</manvolnum></citerefentry> suite.</para>
40
41         <para><command>nmbd</command> is a server that understands 
42         and can reply to NetBIOS over IP name service requests, like 
43         those produced by SMB/CIFS clients such as Windows 95/98/ME, 
44         Windows NT, Windows 2000, Windows XP and LanManager clients. It also
45         participates in the browsing protocols which make up the 
46         Windows "Network Neighborhood" view.</para>
47
48         <para>SMB/CIFS clients, when they start up, may wish to 
49         locate an SMB/CIFS server. That is, they wish to know what 
50         IP number a specified host is using.</para>
51
52         <para>Amongst other services, <command>nmbd</command> will 
53         listen for such requests, and if its own NetBIOS name is 
54         specified it will respond with the IP number of the host it 
55         is running on.  Its "own NetBIOS name" is by
56         default the primary DNS name of the host it is running on, 
57         but this can be overridden by the <smbconfoption name="netbios name"/>
58         in &smb.conf;. Thus <command>nmbd</command> will 
59         reply to broadcast queries for its own name(s). Additional
60         names for <command>nmbd</command> to respond on can be set 
61         via parameters in the <citerefentry><refentrytitle>smb.conf</refentrytitle>
62         <manvolnum>5</manvolnum></citerefentry> configuration file.</para>
63
64         <para><command>nmbd</command> can also be used as a WINS 
65         (Windows Internet Name Server) server. What this basically means 
66         is that it will act as a WINS database server, creating a 
67         database from name registration requests that it receives and 
68         replying to queries from clients for these names.</para>
69
70         <para>In addition, <command>nmbd</command> can act as a WINS 
71         proxy, relaying broadcast queries from clients that do 
72         not understand how to talk the WINS protocol to a WINS 
73         server.</para>
74 </refsect1>
75
76 <refsect1>
77         <title>OPTIONS</title>
78
79         <variablelist>
80                 <varlistentry>
81                 <term>-D</term>
82                 <listitem><para>If specified, this parameter causes 
83                 <command>nmbd</command> to operate as a daemon. That is, 
84                 it detaches itself and runs in the background, fielding 
85                 requests on the appropriate port. By default, <command>nmbd</command> 
86                 will operate as a daemon if launched from a command shell. 
87                 nmbd can also be operated from the <command>inetd</command> 
88                 meta-daemon, although this is not recommended.
89                 </para></listitem>
90                 </varlistentry>
91
92                 <varlistentry>
93                 <term>-F</term>
94                 <listitem><para>If specified, this parameter causes
95                 the main <command>nmbd</command> process to not daemonize,
96                 i.e. double-fork and disassociate with the terminal.
97                 Child processes are still created as normal to service
98                 each connection request, but the main process does not
99                 exit. This operation mode is suitable for running
100                 <command>nmbd</command> under process supervisors such
101                 as <command>supervise</command> and <command>svscan</command>
102                 from Daniel J. Bernstein's <command>daemontools</command>
103                 package, or the AIX process monitor.
104                 </para></listitem>
105                 </varlistentry>
106
107                 <varlistentry>
108                 <term>-S</term>
109                 <listitem><para>If specified, this parameter causes
110                 <command>nmbd</command> to log to standard output rather
111                 than a file.</para></listitem>
112                 </varlistentry>
113
114                 <varlistentry>
115                 <term>-i</term>
116                 <listitem><para>If this parameter is specified it causes the
117                 server to run "interactively", not as a daemon, even if the
118                 server is executed on the command line of a shell. Setting this
119                 parameter negates the implicit daemon mode when run from the
120                 command line. <command>nmbd</command> also logs to standard
121                 output, as if the <constant>-S</constant> parameter had been
122                 given. </para></listitem>
123                 </varlistentry>
124
125                 &stdarg.help;
126                 
127                 <varlistentry>
128                 <term>-H &lt;filename&gt;</term>
129                 <listitem><para>NetBIOS lmhosts file.  The lmhosts 
130                 file is a list of NetBIOS names to IP addresses that 
131                 is loaded by the nmbd server and used via the name 
132                 resolution mechanism <smbconfoption name="name resolve order"/> described in <citerefentry><refentrytitle>smb.conf</refentrytitle>
133                 <manvolnum>5</manvolnum></citerefentry> to resolve any 
134                 NetBIOS name queries needed by the server. Note 
135                 that the contents of this file are <emphasis>NOT</emphasis> 
136                 used by <command>nmbd</command> to answer any name queries. 
137                 Adding a line to this file affects name NetBIOS resolution 
138                 from this host <emphasis>ONLY</emphasis>.</para>
139
140                 <para>The default path to this file is compiled into 
141                 Samba as part of the build process. Common defaults 
142                 are <filename>/usr/local/samba/lib/lmhosts</filename>,
143                 <filename>/usr/samba/lib/lmhosts</filename> or
144                 <filename>/etc/samba/lmhosts</filename>. See the <citerefentry><refentrytitle>lmhosts</refentrytitle>
145         <manvolnum>5</manvolnum></citerefentry> man page for details on the contents of this file.</para></listitem>
146                 </varlistentry>
147
148                 &stdarg.server.debug;
149                 &popt.common.samba;
150                 
151                 <varlistentry>
152                 <term>-p &lt;UDP port number&gt;</term>
153                 <listitem><para>UDP port number is a positive integer value.
154                 This option changes the default UDP port number (normally 137)
155                 that <command>nmbd</command> responds to name queries on. Don't
156                 use this option unless you are an expert, in which case you
157                 won't need help!</para></listitem>
158                 </varlistentry>
159
160         </variablelist>
161 </refsect1>
162
163 <refsect1>
164         <title>FILES</title>
165
166         <variablelist>
167                 <varlistentry>
168                 <term><filename>/etc/inetd.conf</filename></term>
169                 <listitem><para>If the server is to be run by the
170                 <command>inetd</command> meta-daemon, this file
171                 must contain suitable startup information for the
172                 meta-daemon. 
173                 </para></listitem>
174                 </varlistentry>
175
176                 <varlistentry>
177                 <term><filename>/etc/rc</filename></term>
178                 <listitem><para>or whatever initialization script your
179                 system uses).</para>
180
181                 <para>If running the server as a daemon at startup,
182                 this file will need to contain an appropriate startup
183                 sequence for the server.</para></listitem>
184                 </varlistentry>
185
186                 <varlistentry>
187                 <term><filename>/etc/services</filename></term>
188                 <listitem><para>If running the server via the
189                 meta-daemon <command>inetd</command>, this file
190                 must contain a mapping of service name (e.g., netbios-ssn)
191                 to service port (e.g., 139) and protocol type (e.g., tcp).
192                 </para></listitem>
193                 </varlistentry>
194
195                 <varlistentry>
196                 <term><filename>/usr/local/samba/lib/smb.conf</filename></term>
197                 <listitem><para>This is the default location of 
198                 the <citerefentry><refentrytitle>smb.conf</refentrytitle>
199                 <manvolnum>5</manvolnum></citerefentry> server
200                 configuration file. Other common places that systems
201                 install this file are <filename>/usr/samba/lib/smb.conf</filename>
202                 and <filename>/etc/samba/smb.conf</filename>.</para>
203
204                 <para>When run as a WINS server (see the
205                         <smbconfoption name="wins support"/>
206                 parameter in the <citerefentry><refentrytitle>smb.conf</refentrytitle>
207                 <manvolnum>5</manvolnum></citerefentry> man page),
208                 <command>nmbd</command>
209                 will store the WINS database in the file <filename>wins.dat</filename>
210                 in the <filename>var/locks</filename> directory configured under
211                 wherever Samba was configured to install itself.</para>
212
213                 <para>If <command>nmbd</command> is acting as a <emphasis>
214                                 browse master</emphasis> (see the <smbconfoption name="local master"/>
215                 parameter in the <citerefentry><refentrytitle>smb.conf</refentrytitle>
216         <manvolnum>5</manvolnum></citerefentry> man page, <command>nmbd</command>
217                 will store the browsing database in the file <filename>browse.dat
218                 </filename> in the <filename>var/locks</filename> directory
219                 configured under wherever Samba was configured to install itself.
220                 </para></listitem>
221                 </varlistentry>
222         </variablelist>
223 </refsect1>
224
225 <refsect1>
226         <title>SIGNALS</title>
227
228         <para>To shut down an <command>nmbd</command> process it is recommended
229         that SIGKILL (-9) <emphasis>NOT</emphasis> be used, except as a last
230         resort, as this may leave the name database in an inconsistent state.
231         The correct way to terminate <command>nmbd</command> is to send it
232         a SIGTERM (-15) signal and wait for it to die on its own.</para>
233
234         <para><command>nmbd</command> will accept SIGHUP, which will cause
235         it to dump out its namelists into the file <filename>namelist.debug
236         </filename> in the <filename>/usr/local/samba/var/locks</filename>
237         directory (or the <filename>var/locks</filename> directory configured
238         under wherever Samba was configured to install itself). This will also
239         cause <command>nmbd</command> to dump out its server database in
240         the <filename>log.nmb</filename> file.</para>
241
242         <para>The debug log level of nmbd may be raised or lowered
243         using <citerefentry><refentrytitle>smbcontrol</refentrytitle>
244         <manvolnum>1</manvolnum></citerefentry> (SIGUSR[1|2] signals
245         are no longer used since Samba 2.2). This is to allow
246         transient problems to be diagnosed, whilst still running 
247         at a normally low log level.</para>
248 </refsect1>
249
250
251 <refsect1>
252         <title>VERSION</title>
253
254         <para>This man page is correct for version 3 of 
255         the Samba suite.</para>
256 </refsect1>
257
258 <refsect1>
259         <title>SEE ALSO</title>
260         <para>
261         <citerefentry><refentrytitle>inetd</refentrytitle>
262         <manvolnum>8</manvolnum></citerefentry>, <citerefentry><refentrytitle>smbd</refentrytitle>
263         <manvolnum>8</manvolnum></citerefentry>, <citerefentry><refentrytitle>smb.conf</refentrytitle>
264         <manvolnum>5</manvolnum></citerefentry>, <citerefentry><refentrytitle>smbclient</refentrytitle>
265         <manvolnum>1</manvolnum></citerefentry>, <citerefentry><refentrytitle>testparm</refentrytitle>
266         <manvolnum>1</manvolnum></citerefentry>, and the Internet 
267         RFC's <filename>rfc1001.txt</filename>, <filename>rfc1002.txt</filename>. 
268         In addition the CIFS (formerly SMB) specification is available 
269         as a link from the Web page <ulink noescape="1" url="http://samba.org/cifs/"> 
270         http://samba.org/cifs/</ulink>.</para>
271 </refsect1>
272
273 <refsect1>
274         <title>AUTHOR</title>
275         
276         <para>The original Samba software and related utilities 
277         were created by Andrew Tridgell. Samba is now developed
278         by the Samba Team as an Open Source project similar 
279         to the way the Linux kernel is developed.</para>
280         
281         <para>The original Samba man pages were written by Karl Auer. 
282         The man page sources were converted to YODL format (another 
283         excellent piece of Open Source software, available at <ulink url="ftp://ftp.icce.rug.nl/pub/unix/">
284         ftp://ftp.icce.rug.nl/pub/unix/</ulink>) and updated for the Samba 2.0 
285         release by Jeremy Allison.  The conversion to DocBook for 
286         Samba 2.2 was done by Gerald Carter. The conversion to DocBook
287         XML 4.2 for Samba 3.0 was done by Alexander Bokovoy.</para>
288 </refsect1>
289
290 </refentry>