source: server/major/samba3.xml@ 3cb0c57

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 6.2 6.2.0 6.2.0-rc1 6.2.0-rc2 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 3cb0c57 was 3cb0c57, checked in by Randy McMurchy <randy@…>, 18 years ago

Added the 'User Notes' wiki link to each package page; changed all instances of .[so,a] to .{so,a} (brackets changed to braces); changed all replaceable tags to use angle brackets instead of square brackets to encapsulate the text - commit #9

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@5837 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 40.7 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY samba3-download-http "http://us1.samba.org/samba/ftp/stable/samba-&samba3-version;.tar.gz">
8 <!ENTITY samba3-download-ftp "ftp://ftp.samba.org/pub/samba/samba-&samba3-version;.tar.gz">
9 <!ENTITY samba3-md5sum "5c39505af17cf5caf3d6ed8bab135036">
10 <!ENTITY samba3-size "17.5 MB">
11 <!ENTITY samba3-buildsize "199 MB">
12 <!ENTITY samba3-time "2.8 SBU">
13]>
14
15<sect1 id="samba3" xreflabel="Samba-&samba3-version;">
16 <?dbhtml filename="samba3.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 <keywordset>
22 <keyword role="package">samba-&samba3-version;.tar</keyword>
23 <keyword role="ftpdir">samba</keyword>
24 </keywordset>
25 </sect1info>
26
27 <title>Samba-&samba3-version;</title>
28
29 <indexterm zone="samba3">
30 <primary sortas="a-Samba">Samba</primary>
31 </indexterm>
32
33 <sect2 role="package">
34 <title>Introduction to Samba</title>
35
36 <para>The <application>Samba</application> package provides file and print
37 services to SMB/CIFS clients and Windows networking to Linux clients.
38 <application>Samba</application> can also be configured as a Windows NT
39 4.0 Domain Controller replacement (with caveats working with NT PDC's and
40 BDC's), a file/print server acting as a member of a Windows NT 4.0 or
41 Active Directory domain and a NetBIOS (rfc1001/1002) nameserver (which
42 amongst other things provides LAN browsing support).</para>
43
44 <bridgehead renderas="sect3">Package Information</bridgehead>
45 <itemizedlist spacing="compact">
46 <listitem>
47 <para>Download (HTTP): <ulink url="&samba3-download-http;"/></para>
48 </listitem>
49 <listitem>
50 <para>Download (FTP): <ulink url="&samba3-download-ftp;"/></para>
51 </listitem>
52 <listitem>
53 <para>Download MD5 sum: &samba3-md5sum;</para>
54 </listitem>
55 <listitem>
56 <para>Download size: &samba3-size;</para>
57 </listitem>
58 <listitem>
59 <para>Estimated disk space required: &samba3-buildsize;</para>
60 </listitem>
61 <listitem>
62 <para>Estimated build time: &samba3-time;</para>
63 </listitem>
64 </itemizedlist>
65
66 <!--
67 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
68 <itemizedlist spacing="compact">
69 <listitem>
70 <para>Required patch if you have <application>Heimdal</application>
71 installed: <ulink
72 url="&patch-root;/samba-&samba3-version;-heimdal-1.patch"/></para>
73 </listitem>
74 </itemizedlist>
75 -->
76
77 <bridgehead renderas="sect3">Samba Dependencies</bridgehead>
78
79 <bridgehead renderas="sect4">Optional</bridgehead>
80 <para role="optional"><xref linkend="popt"/>,
81 <xref linkend="linux-pam"/>,
82 <xref linkend="openldap"/>,
83 <xref linkend="cups"/>,
84 <xref linkend="heimdal"/> or <xref linkend="mitkrb"/>, and
85 <xref linkend="python"/> (to build Samba API bindings for the
86 <application>Python</application> installation)</para>
87 <!-- only used for the test suite which is not really functional
88 and
89 <ulink url="http://valgrind.kde.org/">Valgrind</ulink></para> -->
90
91 <bridgehead renderas="sect4">Optional
92 (To Build Experimental passdb Libraries</bridgehead>
93 <para><xref linkend="libxml2"/>,
94 <xref linkend="mysql"/>,
95 <xref linkend="postgresql"/></para>
96
97 <para condition="html" role="usernotes">User Notes:
98 <ulink url="&blfs-wiki;/samba3"/></para>
99
100 </sect2>
101
102 <sect2 role="installation">
103 <title>Installation of Samba</title>
104
105 <!--
106 <para>A <application>Samba</application> <filename>include.h</filename>
107 header now does checks for C++ reserved names. The package will not build
108 if you have <application>Heimdal</application> installed as Heimdal uses
109 some of these reserved names inappropriately. If you have
110 <application>Heimdal</application> installed, apply the following patch to
111 disable these checks and allow the package to compile successfully:</para>
112
113<screen><userinput>patch -Np1 -i ../samba-&samba3-version;-heimdal-1.patch</userinput></screen>
114 -->
115
116 <para>Install <application>Samba</application> by running the following
117 commands:</para>
118
119 <note>
120 <para>You may want to run <command>configure</command> with the
121 <option>--help</option> parameter. There may be other parameters
122 needed to take advantage of the optional dependencies.</para>
123 </note>
124
125<screen><userinput>cd source &amp;&amp;
126./configure \
127 --prefix=/usr \
128 --sysconfdir=/etc \
129 --localstatedir=/var \
130 --with-piddir=/var/run \
131 --with-fhs \
132 --with-smbmount &amp;&amp;
133make</userinput></screen>
134
135 <para>This package does not come with a functional test suite.</para>
136
137 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
138
139<!-- Commenting out the need for /var/cache/samba as my testing has
140 shown me that this directory is not used. Grepping the source
141 tree also turns up nothing about 'cache/samba'. -Randy
142<screen role="root"><userinput>install -v -m755 -d /var/cache/samba &amp;&amp;
143-->
144
145<screen role="root"><userinput>make install &amp;&amp;
146mv -v /usr/lib/samba/libsmbclient.so /usr/lib &amp;&amp;
147ln -v -sf ../libsmbclient.so /usr/lib/samba &amp;&amp;
148ln -v -sf libsmbclient.so /usr/lib/libsmbclient.so.0 &amp;&amp;
149
150chmod -v 644 /usr/include/lib{smbclient,msrpc}.h &amp;&amp;
151
152install -v -m755 nsswitch/libnss_win{s,bind}.so /lib &amp;&amp;
153ln -v -sf libnss_winbind.so /lib/libnss_winbind.so.2 &amp;&amp;
154ln -v -sf libnss_wins.so /lib/libnss_wins.so.2 &amp;&amp;
155
156if [ -f nsswitch/pam_winbind.so ]; then
157 install -v -m755 nsswitch/pam_winbind.so /lib/security
158fi &amp;&amp;
159
160install -v -m644 ../examples/smb.conf.default /etc/samba &amp;&amp;
161
162install -v -m755 -d /usr/share/doc/samba-&samba3-version; &amp;&amp;
163install -v -m644 ../docs/*.pdf /usr/share/doc/samba-&samba3-version; &amp;&amp;
164ln -v -s ../../samba/swat /usr/share/doc/samba-&samba3-version;</userinput></screen>
165
166 <para>If you passed the <option>--with-python</option> option to the
167 <command>configure</command> script, issue the following command as the
168 <systemitem class="username">root</systemitem> user to install the
169 <application>Python</application> extensions:</para>
170
171<screen role="root"><userinput>make python_install</userinput></screen>
172
173 </sect2>
174
175 <sect2 role="commands">
176 <title>Command Explanations</title>
177
178 <para><parameter>--sysconfdir=/etc</parameter>: Sets the configuration
179 file directory to avoid the default of
180 <filename class="directory">/usr/etc</filename>.</para>
181
182 <para><parameter>--localstatedir=/var</parameter>: Sets the variable
183 data directory to avoid the default of
184 <filename class="directory">/usr/var</filename>.</para>
185
186 <para><parameter>--with-fhs</parameter>: Assigns all other file paths in
187 a manner compliant with the Filesystem Hierarchy Standard (FHS).</para>
188
189 <para><parameter>--with-smbmount</parameter>: Orders the creation of an
190 extra binary for use by the <command>mount</command> command so that
191 mounting remote SMB (Windows) shares becomes no more complex than
192 mounting remote NFS shares.</para>
193
194 <para><option>--with-pam</option>: Use this parameter to link
195 <application>Linux-PAM</application> into the build. This
196 also builds the <filename class='libraryfile'>pam_winbind.so</filename>
197 <application>PAM</application> module. You can find
198 instructions on how to configure and use the module by running
199 <command>man winbindd</command>.</para>
200
201 <!-- I am convinced that this command is no longer necessary. -Randy
202 <para><command>install -v -d /var/cache/samba</command>: This directory is
203 needed for proper operation of the <command>smbd</command> and
204 <command>nmbd</command> daemons.</para>
205 -->
206
207 <para><command>mv -v /usr/lib/samba/libsmbclient.so ...; ln -v -sf
208 ../libsmbclient.so ...</command>: The
209 <filename class='libraryfile'>libsmbclient.so</filename> library is needed
210 by other packages. This command moves it to a location where other packages
211 can find it.</para>
212
213 <para><command>install -v -m755 nsswitch/libnss_win{s,bind}.so /lib</command>:
214 The nss libraries are not installed by default. If you intend to use
215 winbindd for domain auth, and/or WINS name resolution,
216 you need these libraries.</para>
217
218 <para><command>ln -v -sf libnss_winbind.so /lib/libnss_winbind.so.2</command>
219 and <command>ln -v -sf libnss_wins.so /lib/libnss_wins.so.2</command>:
220 These symlinks are required by glibc to use the NSS
221 libraries.</para>
222
223 <para><command>install -v -m644 ../examples/smb.conf.default
224 /etc/samba</command>: This copies a default <filename>smb.conf</filename>
225 file into <filename>/etc/samba</filename>. This sample configuration will
226 not work until you copy it to <filename>/etc/samba/smb.conf</filename> and
227 make the appropriate changes for your installation. See the configuration
228 section for minimum values which must be set.</para>
229
230 </sect2>
231
232 <sect2 role="configuration">
233 <title>Configuring Samba</title>
234
235 <sect3 id="samba3-config">
236 <title>Config Files</title>
237
238 <para>/etc/samba/smb.conf</para>
239
240 <indexterm zone="samba3 samba3-config">
241 <primary sortas="e-etc-samba-smb.conf">/etc/samba/smb.conf</primary>
242 </indexterm>
243
244 </sect3>
245
246 <sect3>
247 <title>Mounting Shares by Unprivileged Users</title>
248
249 <para>If it is desired for unprivileged users to directly mount (and
250 unmount) SMB shares, the <command>smbmnt</command> and
251 <command>smbumount</command> commands must be setuid
252 <systemitem class='username'>root</systemitem>. Note that users can
253 only mount SMB shares on a mount point owned by that user (requires
254 write access also). If desired, change these programs to setuid
255 <systemitem class='username'>root</systemitem> by issuing the following
256 command as the <systemitem class='username'>root</systemitem>
257 user:</para>
258
259<screen role="root"><userinput>chmod -v 4755 /usr/bin/smb{mnt,umount}</userinput></screen>
260
261 </sect3>
262
263 <sect3>
264 <title>Printing to SMB Clients</title>
265
266 <para>If you use <application>CUPS</application> for print services,
267 and you wish to print to a printer attached to an SMB client, you
268 need to create an SMB backend device. To create the device, issue the
269 following command as the <systemitem class="username">root</systemitem>
270 user:</para>
271
272<screen role="root"><userinput>ln -v -sf /usr/bin/smbspool /usr/lib/cups/backend/smb</userinput></screen>
273
274 </sect3>
275
276 <sect3>
277 <title>Configuration Information</title>
278
279 <para>Due to the complexity and the many various uses for
280 <application>Samba</application>, complete configuration for all the
281 package's capabilities is well beyond the scope of the BLFS book. This
282 section provides instructions to configure the
283 <filename>/etc/samba/smb.conf</filename> file for two common scenarios.
284 The complete contents of <filename>/etc/samba/smb.conf</filename> will
285 depend on the purpose of <application>Samba</application>
286 installation.</para>
287
288 <note>
289 <para>You may find it easier to copy the configuration parameters shown
290 below into an empty <filename>/etc/samba/smb.conf</filename> file
291 instead of copying and editing the default file as mentioned in the
292 <quote>Command Explanations</quote> section. How you create/edit the
293 <filename>/etc/samba/smb.conf</filename> file will be left up to
294 you. Do ensure the file is only writeable by the
295 <systemitem class="username">root</systemitem> user (mode 644).</para>
296 </note>
297
298 <sect4>
299 <title>Scenario 1: Minimal Standalone Client-Only Installation</title>
300
301 <para>Choose this variant if you only want to transfer files using
302 <command>smbclient</command>, mount Windows shares and print to Windows
303 printers, and don't want to share your files and printers to Windows
304 machines.</para>
305
306 <para>A <filename>/etc/samba/smb.conf</filename> file with the following
307 three parameters is sufficient:</para>
308
309<screen role='root'><literal>[global]
310 workgroup = <replaceable>MYGROUP</replaceable>
311 dos charset = <replaceable>cp850</replaceable>
312 unix charset = <replaceable>ISO-8859-1</replaceable></literal></screen>
313
314 <para>The values in this example specify that the computer belongs to a
315 Windows workgroup named
316 <quote><replaceable>MYGROUP</replaceable></quote>, uses the
317 <quote><replaceable>cp850</replaceable></quote> character set on the
318 wire when talking to MS-DOS and MS Windows 9x, and that the filenames
319 are stored in the <quote><replaceable>ISO-8859-1</replaceable></quote>
320 encoding on the disk. Adjust these values appropriately for your
321 installation. The <quote>unix charset</quote> value must be the same as
322 the output of <command>locale charmap</command> when executed with the
323 <envar>LANG</envar> variable set to your preferred locale, otherwise the
324 <command>ls</command> command may not display correct filenames of
325 downloaded files.</para>
326
327 <para>There is no need to run any <application>Samba</application>
328 servers in this scenario, thus you don't need to install the provided
329 bootscripts.</para>
330
331 </sect4>
332
333 <sect4>
334 <title>Scenario 2: Standalone File/Print Server</title>
335
336 <para>Choose this variant if you want to share your files and printers
337 to Windows machines in your workgroup in addition to the capabilities
338 described in Scenario 1.</para>
339
340 <para>In this case, the <filename>/etc/samba/smb.conf.default</filename>
341 file may be a good template to start from. Also add
342 <quote>dos charset</quote> and <quote>unix charset</quote> parameters
343 to the <quote>[global]</quote> section as described in Scenario 1 in
344 order to prevent filename corruption.</para>
345
346 <para>The following configuration file creates a separate share for each
347 user's home directory and also makes all printers available to Windows
348 machines:</para>
349
350<screen role='root'><literal>[global]
351 workgroup = <replaceable>MYGROUP</replaceable>
352 dos charset = <replaceable>cp850</replaceable>
353 unix charset = <replaceable>ISO-8859-1</replaceable>
354
355[homes]
356 comment = Home Directories
357 browseable = no
358 writable = yes
359
360[printers]
361 comment = All Printers
362 path = /var/spool/samba
363 browseable = no
364 guest ok = no
365 printable = yes</literal></screen>
366
367 <para>Other parameters you may wish to customize in the
368 <quote>[global]</quote> section include:</para>
369
370<screen role='root'><literal> server string =
371 security =
372 hosts allow =
373 load printers =
374 log file =
375 max log size =
376 socket options =
377 local master =</literal></screen>
378
379 <para>Reference the comments in the
380 <filename>/etc/samba/smb.conf.default</filename> file for information
381 regarding these parameters.</para>
382
383 <para>Since the <command>smbd</command> and <command>nmbd</command>
384 daemons are needed in this case, install the <filename>samba</filename>
385 bootscript. Be sure to run <command>smbpasswd</command> (with the
386 <option>-a</option> option to add users) to enable and
387 set passwords for all accounts that need
388 <application>Samba</application> access, or use the SWAT web interface
389 (see below) to do the same. Using the default
390 <application>Samba</application> passdb backend, any user you attempt
391 to add will also be required to exist in the
392 <filename>/etc/passwd</filename> file.</para>
393
394 </sect4>
395
396 <sect4>
397 <title>Advanced Requirements</title>
398
399 <para>More complex scenarios involving domain control or membership are
400 possible if the right flags are passed to the ./configure script when
401 the package is built. Such setups are advanced topics and cannot be
402 adequately covered in BLFS. Many complete books have been written on
403 these topics alone. It should be noted, however, that a
404 <application>Samba</application> BDC cannot be used as a fallback
405 for a Windows PDC, and conversely, a Windows BDC cannot be used as a
406 fallback for a <application>Samba</application> PDC. Also in some
407 domain membership scenarios, the <command>winbindd</command> daemon and
408 the corresponding bootscript are needed.</para>
409
410 <para>There is quite a bit of documentation available which covers many
411 of these advanced configurations. Point your web browser to the links
412 below to view some of the documentation included with the
413 <application>Samba</application> package:</para>
414
415 <itemizedlist spacing='compact'>
416 <listitem>
417 <para>Using Samba, 2nd Edition; a popular book published by O'Reilly
418 <ulink url="file:///usr/share/samba/swat/using_samba/toc.html"/></para>
419 </listitem>
420 <listitem>
421 <para>The Official Samba HOWTO and Reference Guide <ulink
422 url="file:///usr/share/samba/swat/help/Samba-HOWTO-Collection/index.html"/>
423 </para>
424 </listitem>
425 <listitem>
426 <para>Samba-3 by Example
427 <ulink url="file:///usr/share/samba/swat/help/Samba-Guide/index.html"/>
428 </para>
429 </listitem>
430 <listitem>
431 <para>The Samba-3 man Pages
432 <ulink url="file:///usr/share/samba/swat/help/samba.7.html"/></para>
433 </listitem>
434 </itemizedlist>
435
436 </sect4>
437
438 </sect3>
439
440 <sect3 id="samba3-swat-config">
441 <title>Configuring SWAT</title>
442
443 <para>The built in SWAT (<application>Samba</application> Web
444 Administration Tool) utility can be used for basic configuration of
445 the <application>Samba</application> installation, but because it may
446 be inconvenient, undesirable or perhaps even impossible to gain
447 access to the console, BLFS recommends setting up access to SWAT using
448 <application>Stunnel</application>. Without
449 <application>Stunnel</application>, the
450 <systemitem class="username">root</systemitem> password is transmitted
451 in clear text over the wire, and is considered an unacceptable security
452 risk. After considering the security implications of using SWAT without
453 <application>Stunnel</application>, and you still wish to implement SWAT
454 without it, instructions are provided at this end of this section.</para>
455
456 <indexterm zone="samba3 samba3-swat-config">
457 <primary sortas="g-SWAT">SWAT</primary>
458 </indexterm>
459
460 <sect4>
461 <title>Setting up SWAT using Stunnel</title>
462
463 <para>First install, or ensure you have already installed, the
464 <xref linkend="stunnel"/> package.</para>
465
466 <para>Next you must add entries to <filename>/etc/services</filename>
467 and modify the <command>inetd</command>/<command>xinetd</command>
468 configuration.</para>
469
470 <indexterm zone="samba3 samba3-swat-config">
471 <primary sortas="e-etc-services">/etc/services</primary>
472 </indexterm>
473
474 <indexterm zone="samba3 samba3-swat-config">
475 <primary sortas="e-etc-inetd.conf">/etc/inetd.conf</primary>
476 </indexterm>
477
478 <indexterm zone="samba3 samba3-swat-config">
479 <primary sortas="e-etc-xinetd.conf">/etc/xinetd.conf</primary>
480 </indexterm>
481
482 <para>Add swat and swat_tunnel entries to
483 <filename>/etc/services</filename> with the following commands issued
484 as the <systemitem class="username">root</systemitem> user:</para>
485
486<screen role="root"><userinput>echo "swat 901/tcp" &gt;&gt; /etc/services &amp;&amp;
487echo "swat_tunnel 902/tcp" &gt;&gt; /etc/services</userinput></screen>
488
489 <para>If <command>inetd</command> is used, the following command will
490 add the swat_tunnel entry to <filename>/etc/inetd.conf</filename> (as
491 user <systemitem class="username">root</systemitem>):</para>
492
493<screen role="root"><userinput>echo "swat_tunnel stream tcp nowait.400 root /usr/sbin/swat swat" \
494 &gt;&gt; /etc/inetd.conf</userinput></screen>
495
496 <para>Issue a <command>killall -HUP inetd</command> to reread the
497 changed <filename>inetd.conf</filename> file.</para>
498
499 <para>If you use <command>xinetd</command>, the following command will
500 create the <application>Samba</application> file as
501 <filename>/etc/xinetd.d/swat_tunnel</filename> (you may need to modify
502 or remove the <quote>only_from</quote> line to include the desired
503 host[s]):</para>
504
505<screen role="root"><userinput>cat &gt;&gt; /etc/xinetd.d/swat_tunnel &lt;&lt; "EOF"
506<literal># Begin /etc/xinetd.d/swat_tunnel
507
508service swat_tunnel
509{
510 port = 902
511 socket_type = stream
512 wait = no
513 only_from = 127.0.0.1
514 user = root
515 server = /usr/sbin/swat
516 log_on_failure += USERID
517}
518
519# End /etc/xinetd.d/swat_tunnel</literal>
520EOF</userinput></screen>
521
522 <indexterm zone="samba3 samba3-swat-config">
523 <primary sortas="e-etc-xinetd.d-swat-tunnel">/etc/xinetd.d/swat_tunnel</primary>
524 </indexterm>
525
526 <para>Issue a <command>killall -HUP xinetd</command> to read the new
527 <filename>/etc/xinetd.d/swat_tunnel</filename> file.</para>
528
529 <para>Next, you must add an entry for the swat service to the
530 <filename>/etc/stunnel/stunnel.conf</filename> file (as user
531 <systemitem class="username">root</systemitem>):</para>
532
533 <indexterm zone="samba3 samba3-swat-config">
534 <primary sortas="e-etc-stunnel-stunnel.conf">/etc/stunnel/stunnel.conf</primary>
535 </indexterm>
536
537<screen role="root"><userinput>cat &gt;&gt; /etc/stunnel/stunnel.conf &lt;&lt; "EOF"
538<literal>[swat]
539accept = 901
540connect = 902
541TIMEOUTclose = 1</literal>
542
543EOF</userinput></screen>
544
545 <para>Restart the <command>stunnel</command> daemon using the following
546 command as the <systemitem class="username">root</systemitem> user:</para>
547
548<screen role="root"><userinput>/etc/rc.d/init.d/stunnel restart</userinput></screen>
549
550 <para>SWAT can be launched by pointing your web browser to
551 <uri>https://<replaceable>&lt;CA_DN_field&gt;</replaceable>:901</uri>.
552 Substitute the hostname listed in the DN field of the CA certificate
553 used with <application>Stunnel</application> for
554 <replaceable>&lt;CA_DN_field&gt;</replaceable>.</para>
555
556 </sect4>
557
558 <sect4>
559 <title>Setting up SWAT without Stunnel</title>
560
561 <warning>
562 <para>BLFS does not recommend using these procedures because of the
563 security risk involved. However, in a home network environment and
564 disclosure of the <systemitem class='username'>root</systemitem>
565 password is an acceptable risk, the following
566 instructions are provided for your convenience.</para>
567 </warning>
568
569 <para>Add a swat entry to <filename>/etc/services</filename> with the
570 following command issued as the
571 <systemitem class='username'>root</systemitem> user:</para>
572
573<screen role='root'><userinput>echo "swat 901/tcp" &gt;&gt; /etc/services</userinput></screen>
574
575 <para>If <command>inetd</command> is used, the following command
576 issued as the <systemitem class='username'>root</systemitem> user will
577 add a swat entry to the <filename>/etc/inetd.conf</filename> file:</para>
578
579<screen role='root'><userinput>echo "swat stream tcp nowait.400 root /usr/sbin/swat swat" \
580 &gt;&gt; /etc/inetd.conf</userinput></screen>
581
582 <para>Issue a <command>killall -HUP inetd</command> to reread the
583 changed <filename>inetd.conf</filename> file.</para>
584
585 <para>If <command>xinetd</command> is used, the following command
586 issued as the <systemitem class='username'>root</systemitem> user
587 will create an <filename>/etc/xinetd.d/swat</filename> file:</para>
588
589<screen role='root'><userinput>cat &gt;&gt; /etc/xinetd.d/swat &lt;&lt; "EOF"
590<literal># Begin /etc/xinetd.d/swat
591
592service swat
593{
594 port = 901
595 socket_type = stream
596 wait = no
597 only_from = 127.0.0.1
598 user = root
599 server = /usr/sbin/swat
600 log_on_failure += USERID
601}
602
603# End /etc/xinetd.d/swat</literal>
604EOF</userinput></screen>
605
606 <para>Issue a <command>killall -HUP xinetd</command> to read the
607 new <filename>/etc/xinetd.d/swat</filename> file.</para>
608
609 <para>SWAT can be launched by pointing your web browser to
610 http://localhost:901.</para>
611
612 </sect4>
613
614 </sect3>
615
616 <sect3>
617 <title/>
618
619 <note>
620 <para>If you linked <application>Linux-PAM</application> into the
621 <application>Samba</application> build, you'll need to create an
622 <filename>/etc/pam.d/samba</filename> file.</para>
623 </note>
624
625 <indexterm zone="samba3 samba3-swat-config">
626 <primary sortas="e-etc-pam.d-samba">/etc/pam.d/samba</primary>
627 </indexterm>
628
629 </sect3>
630
631 <sect3 id="samba3-init">
632 <title>Boot Script</title>
633
634 <para>For your convenience, boot scripts have been provided for
635 <application>Samba</application>. There are two included in the
636 <xref linkend="bootscripts"/> package. The first,
637 <filename>samba</filename>, will start the <command>smbd</command>
638 and <command>nmbd</command> daemons needed to provide SMB/CIFS
639 services. The second script, <filename>winbind</filename>, starts
640 the <command>winbindd</command> daemon, used for providing Windows
641 domain services to Linux clients.</para>
642
643 <indexterm zone="samba3 samba3-init">
644 <primary sortas="f-samba">samba</primary>
645 </indexterm>
646
647 <indexterm zone="samba3 samba3-init">
648 <primary sortas="f-winbind">winbind</primary>
649 </indexterm>
650
651 <para>The default <application>Samba</application> installation uses the
652 <systemitem class='username'>nobody</systemitem> user for guest access
653 to the server. This can be overridden by setting the
654 <option>guest account =</option> parameter in the
655 <filename>/etc/samba/smb.conf</filename> file. If you utilize the
656 <option>guest account =</option> parameter, ensure this user exists in
657 the <filename>/etc/passwd</filename> file. To use the default user,
658 issue the following commands as the
659 <systemitem class='username'>root</systemitem> user:</para>
660
661<screen><userinput>groupadd -g 99 nogroup &amp;&amp;
662useradd -c "Unprivileged Nobody" -d /dev/null -g nogroup \
663 -s /bin/false -u 99 nobody</userinput></screen>
664
665 <para>Install the <filename>samba</filename> script with the following
666 command issued as the <systemitem class="username">root</systemitem>
667 user:</para>
668
669<screen role="root"><userinput>make install-samba</userinput></screen>
670
671 <para>If you also need the <filename>winbind</filename>
672 script:</para>
673
674<screen role="root"><userinput>make install-winbind</userinput></screen>
675
676 </sect3>
677
678 </sect2>
679
680 <sect2 role="content">
681 <title>Contents</title>
682
683 <segmentedlist>
684 <segtitle>Installed Programs</segtitle>
685 <segtitle>Installed Libraries</segtitle>
686 <segtitle>Installed Directories</segtitle>
687
688<!--newprogs: eventlogadm smbget-->
689
690 <seglistitem>
691 <seg>eventlogadm, findsmb, mount.smbfs, net, nmbd, nmblookup,
692 ntlm_auth, pdbedit, profiles, rpcclient, smbcacls, smbclient,
693 smbcontrol, smbcquotas, smbd, smbget, smbmnt, smbmount, smbpasswd,
694 smbspool, smbstatus, smbtar, smbtree, smbumount, swat, tdbbackup,
695 tdbdump, tdbtool, testparm, testprns, wbinfo, and winbindd</seg>
696 <seg>libnss_winbind.so, libnss_wins.so, libsmbclient.so, libmsrpc.so,
697 the pam_winbind.so PAM library and assorted character set, filesystem
698 and support modules.</seg>
699 <seg>/etc/samba, /usr/lib/python2.4/site-packages/samba,
700 /usr/lib/samba, /usr/share/doc/samba-&samba3-version;,
701 /usr/share/samba, /var/lib/samba and /var/log/samba</seg>
702 </seglistitem>
703 </segmentedlist>
704
705 <variablelist>
706 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
707 <?dbfo list-presentation="list"?>
708 <?dbhtml list-presentation="table"?>
709
710 <varlistentry id="eventlogadm">
711 <term><command>eventlogadm</command></term>
712 <listitem>
713 <para>is used to write records to eventlogs from STDIN, add the
714 specified source and DLL eventlog registry entries and display the
715 active eventlog names (from <filename>smb.conf</filename>).</para>
716 <indexterm zone="samba3 eventlogadm">
717 <primary sortas="b-eventlogadm">eventlogadm</primary>
718 </indexterm>
719 </listitem>
720 </varlistentry>
721
722 <varlistentry id="findsmb">
723 <term><command>findsmb</command></term>
724 <listitem>
725 <para>lists information about machines that respond to
726 SMB name queries on a subnet.</para>
727 <indexterm zone="samba3 findsmb">
728 <primary sortas="b-findsmb">findsmb</primary>
729 </indexterm>
730 </listitem>
731 </varlistentry>
732
733 <varlistentry id="mount.smbfs">
734 <term><command>mount.smbfs</command></term>
735 <listitem>
736 <para>is a symlink to <command>smbmount</command> which provides
737 <command>/bin/mount</command> with a way to mount remote Windows
738 (or <application>Samba</application>) fileshares.</para>
739 <indexterm zone="samba3 mount.smbfs">
740 <primary sortas="b-mount.smbfs">mount.smbfs</primary>
741 </indexterm>
742 </listitem>
743 </varlistentry>
744
745 <varlistentry id="net">
746 <term><command>net</command></term>
747 <listitem>
748 <para>is a tool for administration of
749 <application>Samba</application> and remote CIFS servers, similar
750 to the <command>net</command> utility for DOS/Windows.</para>
751 <indexterm zone="samba3 net">
752 <primary sortas="b-net">net</primary>
753 </indexterm>
754 </listitem>
755 </varlistentry>
756
757 <varlistentry id="nmbd">
758 <term><command>nmbd</command></term>
759 <listitem>
760 <para>is the <application>Samba</application>
761 NetBIOS name server.</para>
762 <indexterm zone="samba3 nmbd">
763 <primary sortas="b-nmbd">nmbd</primary>
764 </indexterm>
765 </listitem>
766 </varlistentry>
767
768 <varlistentry id="nmblookup">
769 <term><command>nmblookup</command></term>
770 <listitem>
771 <para>is used to query NetBIOS names and map
772 them to IP addresses.</para>
773 <indexterm zone="samba3 nmblookup">
774 <primary sortas="b-nmblookup">nmblookup</primary>
775 </indexterm>
776 </listitem>
777 </varlistentry>
778
779 <varlistentry id="ntlm_auth">
780 <term><command>ntlm_auth</command></term>
781 <listitem>
782 <para>is a tool to allow external access to Winbind's
783 NTLM authentication function.</para>
784 <indexterm zone="samba3 ntlm_auth">
785 <primary sortas="b-ntlm_auth">ntlm_auth</primary>
786 </indexterm>
787 </listitem>
788 </varlistentry>
789
790 <varlistentry id="pdbedit">
791 <term><command>pdbedit</command></term>
792 <listitem>
793 <para>is a tool used to manage the SAM database.</para>
794 <indexterm zone="samba3 pdbedit">
795 <primary sortas="b-pdbedit">pdbedit</primary>
796 </indexterm>
797 </listitem>
798 </varlistentry>
799
800 <varlistentry id="profiles">
801 <term><command>profiles</command></term>
802 <listitem>
803 <para>is a utility that reports and changes SIDs in Windows
804 registry files. It currently only supports Windows NT.</para>
805 <indexterm zone="samba3 profiles">
806 <primary sortas="b-profiles">profiles</primary>
807 </indexterm>
808 </listitem>
809 </varlistentry>
810
811 <varlistentry id="rpcclient">
812 <term><command>rpcclient</command></term>
813 <listitem>
814 <para>is used to execute MS-RPC client side functions.</para>
815 <indexterm zone="samba3 rpcclient">
816 <primary sortas="b-rpcclient">rpcclient</primary>
817 </indexterm>
818 </listitem>
819 </varlistentry>
820
821 <varlistentry id="smbcacls">
822 <term><command>smbcacls</command></term>
823 <listitem>
824 <para>is used to manipulate Windows NT access control lists.</para>
825 <indexterm zone="samba3 smbcacls">
826 <primary sortas="b-smbcacls">smbcacls</primary>
827 </indexterm>
828 </listitem>
829 </varlistentry>
830
831 <varlistentry id="smbclient">
832 <term><command>smbclient</command></term>
833 <listitem>
834 <para>is a SMB/CIFS access utility, similar to FTP.</para>
835 <indexterm zone="samba3 smbclient">
836 <primary sortas="b-smbclient">smbclient</primary>
837 </indexterm>
838 </listitem>
839 </varlistentry>
840
841 <varlistentry id="smbcontrol">
842 <term><command>smbcontrol</command></term>
843 <listitem>
844 <para>is used to control running <command>smbd</command>,
845 <command>nmbd</command> and <command>winbindd</command>
846 daemons.</para>
847 <indexterm zone="samba3 smbcontrol">
848 <primary sortas="b-smbcontrol">smbcontrol</primary>
849 </indexterm>
850 </listitem>
851 </varlistentry>
852
853 <varlistentry id="smbcquotas">
854 <term><command>smbcquotas</command></term>
855 <listitem>
856 <para>is used to manipulate Windows NT quotas on
857 SMB file shares.</para>
858 <indexterm zone="samba3 smbcquotas">
859 <primary sortas="b-smbcquotas">smbcquotas</primary>
860 </indexterm>
861 </listitem>
862 </varlistentry>
863
864 <varlistentry id="smbd">
865 <term><command>smbd</command></term>
866 <listitem>
867 <para>is the main <application>Samba</application> daemon which
868 provides SMB/CIFS services to clients.</para>
869 <indexterm zone="samba3 smbd">
870 <primary sortas="b-smbd">smbd</primary>
871 </indexterm>
872 </listitem>
873 </varlistentry>
874
875 <varlistentry id="smbget">
876 <term><command>smbget</command></term>
877 <listitem>
878 <para>is a simple utility with <command>wget</command>-like
879 semantics, that can download files from SMB servers. You can specify
880 the files you would like to download on the command-line.</para>
881 <indexterm zone="samba3 smbget">
882 <primary sortas="b-smbget">smbget</primary>
883 </indexterm>
884 </listitem>
885 </varlistentry>
886
887 <varlistentry id="smbmnt">
888 <term><command>smbmnt</command></term>
889 <listitem>
890 <para>is a helper application used by the
891 <command>smbmount</command> program to do the actual mounting of
892 SMB shares. It can be installed setuid
893 <systemitem class='username'>root</systemitem> if you want
894 unprivileged users to be able to mount their SMB shares.</para>
895 <indexterm zone="samba3 smbmnt">
896 <primary sortas="b-smbmnt">smbmnt</primary>
897 </indexterm>
898 </listitem>
899 </varlistentry>
900
901 <varlistentry id="smbmount">
902 <term><command>smbmount</command></term>
903 <listitem>
904 <para>is usually invoked as <command>mount.smbfs</command> by the
905 <command>mount</command> command when using the
906 <parameter>-t smbfs</parameter> option, mounts a Linux SMB
907 filesystem.</para>
908 <indexterm zone="samba3 smbmount">
909 <primary sortas="b-smbmount">smbmount</primary>
910 </indexterm>
911 </listitem>
912 </varlistentry>
913
914 <varlistentry id="smbpasswd">
915 <term><command>smbpasswd</command></term>
916 <listitem>
917 <para>changes a user's <application>Samba</application>
918 password.</para>
919 <indexterm zone="samba3 smbpasswd">
920 <primary sortas="b-smbpasswd">smbpasswd</primary>
921 </indexterm>
922 </listitem>
923 </varlistentry>
924
925 <varlistentry id="smbspool">
926 <term><command>smbspool</command></term>
927 <listitem>
928 <para>sends a print job to an SMB printer.</para>
929 <indexterm zone="samba3 smbspool">
930 <primary sortas="b-smbspool">smbspool</primary>
931 </indexterm>
932 </listitem>
933 </varlistentry>
934
935 <varlistentry id="smbstatus">
936 <term><command>smbstatus</command></term>
937 <listitem>
938 <para>reports current <application>Samba</application>
939 connections.</para>
940 <indexterm zone="samba3 smbstatus">
941 <primary sortas="b-smbstatus">smbstatus</primary>
942 </indexterm>
943 </listitem>
944 </varlistentry>
945
946 <varlistentry id="smbtar">
947 <term><command>smbtar</command></term>
948 <listitem>
949 <para>is a shell script used for backing up SMB/CIFS shares
950 directly to Linux tape drives or a file.</para>
951 <indexterm zone="samba3 smbtar">
952 <primary sortas="b-smbtar">smbtar</primary>
953 </indexterm>
954 </listitem>
955 </varlistentry>
956
957 <varlistentry id="smbtree">
958 <term><command>smbtree</command></term>
959 <listitem>
960 <para>is a text-based SMB network browser.</para>
961 <indexterm zone="samba3 smbtree">
962 <primary sortas="b-smbtree">smbtree</primary>
963 </indexterm>
964 </listitem>
965 </varlistentry>
966
967 <varlistentry id="smbumount">
968 <term><command>smbumount</command></term>
969 <listitem>
970 <para>is used by unprivileged users to unmount SMB filesystems,
971 provided that it is setuid root.</para>
972 <indexterm zone="samba3 smbumount">
973 <primary sortas="b-smbumount">smbumount</primary>
974 </indexterm>
975 </listitem>
976 </varlistentry>
977
978 <varlistentry id="swat">
979 <term><command>swat</command></term>
980 <listitem>
981 <para>is the <application>Samba</application> Web Administration
982 Tool.</para>
983 <indexterm zone="samba3 swat">
984 <primary sortas="b-swat">swat</primary>
985 </indexterm>
986 </listitem>
987 </varlistentry>
988
989 <varlistentry id="tdbbackup">
990 <term><command>tdbbackup</command></term>
991 <listitem>
992 <para>is a tool for backing up or validating the integrity of
993 <application>Samba</application> <filename>.tdb</filename>
994 files.</para>
995 <indexterm zone="samba3 tdbbackup">
996 <primary sortas="b-tdbbackup">tdbbackup</primary>
997 </indexterm>
998 </listitem>
999 </varlistentry>
1000
1001 <varlistentry id="tdbdump">
1002 <term><command>tdbdump</command></term>
1003 <listitem>
1004 <para> is a tool used to print the contents of a
1005 <application>Samba</application> <filename>.tdb</filename>
1006 file.</para>
1007 <indexterm zone="samba3 tdbdump">
1008 <primary sortas="b-tdbdump">tdbdump</primary>
1009 </indexterm>
1010 </listitem>
1011 </varlistentry>
1012
1013 <varlistentry id="tdbtool">
1014 <term><command>tdbtool</command></term>
1015 <listitem>
1016 <para>is a tool which allows simple database manipulation from the
1017 command line.</para>
1018 <indexterm zone="samba3 tdbtool">
1019 <primary sortas="b-tdbtool">tdbtool</primary>
1020 </indexterm>
1021 </listitem>
1022 </varlistentry>
1023
1024 <varlistentry id="testparm">
1025 <term><command>testparm</command></term>
1026 <listitem>
1027 <para>checks an <filename>smb.conf</filename> file for proper
1028 syntax.</para>
1029 <indexterm zone="samba3 testparm">
1030 <primary sortas="b-testparm">testparm</primary>
1031 </indexterm>
1032 </listitem>
1033 </varlistentry>
1034
1035 <varlistentry id="testprns">
1036 <term><command>testprns</command></term>
1037 <listitem>
1038 <para>tests printer names.</para>
1039 <indexterm zone="samba3 testprns">
1040 <primary sortas="b-testprns">testprns</primary>
1041 </indexterm>
1042 </listitem>
1043 </varlistentry>
1044
1045 <varlistentry id="wbinfo">
1046 <term><command>wbinfo</command></term>
1047 <listitem>
1048 <para>queries a running <command>winbindd</command> daemon.</para>
1049 <indexterm zone="samba3 wbinfo">
1050 <primary sortas="b-wbinfo">wbinfo</primary>
1051 </indexterm>
1052 </listitem>
1053 </varlistentry>
1054
1055 <varlistentry id="winbindd">
1056 <term><command>winbindd</command></term>
1057 <listitem>
1058 <para>resolves names from Windows NT servers.</para>
1059 <indexterm zone="samba3 winbindd">
1060 <primary sortas="b-winbindd">winbindd</primary>
1061 </indexterm>
1062 </listitem>
1063 </varlistentry>
1064
1065 </variablelist>
1066
1067 </sect2>
1068
1069</sect1>
Note: See TracBrowser for help on using the repository browser.