regenerate man pages
[Samba.git] / docs / htmldocs / smbd.8.html
blob4be8a257d35a82250ecb3526a52790efd7986433
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
2 <HTML
3 ><HEAD
4 ><TITLE
5 >smbd</TITLE
6 ><META
7 NAME="GENERATOR"
8 CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+
9 "></HEAD
10 ><BODY
11 CLASS="REFENTRY"
12 BGCOLOR="#FFFFFF"
13 TEXT="#000000"
14 LINK="#0000FF"
15 VLINK="#840084"
16 ALINK="#0000FF"
17 ><H1
18 ><A
19 NAME="SMBD">smbd</H1
20 ><DIV
21 CLASS="REFNAMEDIV"
22 ><A
23 NAME="AEN5"
24 ></A
25 ><H2
26 >Name</H2
27 >smbd&nbsp;--&nbsp;server to provide SMB/CIFS services to clients</DIV
28 ><DIV
29 CLASS="REFSYNOPSISDIV"
30 ><A
31 NAME="AEN8"><H2
32 >Synopsis</H2
33 ><P
34 ><B
35 CLASS="COMMAND"
36 >smbd</B
37 > [-D] [-F] [-S] [-i] [-h] [-V] [-b] [-d &#60;debug level&#62;] [-l &#60;log directory&#62;] [-p &#60;port number&#62;] [-O &#60;socket option&#62;] [-s &#60;configuration file&#62;]</P
38 ></DIV
39 ><DIV
40 CLASS="REFSECT1"
41 ><A
42 NAME="AEN23"
43 ></A
44 ><H2
45 >DESCRIPTION</H2
46 ><P
47 >This program is part of the Samba suite.</P
48 ><P
49 ><B
50 CLASS="COMMAND"
51 >smbd</B
52 > is the server daemon that
53 provides filesharing and printing services to Windows clients.
54 The server provides filespace and printer services to
55 clients using the SMB (or CIFS) protocol. This is compatible
56 with the LanManager protocol, and can service LanManager
57 clients. These include MSCLIENT 3.0 for DOS, Windows for
58 Workgroups, Windows 95/98/ME, Windows NT, Windows 2000,
59 OS/2, DAVE for Macintosh, and smbfs for Linux.</P
60 ><P
61 >An extensive description of the services that the
62 server can provide is given in the man page for the
63 configuration file controlling the attributes of those
64 services (see <A
65 HREF="smb.conf.5.html"
66 TARGET="_top"
67 ><TT
68 CLASS="FILENAME"
69 >smb.conf(5)
70 </TT
71 ></A
72 >. This man page will not describe the
73 services, but will concentrate on the administrative aspects
74 of running the server.</P
75 ><P
76 >Please note that there are significant security
77 implications to running this server, and the <A
78 HREF="smb.conf.5.html"
79 TARGET="_top"
80 ><TT
81 CLASS="FILENAME"
82 >smb.conf(5)</TT
83 ></A
85 manpage should be regarded as mandatory reading before
86 proceeding with installation.</P
87 ><P
88 >A session is created whenever a client requests one.
89 Each client gets a copy of the server for each session. This
90 copy then services all connections made by the client during
91 that session. When all connections from its client are closed,
92 the copy of the server for that client terminates.</P
93 ><P
94 >The configuration file, and any files that it includes,
95 are automatically reloaded every minute, if they change. You
96 can force a reload by sending a SIGHUP to the server. Reloading
97 the configuration file will not affect connections to any service
98 that is already established. Either the user will have to
99 disconnect from the service, or <B
100 CLASS="COMMAND"
101 >smbd</B
102 > killed and restarted.</P
103 ></DIV
104 ><DIV
105 CLASS="REFSECT1"
107 NAME="AEN37"
108 ></A
109 ><H2
110 >OPTIONS</H2
112 ></P
113 ><DIV
114 CLASS="VARIABLELIST"
115 ><DL
116 ><DT
117 >-D</DT
118 ><DD
120 >If specified, this parameter causes
121 the server to operate as a daemon. That is, it detaches
122 itself and runs in the background, fielding requests
123 on the appropriate port. Operating the server as a
124 daemon is the recommended way of running <B
125 CLASS="COMMAND"
126 >smbd</B
127 > for
128 servers that provide more than casual use file and
129 print services. This switch is assumed if <B
130 CLASS="COMMAND"
131 >smbd
133 > is executed on the command line of a shell.
135 ></DD
136 ><DT
137 >-F</DT
138 ><DD
140 >If specified, this parameter causes
141 the main <B
142 CLASS="COMMAND"
143 >smbd</B
144 > process to not daemonize,
145 i.e. double-fork and disassociate with the terminal.
146 Child processes are still created as normal to service
147 each connection request, but the main process does not
148 exit. This operation mode is suitable for running
150 CLASS="COMMAND"
151 >smbd</B
152 > under process supervisors such
153 as <B
154 CLASS="COMMAND"
155 >supervise</B
156 > and <B
157 CLASS="COMMAND"
158 >svscan</B
160 from Daniel J. Bernstein's <B
161 CLASS="COMMAND"
162 >daemontools</B
164 package, or the AIX process monitor.
166 ></DD
167 ><DT
168 >-S</DT
169 ><DD
171 >If specified, this parameter causes
173 CLASS="COMMAND"
174 >smbd</B
175 > to log to standard output rather
176 than a file.</P
177 ></DD
178 ><DT
179 >-i</DT
180 ><DD
182 >If this parameter is specified it causes the
183 server to run "interactively", not as a daemon, even if the
184 server is executed on the command line of a shell. Setting this
185 parameter negates the implicit deamon mode when run from the
186 command line. <B
187 CLASS="COMMAND"
188 >smbd</B
189 > also logs to standard
190 output, as if the <B
191 CLASS="COMMAND"
192 >-S</B
193 > parameter had been
194 given.
196 ></DD
197 ><DT
198 >-h</DT
199 ><DD
201 >Prints the help information (usage)
202 for <B
203 CLASS="COMMAND"
204 >smbd</B
205 >.</P
206 ></DD
207 ><DT
208 >-V</DT
209 ><DD
211 >Prints the version number for
213 CLASS="COMMAND"
214 >smbd</B
215 >.</P
216 ></DD
217 ><DT
218 >-b</DT
219 ><DD
221 >Prints information about how
222 Samba was built.</P
223 ></DD
224 ><DT
225 >-d &#60;debug level&#62;</DT
226 ><DD
228 ><TT
229 CLASS="REPLACEABLE"
231 >debuglevel</I
232 ></TT
233 > is an integer
234 from 0 to 10. The default value if this parameter is
235 not specified is zero.</P
237 >The higher this value, the more detail will be
238 logged to the log files about the activities of the
239 server. At level 0, only critical errors and serious
240 warnings will be logged. Level 1 is a reasonable level for
241 day to day running - it generates a small amount of
242 information about operations carried out.</P
244 >Levels above 1 will generate considerable
245 amounts of log data, and should only be used when
246 investigating a problem. Levels above 3 are designed for
247 use only by developers and generate HUGE amounts of log
248 data, most of which is extremely cryptic.</P
250 >Note that specifying this parameter here will
251 override the <A
252 HREF="smb.conf.5.html#loglevel"
253 TARGET="_top"
254 >log
255 level</A
256 > parameter in the <A
257 HREF="smb.conf.5.html"
258 TARGET="_top"
259 > <TT
260 CLASS="FILENAME"
261 >smb.conf(5)</TT
262 ></A
263 > file.</P
264 ></DD
265 ><DT
266 >-l &#60;log directory&#62;</DT
267 ><DD
269 >If specified,
271 CLASS="REPLACEABLE"
273 >log directory</I
274 ></TT
276 specifies a log directory into which the "log.smbd" log
277 file will be created for informational and debug
278 messages from the running server. The log
279 file generated is never removed by the server although
280 its size may be controlled by the <A
281 HREF="smb.conf.5.html#maxlogsize"
282 TARGET="_top"
283 >max log size</A
285 option in the <A
286 HREF="smb.conf.5.html"
287 TARGET="_top"
288 ><TT
289 CLASS="FILENAME"
290 > smb.conf(5)</TT
291 ></A
292 > file. <I
293 CLASS="EMPHASIS"
294 >Beware:</I
296 If the directory specified does not exist, <B
297 CLASS="COMMAND"
298 >smbd</B
300 will log to the default debug log location defined at compile time.
303 >The default log directory is specified at
304 compile time.</P
305 ></DD
306 ><DT
307 >-O &#60;socket options&#62;</DT
308 ><DD
310 >See the <A
311 HREF="smb.conf.5.html#socketoptions"
312 TARGET="_top"
313 >socket options</A
315 parameter in the <A
316 HREF="smb.conf.5.html"
317 TARGET="_top"
318 ><TT
319 CLASS="FILENAME"
320 >smb.conf(5)
321 </TT
322 ></A
323 > file for details.</P
324 ></DD
325 ><DT
326 >-p &#60;port number&#62;</DT
327 ><DD
329 ><TT
330 CLASS="REPLACEABLE"
332 >port number</I
333 ></TT
334 > is a positive integer
335 value. The default value if this parameter is not
336 specified is 139.</P
338 >This number is the port number that will be
339 used when making connections to the server from client
340 software. The standard (well-known) port number for the
341 SMB over TCP is 139, hence the default. If you wish to
342 run the server as an ordinary user rather than
343 as root, most systems will require you to use a port
344 number greater than 1024 - ask your system administrator
345 for help if you are in this situation.</P
347 >In order for the server to be useful by most
348 clients, should you configure it on a port other
349 than 139, you will require port redirection services
350 on port 139, details of which are outlined in rfc1002.txt
351 section 4.3.5.</P
353 >This parameter is not normally specified except
354 in the above situation.</P
355 ></DD
356 ><DT
357 >-s &#60;configuration file&#62;</DT
358 ><DD
360 >The file specified contains the
361 configuration details required by the server. The
362 information in this file includes server-specific
363 information such as what printcap file to use, as well
364 as descriptions of all the services that the server is
365 to provide. See <A
366 HREF="smb.conf.5.html"
367 TARGET="_top"
368 ><TT
369 CLASS="FILENAME"
370 > smb.conf(5)</TT
371 ></A
372 > for more information.
373 The default configuration file name is determined at
374 compile time.</P
375 ></DD
376 ></DL
377 ></DIV
378 ></DIV
379 ><DIV
380 CLASS="REFSECT1"
382 NAME="AEN123"
383 ></A
384 ><H2
385 >FILES</H2
387 ></P
388 ><DIV
389 CLASS="VARIABLELIST"
390 ><DL
391 ><DT
392 ><TT
393 CLASS="FILENAME"
394 >/etc/inetd.conf</TT
395 ></DT
396 ><DD
398 >If the server is to be run by the
400 CLASS="COMMAND"
401 >inetd</B
402 > meta-daemon, this file
403 must contain suitable startup information for the
404 meta-daemon. See the <A
405 HREF="UNIX_INSTALL.html"
406 TARGET="_top"
407 >UNIX_INSTALL.html</A
409 document for details.
411 ></DD
412 ><DT
413 ><TT
414 CLASS="FILENAME"
415 >/etc/rc</TT
416 ></DT
417 ><DD
419 >or whatever initialization script your
420 system uses).</P
422 >If running the server as a daemon at startup,
423 this file will need to contain an appropriate startup
424 sequence for the server. See the <A
425 HREF="UNIX_INSTALL.html"
426 TARGET="_top"
427 >UNIX_INSTALL.html</A
429 document for details.</P
430 ></DD
431 ><DT
432 ><TT
433 CLASS="FILENAME"
434 >/etc/services</TT
435 ></DT
436 ><DD
438 >If running the server via the
439 meta-daemon <B
440 CLASS="COMMAND"
441 >inetd</B
442 >, this file
443 must contain a mapping of service name (e.g., netbios-ssn)
444 to service port (e.g., 139) and protocol type (e.g., tcp).
445 See the <A
446 HREF="UNIX_INSTALL.html"
447 TARGET="_top"
448 >UNIX_INSTALL.html</A
450 document for details.</P
451 ></DD
452 ><DT
453 ><TT
454 CLASS="FILENAME"
455 >/usr/local/samba/lib/smb.conf</TT
456 ></DT
457 ><DD
459 >This is the default location of the
461 HREF="smb.conf.5.html"
462 TARGET="_top"
463 ><TT
464 CLASS="FILENAME"
465 >smb.conf</TT
466 ></A
468 server configuration file. Other common places that systems
469 install this file are <TT
470 CLASS="FILENAME"
471 >/usr/samba/lib/smb.conf</TT
473 and <TT
474 CLASS="FILENAME"
475 >/etc/smb.conf</TT
476 >.</P
478 >This file describes all the services the server
479 is to make available to clients. See <A
480 HREF="smb.conf.5.html"
481 TARGET="_top"
482 > <TT
483 CLASS="FILENAME"
484 >smb.conf(5)</TT
485 ></A
486 > for more information.</P
487 ></DD
488 ></DL
489 ></DIV
490 ></DIV
491 ><DIV
492 CLASS="REFSECT1"
494 NAME="AEN159"
495 ></A
496 ><H2
497 >LIMITATIONS</H2
499 >On some systems <B
500 CLASS="COMMAND"
501 >smbd</B
502 > cannot change uid back
503 to root after a setuid() call. Such systems are called
504 trapdoor uid systems. If you have such a system,
505 you will be unable to connect from a client (such as a PC) as
506 two different users at once. Attempts to connect the
507 second user will result in access denied or
508 similar.</P
509 ></DIV
510 ><DIV
511 CLASS="REFSECT1"
513 NAME="AEN163"
514 ></A
515 ><H2
516 >ENVIRONMENT VARIABLES</H2
518 ></P
519 ><DIV
520 CLASS="VARIABLELIST"
521 ><DL
522 ><DT
523 ><TT
524 CLASS="ENVAR"
525 >PRINTER</TT
526 ></DT
527 ><DD
529 >If no printer name is specified to
530 printable services, most systems will use the value of
531 this variable (or <TT
532 CLASS="CONSTANT"
533 >lp</TT
534 > if this variable is
535 not defined) as the name of the printer to use. This
536 is not specific to the server, however.</P
537 ></DD
538 ></DL
539 ></DIV
540 ></DIV
541 ><DIV
542 CLASS="REFSECT1"
544 NAME="AEN172"
545 ></A
546 ><H2
547 >PAM INTERACTION</H2
549 >Samba uses PAM for authentication (when presented with a plaintext
550 password), for account checking (is this account disabled?) and for
551 session management. The degree too which samba supports PAM is restricted
552 by the limitations of the SMB protocol and the
554 HREF="smb.conf.5.html#OBEYPAMRESRICTIONS"
555 TARGET="_top"
556 >obey pam restricions</A
558 smb.conf paramater. When this is set, the following restrictions apply:
561 ></P
562 ><UL
563 ><LI
566 CLASS="EMPHASIS"
567 >Account Validation</I
568 >: All accesses to a
569 samba server are checked
570 against PAM to see if the account is vaild, not disabled and is permitted to
571 login at this time. This also applies to encrypted logins.
573 ></LI
574 ><LI
577 CLASS="EMPHASIS"
578 >Session Management</I
579 >: When not using share
580 level secuirty, users must pass PAM's session checks before access
581 is granted. Note however, that this is bypassed in share level secuirty.
582 Note also that some older pam configuration files may need a line
583 added for session support.
585 ></LI
586 ></UL
587 ></DIV
588 ><DIV
589 CLASS="REFSECT1"
591 NAME="AEN183"
592 ></A
593 ><H2
594 >VERSION</H2
596 >This man page is correct for version 3.0 of
597 the Samba suite.</P
598 ></DIV
599 ><DIV
600 CLASS="REFSECT1"
602 NAME="AEN186"
603 ></A
604 ><H2
605 >DIAGNOSTICS</H2
607 >Most diagnostics issued by the server are logged
608 in a specified log file. The log file name is specified
609 at compile time, but may be overridden on the command line.</P
611 >The number and nature of diagnostics available depends
612 on the debug level used by the server. If you have problems, set
613 the debug level to 3 and peruse the log files.</P
615 >Most messages are reasonably self-explanatory. Unfortunately,
616 at the time this man page was created, there are too many diagnostics
617 available in the source code to warrant describing each and every
618 diagnostic. At this stage your best bet is still to grep the
619 source code and inspect the conditions that gave rise to the
620 diagnostics you are seeing.</P
621 ></DIV
622 ><DIV
623 CLASS="REFSECT1"
625 NAME="AEN191"
626 ></A
627 ><H2
628 >SIGNALS</H2
630 >Sending the <B
631 CLASS="COMMAND"
632 >smbd</B
633 > a SIGHUP will cause it to
634 reload its <TT
635 CLASS="FILENAME"
636 >smb.conf</TT
637 > configuration
638 file within a short period of time.</P
640 >To shut down a user's <B
641 CLASS="COMMAND"
642 >smbd</B
643 > process it is recommended
644 that <B
645 CLASS="COMMAND"
646 >SIGKILL (-9)</B
647 > <I
648 CLASS="EMPHASIS"
649 >NOT</I
651 be used, except as a last resort, as this may leave the shared
652 memory area in an inconsistent state. The safe way to terminate
653 an <B
654 CLASS="COMMAND"
655 >smbd</B
656 > is to send it a SIGTERM (-15) signal and wait for
657 it to die on its own.</P
659 >The debug log level of <B
660 CLASS="COMMAND"
661 >smbd</B
662 > may be raised
663 or lowered using <A
664 HREF="smbcontrol.1.html"
665 TARGET="_top"
667 CLASS="COMMAND"
668 >smbcontrol(1)
670 ></A
671 > program (SIGUSR[1|2] signals are no longer used in
672 Samba 2.2). This is to allow transient problems to be diagnosed,
673 whilst still running at a normally low log level.</P
675 >Note that as the signal handlers send a debug write,
676 they are not re-entrant in <B
677 CLASS="COMMAND"
678 >smbd</B
679 >. This you should wait until
681 CLASS="COMMAND"
682 >smbd</B
683 > is in a state of waiting for an incoming SMB before
684 issuing them. It is possible to make the signal handlers safe
685 by un-blocking the signals before the select call and re-blocking
686 them after, however this would affect performance.</P
687 ></DIV
688 ><DIV
689 CLASS="REFSECT1"
691 NAME="AEN208"
692 ></A
693 ><H2
694 >SEE ALSO</H2
696 >hosts_access(5), <B
697 CLASS="COMMAND"
698 >inetd(8)</B
701 HREF="nmbd.8.html"
702 TARGET="_top"
704 CLASS="COMMAND"
705 >nmbd(8)</B
706 ></A
709 HREF="smb.conf.5.html"
710 TARGET="_top"
711 ><TT
712 CLASS="FILENAME"
713 >smb.conf(5)</TT
716 >, <A
717 HREF="smbclient.1.html"
718 TARGET="_top"
720 CLASS="COMMAND"
721 >smbclient(1)
723 ></A
724 >, <A
725 HREF="testparm.1.html"
726 TARGET="_top"
728 CLASS="COMMAND"
729 > testparm(1)</B
730 ></A
731 >, <A
732 HREF="testprns.1.html"
733 TARGET="_top"
734 > <B
735 CLASS="COMMAND"
736 >testprns(1)</B
737 ></A
738 >, and the Internet RFC's
740 CLASS="FILENAME"
741 >rfc1001.txt</TT
742 >, <TT
743 CLASS="FILENAME"
744 >rfc1002.txt</TT
746 In addition the CIFS (formerly SMB) specification is available
747 as a link from the Web page <A
748 HREF="http://samba.org/cifs/"
749 TARGET="_top"
751 http://samba.org/cifs/</A
752 >.</P
753 ></DIV
754 ><DIV
755 CLASS="REFSECT1"
757 NAME="AEN225"
758 ></A
759 ><H2
760 >AUTHOR</H2
762 >The original Samba software and related utilities
763 were created by Andrew Tridgell. Samba is now developed
764 by the Samba Team as an Open Source project similar
765 to the way the Linux kernel is developed.</P
767 >The original Samba man pages were written by Karl Auer.
768 The man page sources were converted to YODL format (another
769 excellent piece of Open Source software, available at
771 HREF="ftp://ftp.icce.rug.nl/pub/unix/"
772 TARGET="_top"
773 > ftp://ftp.icce.rug.nl/pub/unix/</A
774 >) and updated for the Samba 2.0
775 release by Jeremy Allison. The conversion to DocBook for
776 Samba 2.2 was done by Gerald Carter</P
777 ></DIV
778 ></BODY
779 ></HTML