1SMBD(8)                   System Administration tools                  SMBD(8)
2
3
4

NAME

6       smbd - server to provide SMB/CIFS services to clients
7

SYNOPSIS

9       smbd [-D|--daemon] [-F|--foreground] [-S|--log-stdout]
10        [-i|--interactive] [-V] [-b|--build-options] [-d <debug level>]
11        [-l|--log-basename <log directory>] [-p <port number(s)>]
12        [-P <profiling level>] [-s <configuration file>] [--no-process-group]
13

DESCRIPTION

15       This program is part of the samba(7) suite.
16
17       smbd is the server daemon that provides filesharing and printing
18       services to Windows clients. The server provides filespace and printer
19       services to clients using the SMB (or CIFS) protocol. This is
20       compatible with the LanManager protocol, and can service LanManager
21       clients. These include MSCLIENT 3.0 for DOS, Windows for Workgroups,
22       Windows 95/98/ME, Windows NT, Windows 2000, OS/2, DAVE for Macintosh,
23       and smbfs for Linux.
24
25       An extensive description of the services that the server can provide is
26       given in the man page for the configuration file controlling the
27       attributes of those services (see smb.conf(5). This man page will not
28       describe the services, but will concentrate on the administrative
29       aspects of running the server.
30
31       Please note that there are significant security implications to running
32       this server, and the smb.conf(5) manual page should be regarded as
33       mandatory reading before proceeding with installation.
34
35       A session is created whenever a client requests one. Each client gets a
36       copy of the server for each session. This copy then services all
37       connections made by the client during that session. When all
38       connections from its client are closed, the copy of the server for that
39       client terminates.
40
41       The configuration file, and any files that it includes, are
42       automatically reloaded every minute, if they change. You can force a
43       reload by sending a SIGHUP to the server. Reloading the configuration
44       file will not affect connections to any service that is already
45       established. Either the user will have to disconnect from the service,
46       or smbd killed and restarted.
47

OPTIONS

49       -D|--daemon
50           If specified, this parameter causes the server to operate as a
51           daemon. That is, it detaches itself and runs in the background,
52           fielding requests on the appropriate port. Operating the server as
53           a daemon is the recommended way of running smbd for servers that
54           provide more than casual use file and print services. This switch
55           is assumed if smbd is executed on the command line of a shell.
56
57       -F|--foreground
58           If specified, this parameter causes the main smbd process to not
59           daemonize, i.e. double-fork and disassociate with the terminal.
60           Child processes are still created as normal to service each
61           connection request, but the main process does not exit. This
62           operation mode is suitable for running smbd under process
63           supervisors such as supervise and svscan from Daniel J. Bernstein's
64           daemontools package, or the AIX process monitor.
65
66       -S|--log-stdout
67           If specified, this parameter causes smbd to log to standard output
68           rather than a file.
69
70       -i|--interactive
71           If this parameter is specified it causes the server to run
72           "interactively", not as a daemon, even if the server is executed on
73           the command line of a shell. Setting this parameter negates the
74           implicit daemon mode when run from the command line.  smbd will
75           only accept one connection and terminate. It will also log to
76           standard output, as if the -S parameter had been given.
77
78       -d|--debuglevel=level
79           level is an integer from 0 to 10. The default value if this
80           parameter is not specified is 0.
81
82           The higher this value, the more detail will be logged to the log
83           files about the activities of the server. At level 0, only critical
84           errors and serious warnings will be logged. Level 1 is a reasonable
85           level for day-to-day running - it generates a small amount of
86           information about operations carried out.
87
88           Levels above 1 will generate considerable amounts of log data, and
89           should only be used when investigating a problem. Levels above 3
90           are designed for use only by developers and generate HUGE amounts
91           of log data, most of which is extremely cryptic.
92
93           Note that specifying this parameter here will override the log
94           level parameter in the smb.conf file.
95
96       -V|--version
97           Prints the program version number.
98
99       -s|--configfile=<configuration file>
100           The file specified contains the configuration details required by
101           the server. The information in this file includes server-specific
102           information such as what printcap file to use, as well as
103           descriptions of all the services that the server is to provide. See
104           smb.conf for more information. The default configuration file name
105           is determined at compile time.
106
107       -l|--log-basename=logdirectory
108           Base directory name for log/debug files. The extension ".progname"
109           will be appended (e.g. log.smbclient, log.smbd, etc...). The log
110           file is never removed by the client.
111
112       --option=<name>=<value>
113           Set the smb.conf(5) option "<name>" to value "<value>" from the
114           command line. This overrides compiled-in defaults and options read
115           from the configuration file.
116
117       -?|--help
118           Print a summary of command line options.
119
120       --usage
121           Display brief usage message.
122
123       --no-process-group
124           Do not create a new process group for smbd.
125
126       -b|--build-options
127           Prints information about how Samba was built.
128
129       -p|--port<port number(s)>
130           port number(s) is a space or comma-separated list of TCP ports smbd
131           should listen on. The default value is taken from the ports
132           parameter in smb.conf
133
134           The default ports are 139 (used for SMB over NetBIOS over TCP) and
135           port 445 (used for plain SMB over TCP).
136
137       -P|--profiling-level<profiling level>
138           profiling level is a number specifying the level of profiling data
139           to be collected. 0 turns off profiling, 1 turns on counter
140           profiling only, 2 turns on complete profiling, and 3 resets all
141           profiling data.
142

FILES

144       /etc/inetd.conf
145           If the server is to be run by the inetd meta-daemon, this file must
146           contain suitable startup information for the meta-daemon.
147
148       /etc/rc
149           or whatever initialization script your system uses).
150
151           If running the server as a daemon at startup, this file will need
152           to contain an appropriate startup sequence for the server.
153
154       /etc/services
155           If running the server via the meta-daemon inetd, this file must
156           contain a mapping of service name (e.g., netbios-ssn) to service
157           port (e.g., 139) and protocol type (e.g., tcp).
158
159       /usr/local/samba/lib/smb.conf
160           This is the default location of the smb.conf(5) server
161           configuration file. Other common places that systems install this
162           file are /usr/samba/lib/smb.conf and /etc/samba/smb.conf.
163
164           This file describes all the services the server is to make
165           available to clients. See smb.conf(5) for more information.
166

LIMITATIONS

168       On some systems smbd cannot change uid back to root after a setuid()
169       call. Such systems are called trapdoor uid systems. If you have such a
170       system, you will be unable to connect from a client (such as a PC) as
171       two different users at once. Attempts to connect the second user will
172       result in access denied or similar.
173

ENVIRONMENT VARIABLES

175       PRINTER
176           If no printer name is specified to printable services, most systems
177           will use the value of this variable (or lp if this variable is not
178           defined) as the name of the printer to use. This is not specific to
179           the server, however.
180

PAM INTERACTION

182       Samba uses PAM for authentication (when presented with a plaintext
183       password), for account checking (is this account disabled?) and for
184       session management. The degree too which samba supports PAM is
185       restricted by the limitations of the SMB protocol and the obey pam
186       restrictions smb.conf(5) parameter. When this is set, the following
187       restrictions apply:
188
189              ·   Account Validation: All accesses to a samba server are
190                  checked against PAM to see if the account is valid, not
191                  disabled and is permitted to login at this time. This also
192                  applies to encrypted logins.
193
194              ·   Session Management: When not using share level security,
195                  users must pass PAM's session checks before access is
196                  granted. Note however, that this is bypassed in share level
197                  security. Note also that some older pam configuration files
198                  may need a line added for session support.
199

VERSION

201       This man page is part of version 4.9.8 of the Samba suite.
202

DIAGNOSTICS

204       Most diagnostics issued by the server are logged in a specified log
205       file. The log file name is specified at compile time, but may be
206       overridden on the command line.
207
208       The number and nature of diagnostics available depends on the debug
209       level used by the server. If you have problems, set the debug level to
210       3 and peruse the log files.
211
212       Most messages are reasonably self-explanatory. Unfortunately, at the
213       time this man page was created, there are too many diagnostics
214       available in the source code to warrant describing each and every
215       diagnostic. At this stage your best bet is still to grep the source
216       code and inspect the conditions that gave rise to the diagnostics you
217       are seeing.
218

TDB FILES

220       Samba stores it's data in several TDB (Trivial Database) files, usually
221       located in /var/lib/samba.
222
223       (*) information persistent across restarts (but not necessarily
224       important to backup).
225
226       account_policy.tdb*
227           NT account policy settings such as pw expiration, etc...
228
229       brlock.tdb
230           byte range locks
231
232       browse.dat
233           browse lists
234
235       gencache.tdb
236           generic caching db
237
238       group_mapping.tdb*
239           group mapping information
240
241       locking.tdb
242           share modes & oplocks
243
244       login_cache.tdb*
245           bad pw attempts
246
247       messages.tdb
248           Samba messaging system
249
250       netsamlogon_cache.tdb*
251           cache of user net_info_3 struct from net_samlogon() request (as a
252           domain member)
253
254       ntdrivers.tdb*
255           installed printer drivers
256
257       ntforms.tdb*
258           installed printer forms
259
260       ntprinters.tdb*
261           installed printer information
262
263       printing/
264           directory containing tdb per print queue of cached lpq output
265
266       registry.tdb
267           Windows registry skeleton (connect via regedit.exe)
268
269       smbXsrv_session_global.tdb
270           session information (e.g. support for 'utmp = yes')
271
272       smbXsrv_tcon_global.tdb
273           share connections (used to enforce max connections, etc...)
274
275       smbXsrv_open_global.tdb
276           open file handles (used durable handles, etc...)
277
278       share_info.tdb*
279           share acls
280
281       winbindd_cache.tdb
282           winbindd's cache of user lists, etc...
283
284       winbindd_idmap.tdb*
285           winbindd's local idmap db
286
287       wins.dat*
288           wins database when 'wins support = yes'
289

SIGNALS

291       Sending the smbd a SIGHUP will cause it to reload its smb.conf
292       configuration file within a short period of time.
293
294       To shut down a user's smbd process it is recommended that SIGKILL (-9)
295       NOT be used, except as a last resort, as this may leave the shared
296       memory area in an inconsistent state. The safe way to terminate an smbd
297       is to send it a SIGTERM (-15) signal and wait for it to die on its own.
298
299       The debug log level of smbd may be raised or lowered using
300       smbcontrol(1) program (SIGUSR[1|2] signals are no longer used since
301       Samba 2.2). This is to allow transient problems to be diagnosed, whilst
302       still running at a normally low log level.
303
304       Note that as the signal handlers send a debug write, they are not
305       re-entrant in smbd. This you should wait until smbd is in a state of
306       waiting for an incoming SMB before issuing them. It is possible to make
307       the signal handlers safe by un-blocking the signals before the select
308       call and re-blocking them after, however this would affect performance.
309

SEE ALSO

311       hosts_access(5), inetd(8), nmbd(8), smb.conf(5), smbclient(1),
312       testparm(1), and the Internet RFC's rfc1001.txt, rfc1002.txt. In
313       addition the CIFS (formerly SMB) specification is available as a link
314       from the Web page https://www.samba.org/cifs/.
315

AUTHOR

317       The original Samba software and related utilities were created by
318       Andrew Tridgell. Samba is now developed by the Samba Team as an Open
319       Source project similar to the way the Linux kernel is developed.
320
321
322
323Samba 4.9.8                       05/14/2019                           SMBD(8)
Impressum