1 .TH SMB.CONF 5 "08 Dec 1998" "smb.conf 2.0.0beta3"
4 smb\&.conf \- The configuration file for the Samba suite
8 \fBsmb\&.conf\fP The \fBsmb\&.conf\fP file is a configuration file for the
9 Samba suite\&. \fBsmb\&.conf\fP contains runtime configuration information
10 for the Samba programs\&. The \fBsmb\&.conf\fP file is designed to be
11 configured and administered by the \fBswat (8)\fP
12 program\&. The complete description of the file format and possible
13 parameters held within are here for reference purposes\&.
17 The file consists of sections and parameters\&. A section begins with
18 the name of the section in square brackets and continues until the
19 next section begins\&. Sections contain parameters of the form
21 \f(CW\'name = value\'\fP
23 The file is line-based - that is, each newline-terminated line
24 represents either a comment, a section name or a parameter\&.
26 Section and parameter names are not case sensitive\&.
28 Only the first equals sign in a parameter is significant\&. Whitespace
29 before or after the first equals sign is discarded\&. Leading, trailing
30 and internal whitespace in section and parameter names is
31 irrelevant\&. Leading and trailing whitespace in a parameter value is
32 discarded\&. Internal whitespace within a parameter value is retained
35 Any line beginning with a semicolon (\';\') or a hash (\'#\') character is
36 ignored, as are lines containing only whitespace\&.
38 Any line ending in a \f(CW\'\e\'\fP is "continued" on the next line in the
39 customary UNIX fashion\&.
41 The values following the equals sign in parameters are all either a
42 string (no quotes needed) or a boolean, which may be given as yes/no,
43 0/1 or true/false\&. Case is not significant in boolean values, but is
44 preserved in string values\&. Some items such as create modes are
47 .SH "SECTION DESCRIPTIONS"
49 Each section in the configuration file (except for the
50 \fB[global]\fP section) describes a shared resource (known
51 as a \fI"share"\fP)\&. The section name is the name of the shared resource
52 and the parameters within the section define the shares attributes\&.
54 There are three special sections, \fB[global]\fP,
55 \fB[homes]\fP and \fB[printers]\fP, which are
56 described under \fB\'special sections\'\fP\&. The
57 following notes apply to ordinary section descriptions\&.
59 A share consists of a directory to which access is being given plus
60 a description of the access rights which are granted to the user of
61 the service\&. Some housekeeping options are also specifiable\&.
63 Sections are either filespace services (used by the client as an
64 extension of their native file systems) or printable services (used by
65 the client to access print services on the host running the server)\&.
67 Sections may be designated \fBguest\fP services, in which
68 case no password is required to access them\&. A specified UNIX
69 \fBguest account\fP is used to define access
70 privileges in this case\&.
72 Sections other than guest services will require a password to access
73 them\&. The client provides the username\&. As older clients only provide
74 passwords and not usernames, you may specify a list of usernames to
75 check against the password using the \fB"user="\fP option in
76 the share definition\&. For modern clients such as Windows 95/98 and
77 Windows NT, this should not be necessary\&.
79 Note that the access rights granted by the server are masked by the
80 access rights granted to the specified or guest UNIX user by the host
81 system\&. The server does not grant more access than the host system
84 The following sample section defines a file space share\&. The user has
85 write access to the path \f(CW/home/bar\fP\&. The share is accessed via
102 The following sample section defines a printable share\&. The share
103 is readonly, but printable\&. That is, the only write access permitted
104 is via calls to open, write to and close a spool file\&. The
105 \fB\'guest ok\'\fP parameter means access will be permitted
106 as the default guest user (specified elsewhere):
113 path = /usr/spool/public
122 .SH "SPECIAL SECTIONS"
125 .IP "\fBThe [global] section\fP"
127 Parameters in this section apply to the server as a whole, or are
128 defaults for sections which do not specifically define certain
129 items\&. See the notes under \fB\'PARAMETERS\'\fP for more
132 .IP "\fBThe [homes] section\fP"
134 If a section called \f(CW\'homes\'\fP is included in the configuration file,
135 services connecting clients to their home directories can be created
136 on the fly by the server\&.
138 When the connection request is made, the existing sections are
139 scanned\&. If a match is found, it is used\&. If no match is found, the
140 requested section name is treated as a user name and looked up in the
141 local password file\&. If the name exists and the correct password has
142 been given, a share is created by cloning the [homes] section\&.
144 Some modifications are then made to the newly created share:
148 The share name is changed from \f(CW\'homes\'\fP to the located
152 If no path was given, the path is set to the user\'s home
156 If you decide to use a \fBpath=\fP line in your [homes]
157 section then you may find it useful to use the \fB%S\fP
158 macro\&. For example :
160 \f(CWpath=/data/pchome/%S\fP
162 would be useful if you have different home directories for your PCs
163 than for UNIX access\&.
165 This is a fast and simple way to give a large number of clients access
166 to their home directories with a minimum of fuss\&.
168 A similar process occurs if the requested section name is \f(CW"homes"\fP,
169 except that the share name is not changed to that of the requesting
170 user\&. This method of using the [homes] section works well if different
171 users share a client PC\&.
173 The [homes] section can specify all the parameters a normal service
174 section can specify, though some make more sense than others\&. The
175 following is a typical and suitable [homes] section:
188 An important point is that if guest access is specified in the [homes]
189 section, all home directories will be visible to all clients
190 \fBwithout a password\fP\&. In the very unlikely event that this is
191 actually desirable, it would be wise to also specify \fBread only
194 Note that the \fBbrowseable\fP flag for auto home
195 directories will be inherited from the global browseable flag, not the
196 [homes] browseable flag\&. This is useful as it means setting
197 browseable=no in the [homes] section will hide the [homes] share but
198 make any auto home directories visible\&.
200 .IP "\fBThe [printers] section\fP"
202 This section works like \fB[homes]\fP, but for printers\&.
204 If a [printers] section occurs in the configuration file, users are
205 able to connect to any printer specified in the local host\'s printcap
208 When a connection request is made, the existing sections are
209 scanned\&. If a match is found, it is used\&. If no match is found, but a
210 \fB[homes]\fP section exists, it is used as described
211 above\&. Otherwise, the requested section name is treated as a printer
212 name and the appropriate printcap file is scanned to see if the
213 requested section name is a valid printer share name\&. If a match is
214 found, a new printer share is created by cloning the [printers]
217 A few modifications are then made to the newly created share:
221 The share name is set to the located printer name
224 If no printer name was given, the printer name is set to the
228 If the share does not permit guest access and no username was
229 given, the username is set to the located printer name\&.
232 Note that the [printers] service MUST be printable - if you specify
233 otherwise, the server will refuse to load the configuration file\&.
235 Typically the path specified would be that of a world-writeable spool
236 directory with the sticky bit set on it\&. A typical [printers] entry
237 would look like this:
244 path = /usr/spool/public
253 All aliases given for a printer in the printcap file are legitimate
254 printer names as far as the server is concerned\&. If your printing
255 subsystem doesn\'t work like that, you will have to set up a
256 pseudo-printcap\&. This is a file consisting of one or more lines like
262 alias|alias|alias|alias\&.\&.\&.
267 Each alias should be an acceptable printer name for your printing
268 subsystem\&. In the \fB[global]\fP section, specify the new
269 file as your printcap\&. The server will then only recognize names
270 found in your pseudo-printcap, which of course can contain whatever
271 aliases you like\&. The same technique could be used simply to limit
272 access to a subset of your local printers\&.
274 An alias, by the way, is defined as any component of the first entry
275 of a printcap record\&. Records are separated by newlines, components
276 (if there are more than one) are separated by vertical bar symbols
279 NOTE: On SYSV systems which use lpstat to determine what printers are
280 defined on the system you may be able to use \fB"printcap name =
281 lpstat"\fP to automatically obtain a list of
282 printers\&. See the \fB"printcap name"\fP option for
288 Parameters define the specific attributes of sections\&.
290 Some parameters are specific to the \fB[global]\fP section
291 (e\&.g\&., \fBsecurity\fP)\&. Some parameters are usable in
292 all sections (e\&.g\&., \fBcreate mode\fP)\&. All others are
293 permissible only in normal sections\&. For the purposes of the following
294 descriptions the \fB[homes]\fP and
295 \fB[printers]\fP sections will be considered normal\&.
296 The letter \f(CW\'G\'\fP in parentheses indicates that a parameter is
297 specific to the \fB[global]\fP section\&. The letter \f(CW\'S\'\fP
298 indicates that a parameter can be specified in a service specific
299 section\&. Note that all \f(CW\'S\'\fP parameters can also be specified in the
300 \fB[global]\fP section - in which case they will define
301 the default behavior for all services\&.
303 Parameters are arranged here in alphabetical order - this may not
304 create best bedfellows, but at least you can find them! Where there
305 are synonyms, the preferred synonym is described, others refer to the
308 .SH "VARIABLE SUBSTITUTIONS"
310 Many of the strings that are settable in the config file can take
311 substitutions\&. For example the option \fB\f(CW"path =
312 /tmp/%u"\fP\fP would be interpreted as \f(CW"path = /tmp/john"\fP if
313 the user connected with the username john\&.
315 These substitutions are mostly noted in the descriptions below, but
316 there are some general substitutions which apply whenever they might
317 be relevant\&. These are:
321 \fB%S\fP = the name of the current service, if any\&.
324 \fB%P\fP = the root directory of the current service, if any\&.
327 \fB%u\fP = user name of the current service, if any\&.
330 \fB%g\fP = primary group name of \fB%u\fP\&.
333 \fB%U\fP = session user name (the user name that
334 the client wanted, not necessarily the same as the one they got)\&.
337 \fB%G\fP = primary group name of \fB%U\fP\&.
340 \fB%H\fP = the home directory of the user given by \fB%u\fP\&.
343 \fB%v\fP = the Samba version\&.
346 \fB%h\fP = the internet hostname that Samba is running on\&.
349 \fB%m\fP = the NetBIOS name of the client machine (very useful)\&.
352 \fB%L\fP = the NetBIOS name of the server\&. This allows you to change your
353 config based on what the client calls you\&. Your server can have a "dual
357 \fB%M\fP = the internet name of the client machine\&.
360 \fB%N\fP = the name of your NIS home directory server\&. This is
361 obtained from your NIS auto\&.map entry\&. If you have not compiled Samba
362 with the \fB--with-automount\fP option then this value will be the same
366 \fB%p\fP = the path of the service\'s home directory, obtained from your NIS
367 auto\&.map entry\&. The NIS auto\&.map entry is split up as "%N:%p"\&.
370 \fB%R\fP = the selected protocol level after protocol
371 negotiation\&. It can be one of CORE, COREPLUS, LANMAN1, LANMAN2 or NT1\&.
374 \fB%d\fP = The process id of the current server process\&.
377 \fB%a\fP = the architecture of the remote
378 machine\&. Only some are recognized, and those may not be 100%
379 reliable\&. It currently recognizes Samba, WfWg, WinNT and
380 Win95\&. Anything else will be known as "UNKNOWN"\&. If it gets it wrong
381 then sending a level 3 log to \fIsamba-bugs@samba\&.org\fP
382 should allow it to be fixed\&.
385 \fB%I\fP = The IP address of the client machine\&.
388 \fB%T\fP = the current date and time\&.
391 There are some quite creative things that can be done with these
392 substitutions and other smb\&.conf options\&.
396 Samba supports \fI"name mangling"\fP so that DOS and Windows clients can
397 use files that don\'t conform to the 8\&.3 format\&. It can also be set to
398 adjust the case of 8\&.3 format filenames\&.
400 There are several options that control the way mangling is performed,
401 and they are grouped here rather than listed separately\&. For the
402 defaults look at the output of the testparm program\&.
404 All of these options can be set separately for each service (or
405 globally, of course)\&.
409 \fB"mangle case = yes/no"\fP controls if names that have characters that
410 aren\'t of the "default" case are mangled\&. For example, if this is yes
411 then a name like \f(CW"Mail"\fP would be mangled\&. Default \fIno\fP\&.
413 \fB"case sensitive = yes/no"\fP controls whether filenames are case
414 sensitive\&. If they aren\'t then Samba must do a filename search and
415 match on passed names\&. Default \fIno\fP\&.
417 \fB"default case = upper/lower"\fP controls what the default case is for new
418 filenames\&. Default \fIlower\fP\&.
420 \fB"preserve case = yes/no"\fP controls if new files are created with the
421 case that the client passes, or if they are forced to be the \f(CW"default"\fP
422 case\&. Default \fIYes\fP\&.
425 \fB"short preserve case = yes/no"\fP controls if new files which conform
426 to 8\&.3 syntax, that is all in upper case and of suitable length, are
427 created upper case, or if they are forced to be the \f(CW"default"\fP
428 case\&. This option can be use with \fB"preserve case =
429 yes"\fP to permit long filenames to retain their
430 case, while short names are lowered\&. Default \fIYes\fP\&.
432 By default, Samba 2\&.0 has the same semantics as a Windows NT
433 server, in that it is case insensitive but case preserving\&.
435 .SH "NOTE ABOUT USERNAME/PASSWORD VALIDATION"
437 There are a number of ways in which a user can connect to a
438 service\&. The server follows the following steps in determining if it
439 will allow a connection to a specified service\&. If all the steps fail
440 then the connection request is rejected\&. If one of the steps pass then
441 the following steps are not checked\&.
443 If the service is marked \fB"guest only = yes"\fP then
444 steps 1 to 5 are skipped\&.
448 Step 1: If the client has passed a username/password pair and
449 that username/password pair is validated by the UNIX system\'s password
450 programs then the connection is made as that username\&. Note that this
451 includes the \f(CW\e\eserver\eservice%username\fP method of passing a
455 Step 2: If the client has previously registered a username with
456 the system and now supplies a correct password for that username then
457 the connection is allowed\&.
460 Step 3: The client\'s netbios name and any previously used user
461 names are checked against the supplied password, if they match then
462 the connection is allowed as the corresponding user\&.
465 Step 4: If the client has previously validated a
466 username/password pair with the server and the client has passed the
467 validation token then that username is used\&. This step is skipped if
468 \fB"revalidate = yes"\fP for this service\&.
471 Step 5: If a \fB"user = "\fP field is given in the
472 smb\&.conf file for the service and the client has supplied a password,
473 and that password matches (according to the UNIX system\'s password
474 checking) with one of the usernames from the \fBuser=\fP
475 field then the connection is made as the username in the
476 \fB"user="\fP line\&. If one of the username in the
477 \fBuser=\fP list begins with a \f(CW\'@\'\fP then that name
478 expands to a list of names in the group of the same name\&.
481 Step 6: If the service is a guest service then a connection is
482 made as the username given in the \fB"guest account
483 ="\fP for the service, irrespective of the supplied
487 .SH "COMPLETE LIST OF GLOBAL PARAMETERS"
489 Here is a list of all global parameters\&. See the section of each
490 parameter for details\&. Note that some are synonyms\&.
494 \fBadd user script\fP
500 \fBannounce version\fP
506 \fBbind interfaces only\fP
512 \fBchange notify timeout\fP
518 \fBclient code page\fP
530 \fBdebug timestamp\fP
539 \fBdefault service\fP
542 \fBdelete user script\fP
551 \fBdomain admin group\fP
554 \fBdomain admin users\fP
557 \fBdomain controller\fP
563 \fBdomain guest group\fP
566 \fBdomain guest users\fP
575 \fBencrypt passwords\fP
605 \fBldap root passwd\fP
653 \fBmachine password timeout\fP
683 \fBmessage command\fP
689 \fBname resolve order\fP
692 \fBnetbios aliases\fP
701 \fBnt pipe support\fP
710 \fBole locking compatibility\fP
725 \fBpasswd chat debug\fP
734 \fBpassword server\fP
737 \fBprefered master\fP
740 \fBpreferred master\fP
752 \fBprinter driver file\fP
761 \fBread prediction\fP
770 \fBremote announce\fP
773 \fBremote browse sync\fP
791 \fBshared mem size\fP
794 \fBsmb passwd file\fP
812 \fBssl CA certFile\fP
818 \fBssl client cert\fP
824 \fBssl compatibility\fP
830 \fBssl hosts resign\fP
833 \fBssl require clientcert\fP
836 \fBssl require servercert\fP
839 \fBssl server cert\fP
851 \fBstat cache size\fP
872 \fBunix password sync\fP
878 \fBupdate encrypted\fP
908 .SH "COMPLETE LIST OF SERVICE PARAMETERS"
910 Here is a list of all service parameters\&. See the section of each
911 parameter for details\&. Note that some are synonyms\&.
921 \fBalternate permissions\fP
957 \fBdelete readonly\fP
960 \fBdelete veto files\fP
978 \fBdos filetime resolution\fP
987 \fBfake directory create times\fP
993 \fBfollow symlinks\fP
996 \fBforce create mode\fP
999 \fBforce directory mode\fP
1023 \fBhide dot files\fP
1044 \fBlppause command\fP
1050 \fBlpresume command\fP
1086 \fBmax connections\fP
1089 \fBmin print space\fP
1128 \fBprinter driver\fP
1131 \fBprinter driver location\fP
1143 \fBqueuepause command\fP
1146 \fBqueueresume command\fP
1170 \fBshort preserve case\fP
1176 \fBstrict locking\fP
1200 \fBveto oplock files\fP
1221 .SH "EXPLANATION OF EACH PARAMETER"
1224 .IP "\fBadd user script (G)\fP"
1226 This is the full pathname to a script that will be run \fIAS ROOT\fP by
1227 \fBsmbd (8)\fP under special circumstances decribed
1230 Normally, a Samba server requires that UNIX users are created for all
1231 users accessing files on this server\&. For sites that use Windows NT
1232 account databases as their primary user database creating these users
1233 and keeping the user list in sync with the Windows NT PDC is an
1234 onerous task\&. This option allows \fBsmbd\fP to create
1235 the required UNIX users \fION DEMAND\fP when a user accesses the Samba
1238 In order to use this option, \fBsmbd\fP must be set to
1239 \fBsecurity=server\fP or
1240 \fBsecurity=domain\fP and \fB"add user script"\fP
1241 must be set to a full pathname for a script that will create a UNIX user
1242 given one argument of \fB%u\fP, which expands into the UNIX user name to
1245 When the Windows user attempts to access the Samba server, at
1246 \fI"login"\fP(session setup in the SMB protocol) time,
1247 \fBsmbd\fP contacts the \fBpassword
1248 server\fP and attempts to authenticate the given user
1249 with the given password\&. If the authentication succeeds then
1250 \fBsmbd\fP attempts to find a UNIX user in the UNIX
1251 password database to map the Windows user into\&. If this lookup fails,
1252 and \fB"add user script"\fP is set then \fBsmbd\fP will
1253 call the specified script \fIAS ROOT\fP, expanding any \fB%u\fP argument
1254 to be the user name to create\&.
1256 If this script successfully creates the user then
1257 \fBsmbd\fP will continue on as though the UNIX user
1258 already existed\&. In this way, UNIX users are dynamically created to
1259 match existing Windows NT accounts\&.
1261 See also \fBsecurity=server\fP,
1262 \fBsecurity=domain\fP, \fBpassword
1263 server\fP, \fBdelete user
1267 \f(CW add user script = <empty string>\fP
1270 \f(CW add user script = /usr/local/samba/bin/add_user %u\fP
1272 .IP "\fBadmin users (S)\fP"
1274 This is a list of users who will be granted administrative privileges
1275 on the share\&. This means that they will do all file operations as the
1276 super-user (root)\&.
1278 You should use this option very carefully, as any user in this list
1279 will be able to do anything they like on the share, irrespective of
1284 \f(CW no admin users\fP
1288 \f(CW admin users = jason\fP
1290 .IP "\fBallow hosts (S)\fP"
1292 A synonym for this parameter is \fB\'hosts allow\'\fP
1294 This parameter is a comma, space, or tab delimited set of hosts which
1295 are permitted to access a service\&.
1297 If specified in the \fB[global]\fP section then it will
1298 apply to all services, regardless of whether the individual service
1299 has a different setting\&.
1301 You can specify the hosts by name or IP number\&. For example, you could
1302 restrict access to only the hosts on a Class C subnet with something
1303 like \f(CW"allow hosts = 150\&.203\&.5\&."\fP\&. The full syntax of the list is
1304 described in the man page \fBhosts_access (5)\fP\&. Note that this man
1305 page may not be present on your system, so a brief description will
1306 be given here also\&.
1308 \fINOTE:\fP IF you wish to allow the \fBsmbpasswd
1309 (8)\fP program to be run by local users to change
1310 their Samba passwords using the local \fBsmbd (8)\fP
1311 daemon, then you \fIMUST\fP ensure that the localhost is listed in your
1312 \fBallow hosts\fP list, as \fBsmbpasswd (8)\fP runs
1313 in client-server mode and is seen by the local
1314 \fBsmbd\fP process as just another client\&.
1316 You can also specify hosts by network/netmask pairs and by netgroup
1317 names if your system supports netgroups\&. The \fIEXCEPT\fP keyword can also
1318 be used to limit a wildcard list\&. The following examples may provide
1321 \fBExample 1\fP: allow localhost and all IPs in 150\&.203\&.*\&.* except one
1323 \f(CW hosts allow = localhost, 150\&.203\&. EXCEPT 150\&.203\&.6\&.66\fP
1325 \fBExample 2\fP: allow localhost and hosts that match the given network/netmask
1327 \f(CW hosts allow = localhost, 150\&.203\&.15\&.0/255\&.255\&.255\&.0\fP
1329 \fBExample 3\fP: allow a localhost plus a couple of hosts
1331 \f(CW hosts allow = localhost, lapland, arvidsjaur\fP
1333 \fBExample 4\fP: allow only hosts in NIS netgroup "foonet" or localhost, but
1334 deny access from one particular host
1336 \f(CW hosts allow = @foonet, localhost\fP
1337 \f(CW hosts deny = pirate\fP
1339 Note that access still requires suitable user-level passwords\&.
1341 See \fBtestparm (1)\fP for a way of testing your
1342 host access to see if it does what you expect\&.
1345 \f(CW none (i\&.e\&., all hosts permitted access)\fP
1348 \f(CW allow hosts = 150\&.203\&.5\&. localhost myhost\&.mynet\&.edu\&.au\fP
1350 .IP "\fBalternate permissions (S)\fP"
1352 This is a deprecated parameter\&. It no longer has any effect in Samba2\&.0\&.
1353 In previous versions of Samba it affected the way the DOS "read only"
1354 attribute was mapped for a file\&. In Samba2\&.0 a file is marked "read only"
1355 if the UNIX file does not have the \'w\' bit set for the owner of the file,
1356 regardless if the owner of the file is the currently logged on user or not\&.
1358 .IP "\fBannounce as (G)\fP"
1360 This specifies what type of server \fBnmbd\fP will
1361 announce itself as, to a network neighborhood browse list\&. By default
1362 this is set to Windows NT\&. The valid options are : "NT", "Win95" or
1363 "WfW" meaning Windows NT, Windows 95 and Windows for Workgroups
1364 respectively\&. Do not change this parameter unless you have a specific
1365 need to stop Samba appearing as an NT server as this may prevent Samba
1366 servers from participating as browser servers correctly\&.
1369 \f(CW announce as = NT\fP
1372 \f(CW announce as = Win95\fP
1374 .IP "\fBannounce version (G)\fP"
1376 This specifies the major and minor version numbers that nmbd will use
1377 when announcing itself as a server\&. The default is 4\&.2\&. Do not change
1378 this parameter unless you have a specific need to set a Samba server
1379 to be a downlevel server\&.
1382 \f(CW announce version = 4\&.2\fP
1385 \f(CW announce version = 2\&.0\fP
1387 .IP "\fBauto services (G)\fP"
1389 This is a list of services that you want to be automatically added to
1390 the browse lists\&. This is most useful for homes and printers services
1391 that would otherwise not be visible\&.
1393 Note that if you just want all printers in your printcap file loaded
1394 then the \fB"load printers"\fP option is easier\&.
1397 \f(CW no auto services\fP
1400 \f(CW auto services = fred lp colorlp\fP
1402 .IP "\fBavailable (S)\fP"
1404 This parameter lets you \fI\'turn off\'\fP a service\&. If \f(CW\'available = no\'\fP,
1405 then \fIALL\fP attempts to connect to the service will fail\&. Such failures
1409 \f(CW available = yes\fP
1412 \f(CW available = no\fP
1414 .IP "\fBbind interfaces only (G)\fP"
1416 This global parameter allows the Samba admin to limit what interfaces
1417 on a machine will serve smb requests\&. If affects file service
1418 \fBsmbd\fP and name service \fBnmbd\fP
1419 in slightly different ways\&.
1421 For name service it causes \fBnmbd\fP to bind to ports
1422 137 and 138 on the interfaces listed in the
1423 \fB\'interfaces\'\fP
1424 parameter\&. \fBnmbd\fP also binds to the \'all
1425 addresses\' interface (0\&.0\&.0\&.0) on ports 137 and 138 for the purposes
1426 of reading broadcast messages\&. If this option is not set then
1427 \fBnmbd\fP will service name requests on all of these
1428 sockets\&. If \fB"bind interfaces only"\fP is set then
1429 \fBnmbd\fP will check the source address of any
1430 packets coming in on the broadcast sockets and discard any that don\'t
1431 match the broadcast addresses of the interfaces in the
1432 \fB\'interfaces\'\fP parameter list\&. As unicast packets
1433 are received on the other sockets it allows \fBnmbd\fP
1434 to refuse to serve names to machines that send packets that arrive
1435 through any interfaces not listed in the
1436 \fB"interfaces"\fP list\&. IP Source address spoofing
1437 does defeat this simple check, however so it must not be used
1438 seriously as a security feature for \fBnmbd\fP\&.
1440 For file service it causes \fBsmbd\fP to bind only to
1441 the interface list given in the \fB\'interfaces\'\fP
1442 parameter\&. This restricts the networks that \fBsmbd\fP
1443 will serve to packets coming in those interfaces\&. Note that you
1444 should not use this parameter for machines that are serving PPP or
1445 other intermittent or non-broadcast network interfaces as it will not
1446 cope with non-permanent interfaces\&.
1448 In addition, to change a users SMB password, the
1449 \fBsmbpasswd\fP by default connects to the
1450 \fI"localhost" - 127\&.0\&.0\&.1\fP address as an SMB client to issue the
1451 password change request\&. If \fB"bind interfaces only"\fP is set then
1452 unless the network address \fI127\&.0\&.0\&.1\fP is added to the
1453 \fB\'interfaces\'\fP parameter list then
1454 \fBsmbpasswd\fP will fail to connect in it\'s
1455 default mode\&. \fBsmbpasswd\fP can be forced to
1456 use the primary IP interface of the local host by using its
1457 \fB"-r remote machine"\fP parameter, with
1458 \fB"remote machine"\fP set to the IP name of the primary interface
1459 of the local host\&.
1462 \f(CW bind interfaces only = False\fP
1465 \f(CW bind interfaces only = True\fP
1467 .IP "\fBblocking locks (S)\fP"
1469 This parameter controls the behavior of \fBsmbd\fP when
1470 given a request by a client to obtain a byte range lock on a region
1471 of an open file, and the request has a time limit associated with it\&.
1473 If this parameter is set and the lock range requested cannot be
1474 immediately satisfied, Samba 2\&.0 will internally queue the lock
1475 request, and periodically attempt to obtain the lock until the
1476 timeout period expires\&.
1478 If this parameter is set to "False", then Samba 2\&.0 will behave
1479 as previous versions of Samba would and will fail the lock
1480 request immediately if the lock range cannot be obtained\&.
1482 This parameter can be set per share\&.
1485 \f(CW blocking locks = True\fP
1488 \f(CW blocking locks = False\fP
1490 .IP "\fBbrowsable (S)\fP"
1492 Synonym for \fBbrowseable\fP\&.
1494 .IP "\fBbrowse list(G)\fP"
1496 This controls whether \fBsmbd\fP will serve a browse
1497 list to a client doing a NetServerEnum call\&. Normally set to true\&. You
1498 should never need to change this\&.
1501 \f(CW browse list = Yes\fP
1503 .IP "\fBbrowseable\fP"
1505 This controls whether this share is seen in the list of available
1506 shares in a net view and in the browse list\&.
1509 \f(CW browseable = Yes\fP
1512 \f(CW browseable = No\fP
1514 .IP "\fBcase sensitive (G)\fP"
1516 See the discussion in the section \fBNAME MANGLING\fP\&.
1518 .IP "\fBcasesignames (G)\fP"
1520 Synonym for \fB"case sensitive"\fP\&.
1522 .IP "\fBchange notify timeout (G)\fP"
1524 One of the new NT SMB requests that Samba 2\&.0 supports is the
1525 "ChangeNotify" requests\&. This SMB allows a client to tell a server to
1526 \fI"watch"\fP a particular directory for any changes and only reply to
1527 the SMB request when a change has occurred\&. Such constant scanning of
1528 a directory is expensive under UNIX, hence an
1529 \fBsmbd\fP daemon only performs such a scan on each
1530 requested directory once every \fBchange notify timeout\fP seconds\&.
1532 \fBchange notify timeout\fP is specified in units of seconds\&.
1535 \f(CW change notify timeout = 60\fP
1538 \f(CW change notify timeout = 300\fP
1540 Would change the scan time to every 5 minutes\&.
1542 .IP "\fBcharacter set (G)\fP"
1544 This allows a smbd to map incoming filenames from a DOS Code page (see
1545 the \fBclient code page\fP parameter) to several
1546 built in UNIX character sets\&. The built in code page translations are:
1550 \fBISO8859-1\fP Western European UNIX character set\&. The parameter
1551 \fBclient code page\fP \fIMUST\fP be set to code
1552 page 850 if the \fBcharacter set\fP parameter is set to iso8859-1
1553 in order for the conversion to the UNIX character set to be done
1557 \fBISO8859-2\fP Eastern European UNIX character set\&. The parameter
1558 \fBclient code page\fP \fIMUST\fP be set to code
1559 page 852 if the \fBcharacter set\fP parameter is set to ISO8859-2
1560 in order for the conversion to the UNIX character set to be done
1564 \fBISO8859-5\fP Russian Cyrillic UNIX character set\&. The parameter
1565 \fBclient code page\fP \fIMUST\fP be set to code
1566 page 866 if the \fBcharacter set\fP parameter is set to ISO8859-2
1567 in order for the conversion to the UNIX character set to be done
1571 \fBKOI8-R\fP Alternate mapping for Russian Cyrillic UNIX
1572 character set\&. The parameter \fBclient code
1573 page\fP \fIMUST\fP be set to code page 866 if the
1574 \fBcharacter set\fP parameter is set to KOI8-R in order for the
1575 conversion to the UNIX character set to be done correctly\&.
1578 \fIBUG\fP\&. These MSDOS code page to UNIX character set mappings should
1579 be dynamic, like the loading of MS DOS code pages, not static\&.
1581 See also \fBclient code page\fP\&. Normally this
1582 parameter is not set, meaning no filename translation is done\&.
1585 \f(CW character set = <empty string>\fP
1588 \f(CW character set = ISO8859-1\fP
1590 .IP "\fBclient code page (G)\fP"
1592 This parameter specifies the DOS code page that the clients accessing
1593 Samba are using\&. To determine what code page a Windows or DOS client
1594 is using, open a DOS command prompt and type the command "chcp"\&. This
1595 will output the code page\&. The default for USA MS-DOS, Windows 95, and
1596 Windows NT releases is code page 437\&. The default for western european
1597 releases of the above operating systems is code page 850\&.
1599 This parameter tells \fBsmbd\fP which of the
1600 \f(CWcodepage\&.XXX\fP files to dynamically load on startup\&. These files,
1601 described more fully in the manual page \fBmake_smbcodepage
1602 (1)\fP, tell \fBsmbd\fP how
1603 to map lower to upper case characters to provide the case insensitivity
1604 of filenames that Windows clients expect\&.
1606 Samba currently ships with the following code page files :
1610 \fBCode Page 437 - MS-DOS Latin US\fP
1613 \fBCode Page 737 - Windows \'95 Greek\fP
1616 \fBCode Page 850 - MS-DOS Latin 1\fP
1619 \fBCode Page 852 - MS-DOS Latin 2\fP
1622 \fBCode Page 861 - MS-DOS Icelandic\fP
1625 \fBCode Page 866 - MS-DOS Cyrillic\fP
1628 \fBCode Page 932 - MS-DOS Japanese SJIS\fP
1631 \fBCode Page 936 - MS-DOS Simplified Chinese\fP
1634 \fBCode Page 949 - MS-DOS Korean Hangul\fP
1637 \fBCode Page 950 - MS-DOS Traditional Chinese\fP
1640 Thus this parameter may have any of the values 437, 737, 850, 852,
1641 861, 932, 936, 949, or 950\&. If you don\'t find the codepage you need,
1642 read the comments in one of the other codepage files and the
1643 \fBmake_smbcodepage (1)\fP man page and
1644 write one\&. Please remember to donate it back to the Samba user
1647 This parameter co-operates with the \fB"valid
1648 chars"\fP parameter in determining what characters are
1649 valid in filenames and how capitalization is done\&. If you set both
1650 this parameter and the \fB"valid chars"\fP parameter
1651 the \fB"client code page"\fP parameter \fIMUST\fP be set before the
1652 \fB"valid chars"\fP parameter in the \fBsmb\&.conf\fP
1653 file\&. The \fB"valid chars"\fP string will then augment
1654 the character settings in the "client code page" parameter\&.
1656 If not set, \fB"client code page"\fP defaults to 850\&.
1658 See also : \fB"valid chars"\fP
1661 \f(CW client code page = 850\fP
1664 \f(CW client code page = 936\fP
1666 .IP "\fBcodingsystem (G)\fP"
1668 This parameter is used to determine how incoming Shift-JIS Japanese
1669 characters are mapped from the incoming \fB"client code
1670 page"\fP used by the client, into file names in the
1671 UNIX filesystem\&. Only useful if \fB"client code
1672 page"\fP is set to 932 (Japanese Shift-JIS)\&.
1678 \fBSJIS\fP Shift-JIS\&. Does no conversion of the incoming filename\&.
1681 \fBJIS8, J8BB, J8BH, J8@B, J8@J, J8@H \fP Convert from incoming
1682 Shift-JIS to eight bit JIS code with different shift-in, shift out
1686 \fBJIS7, J7BB, J7BH, J7@B, J7@J, J7@H \fP Convert from incoming
1687 Shift-JIS to seven bit JIS code with different shift-in, shift out
1691 \fBJUNET, JUBB, JUBH, JU@B, JU@J, JU@H \fP Convert from incoming
1692 Shift-JIS to JUNET code with different shift-in, shift out codes\&.
1695 \fBEUC\fP Convert an incoming Shift-JIS character to EUC code\&.
1698 \fBHEX\fP Convert an incoming Shift-JIS character to a 3 byte hex
1699 representation, i\&.e\&. \f(CW:AB\fP\&.
1702 \fBCAP\fP Convert an incoming Shift-JIS character to the 3 byte hex
1703 representation used by the Columbia AppleTalk Program (CAP),
1704 i\&.e\&. \f(CW:AB\fP\&. This is used for compatibility between Samba and CAP\&.
1707 .IP "\fBcomment (S)\fP"
1709 This is a text field that is seen next to a share when a client does a
1710 queries the server, either via the network neighborhood or via "net
1711 view" to list what shares are available\&.
1713 If you want to set the string that is displayed next to the machine
1714 name then see the server string command\&.
1717 \f(CW No comment string\fP
1720 \f(CW comment = Fred\'s Files\fP
1722 .IP "\fBconfig file (G)\fP"
1724 This allows you to override the config file to use, instead of the
1725 default (usually \fBsmb\&.conf\fP)\&. There is a chicken and egg problem
1726 here as this option is set in the config file!
1728 For this reason, if the name of the config file has changed when the
1729 parameters are loaded then it will reload them from the new config
1732 This option takes the usual substitutions, which can be very useful\&.
1734 If the config file doesn\'t exist then it won\'t be loaded (allowing you
1735 to special case the config files of just a few clients)\&.
1738 \f(CW config file = /usr/local/samba/lib/smb\&.conf\&.%m\fP
1740 .IP "\fBcopy (S)\fP"
1742 This parameter allows you to \fI\'clone\'\fP service entries\&. The specified
1743 service is simply duplicated under the current service\'s name\&. Any
1744 parameters specified in the current section will override those in the
1745 section being copied\&.
1747 This feature lets you set up a \'template\' service and create similar
1748 services easily\&. Note that the service being copied must occur earlier
1749 in the configuration file than the service doing the copying\&.
1755 \f(CW copy = otherservice\fP
1757 .IP "\fBcreate mask (S)\fP"
1759 A synonym for this parameter is \fB\'create mode\'\fP\&.
1761 When a file is created, the necessary permissions are calculated
1762 according to the mapping from DOS modes to UNIX permissions, and the
1763 resulting UNIX mode is then bit-wise \'AND\'ed with this parameter\&.
1764 This parameter may be thought of as a bit-wise MASK for the UNIX modes
1765 of a file\&. Any bit \fI*not*\fP set here will be removed from the modes set
1766 on a file when it is created\&.
1768 The default value of this parameter removes the \'group\' and \'other\'
1769 write and execute bits from the UNIX modes\&.
1771 Following this Samba will bit-wise \'OR\' the UNIX mode created from
1772 this parameter with the value of the "force create mode" parameter
1773 which is set to 000 by default\&.
1775 This parameter does not affect directory modes\&. See the parameter
1776 \fB\'directory mode\'\fP for details\&.
1778 See also the \fB"force create mode"\fP parameter
1779 for forcing particular mode bits to be set on created files\&. See also
1780 the \fB"directory mode"\fP parameter for masking
1781 mode bits on created directories\&.
1784 \f(CW create mask = 0744\fP
1787 \f(CW create mask = 0775\fP
1789 .IP "\fBcreate mode (S)\fP"
1791 This is a synonym for \fBcreate mask\fP\&.
1793 .IP "\fBdeadtime (G)\fP"
1795 The value of the parameter (a decimal integer) represents the number
1796 of minutes of inactivity before a connection is considered dead, and
1797 it is disconnected\&. The deadtime only takes effect if the number of
1798 open files is zero\&.
1800 This is useful to stop a server\'s resources being exhausted by a large
1801 number of inactive connections\&.
1803 Most clients have an auto-reconnect feature when a connection is
1804 broken so in most cases this parameter should be transparent to users\&.
1806 Using this parameter with a timeout of a few minutes is recommended
1809 A deadtime of zero indicates that no auto-disconnection should be
1813 \f(CW deadtime = 0\fP
1816 \f(CW deadtime = 15\fP
1818 .IP "\fBdebug timestamp (G)\fP"
1820 Samba2\&.0 debug log messages are timestamped by default\&. If you are
1821 running at a high \fB"debug level"\fP these timestamps
1822 can be distracting\&. This boolean parameter allows them to be turned
1826 \f(CW debug timestamp = Yes\fP
1829 \f(CW debug timestamp = No\fP
1831 .IP "\fBdebug level (G)\fP"
1833 The value of the parameter (an integer) allows the debug level
1834 (logging level) to be specified in the \fBsmb\&.conf\fP file\&. This is to
1835 give greater flexibility in the configuration of the system\&.
1837 The default will be the debug level specified on the command line
1838 or level zero if none was specified\&.
1841 \f(CW debug level = 3\fP
1843 .IP "\fBdefault (G)\fP"
1845 A synonym for \fBdefault service\fP\&.
1847 .IP "\fBdefault case (S)\fP"
1849 See the section on \fB"NAME MANGLING"\fP\&. Also note
1850 the \fB"short preserve case"\fP parameter\&.
1852 .IP "\fBdefault service (G)\fP"
1854 This parameter specifies the name of a service which will be connected
1855 to if the service actually requested cannot be found\&. Note that the
1856 square brackets are \fINOT\fP given in the parameter value (see example
1859 There is no default value for this parameter\&. If this parameter is not
1860 given, attempting to connect to a nonexistent service results in an
1863 Typically the default service would be a \fBguest ok\fP,
1864 \fBread-only\fP service\&.
1866 Also note that the apparent service name will be changed to equal that
1867 of the requested service, this is very useful as it allows you to use
1868 macros like \fB%S\fP to make a wildcard service\&.
1870 Note also that any \f(CW\'_\'\fP characters in the name of the service used
1871 in the default service will get mapped to a \f(CW\'/\'\fP\&. This allows for
1872 interesting things\&.
1879 default service = pub
1888 .IP "\fBdelete user script (G)\fP"
1890 This is the full pathname to a script that will be run \fIAS ROOT\fP by
1891 \fBsmbd (8)\fP under special circumstances decribed
1894 Normally, a Samba server requires that UNIX users are created for all
1895 users accessing files on this server\&. For sites that use Windows NT
1896 account databases as their primary user database creating these users
1897 and keeping the user list in sync with the Windows NT PDC is an
1898 onerous task\&. This option allows \fBsmbd\fP to delete
1899 the required UNIX users \fION DEMAND\fP when a user accesses the Samba
1900 server and the Windows NT user no longer exists\&.
1902 In order to use this option, \fBsmbd\fP must be set to
1903 \fBsecurity=domain\fP and \fB"delete user
1904 script"\fP must be set to a full pathname for a script that will delete
1905 a UNIX user given one argument of \fB%u\fP, which expands into the UNIX
1906 user name to delete\&. \fINOTE\fP that this is different to the
1907 \fBadd user script\fP which will work with the
1908 \fBsecurity=server\fP option as well as
1909 \fBsecurity=domain\fP\&. The reason for this
1910 is only when Samba is a domain member does it get the information
1911 on an attempted user logon that a user no longer exists\&. In the
1912 \fBsecurity=server\fP mode a missing user
1913 is treated the same as an invalid password logon attempt\&. Deleting
1914 the user in this circumstance would not be a good idea\&.
1916 When the Windows user attempts to access the Samba server, at
1917 \fI"login"\fP(session setup in the SMB protocol) time,
1918 \fBsmbd\fP contacts the \fBpassword
1919 server\fP and attempts to authenticate the given user
1920 with the given password\&. If the authentication fails with the specific
1921 Domain error code meaning that the user no longer exists then
1922 \fBsmbd\fP attempts to find a UNIX user in the UNIX
1923 password database that matches the Windows user account\&. If this lookup succeeds,
1924 and \fB"delete user script"\fP is set then \fBsmbd\fP will
1925 call the specified script \fIAS ROOT\fP, expanding any \fB%u\fP argument
1926 to be the user name to delete\&.
1928 This script should delete the given UNIX username\&. In this way, UNIX
1929 users are dynamically deleted to match existing Windows NT accounts\&.
1931 See also \fBsecurity=domain\fP,
1932 \fBpassword server\fP, \fBadd user
1936 \f(CW delete user script = <empty string>\fP
1939 \f(CW delete user script = /usr/local/samba/bin/del_user %u\fP
1941 .IP "\fBdelete readonly (S)\fP"
1943 This parameter allows readonly files to be deleted\&. This is not
1944 normal DOS semantics, but is allowed by UNIX\&.
1946 This option may be useful for running applications such as rcs, where
1947 UNIX file ownership prevents changing file permissions, and DOS
1948 semantics prevent deletion of a read only file\&.
1951 \f(CW delete readonly = No\fP
1954 \f(CW delete readonly = Yes\fP
1956 .IP "\fBdelete veto files (S)\fP"
1958 This option is used when Samba is attempting to delete a directory
1959 that contains one or more vetoed directories (see the \fB\'veto
1960 files\'\fP option)\&. If this option is set to False (the
1961 default) then if a vetoed directory contains any non-vetoed files or
1962 directories then the directory delete will fail\&. This is usually what
1965 If this option is set to True, then Samba will attempt to recursively
1966 delete any files and directories within the vetoed directory\&. This can
1967 be useful for integration with file serving systems such as \fBNetAtalk\fP,
1968 which create meta-files within directories you might normally veto
1969 DOS/Windows users from seeing (e\&.g\&. \f(CW\&.AppleDouble\fP)
1971 Setting \f(CW\'delete veto files = True\'\fP allows these directories to be
1972 transparently deleted when the parent directory is deleted (so long
1973 as the user has permissions to do so)\&.
1975 See also the \fBveto files\fP parameter\&.
1978 \f(CW delete veto files = False\fP
1981 \f(CW delete veto files = True\fP
1983 .IP "\fBdeny hosts (S)\fP"
1985 The opposite of \fB\'allow hosts\'\fP - hosts listed
1986 here are \fINOT\fP permitted access to services unless the specific
1987 services have their own lists to override this one\&. Where the lists
1988 conflict, the \fB\'allow\'\fP list takes precedence\&.
1991 \f(CW none (i\&.e\&., no hosts specifically excluded)\fP
1994 \f(CW deny hosts = 150\&.203\&.4\&. badhost\&.mynet\&.edu\&.au\fP
1996 .IP "\fBdfree command (G)\fP"
1998 The dfree command setting should only be used on systems where a
1999 problem occurs with the internal disk space calculations\&. This has
2000 been known to happen with Ultrix, but may occur with other operating
2001 systems\&. The symptom that was seen was an error of "Abort Retry
2002 Ignore" at the end of each directory listing\&.
2004 This setting allows the replacement of the internal routines to
2005 calculate the total disk space and amount available with an external
2006 routine\&. The example below gives a possible script that might fulfill
2009 The external program will be passed a single parameter indicating a
2010 directory in the filesystem being queried\&. This will typically consist
2011 of the string \f(CW"\&./"\fP\&. The script should return two integers in
2012 ascii\&. The first should be the total disk space in blocks, and the
2013 second should be the number of available blocks\&. An optional third
2014 return value can give the block size in bytes\&. The default blocksize
2017 Note: Your script should \fINOT\fP be setuid or setgid and should be
2018 owned by (and writeable only by) root!
2021 \f(CW By default internal routines for determining the disk capacity
2022 and remaining space will be used\&.\fP
2025 \f(CW dfree command = /usr/local/samba/bin/dfree\fP
2027 Where the script dfree (which must be made executable) could be:
2034 df $1 | tail -1 | awk \'{print $2" "$4}\'
2040 or perhaps (on Sys V based systems):
2047 /usr/bin/df -k $1 | tail -1 | awk \'{print $3" "$5}\'
2053 Note that you may have to replace the command names with full
2054 path names on some systems\&.
2056 .IP "\fBdirectory (S)\fP"
2058 Synonym for \fBpath\fP\&.
2060 .IP "\fBdirectory mask (S)\fP"
2062 This parameter is the octal modes which are used when converting DOS
2063 modes to UNIX modes when creating UNIX directories\&.
2065 When a directory is created, the necessary permissions are calculated
2066 according to the mapping from DOS modes to UNIX permissions, and the
2067 resulting UNIX mode is then bit-wise \'AND\'ed with this parameter\&.
2068 This parameter may be thought of as a bit-wise MASK for the UNIX modes
2069 of a directory\&. Any bit \fI*not*\fP set here will be removed from the
2070 modes set on a directory when it is created\&.
2072 The default value of this parameter removes the \'group\' and \'other\'
2073 write bits from the UNIX mode, allowing only the user who owns the
2074 directory to modify it\&.
2076 Following this Samba will bit-wise \'OR\' the UNIX mode created from
2077 this parameter with the value of the "force directory mode"
2078 parameter\&. This parameter is set to 000 by default (i\&.e\&. no extra mode
2081 See the \fB"force directory mode"\fP parameter
2082 to cause particular mode bits to always be set on created directories\&.
2084 See also the \fB"create mode"\fP parameter for masking
2085 mode bits on created files\&.
2088 \f(CW directory mask = 0755\fP
2091 \f(CW directory mask = 0775\fP
2093 .IP "\fBdirectory mode (S)\fP"
2095 Synonym for \fBdirectory mask\fP\&.
2097 .IP "\fBdns proxy (G)\fP"
2099 Specifies that \fBnmbd\fP when acting as a WINS
2100 server and finding that a NetBIOS name has not been registered, should
2101 treat the NetBIOS name word-for-word as a DNS name and do a lookup
2102 with the DNS server for that name on behalf of the name-querying
2105 Note that the maximum length for a NetBIOS name is 15 characters, so
2106 the DNS name (or DNS alias) can likewise only be 15 characters,
2109 \fBnmbd\fP spawns a second copy of itself to do the
2110 DNS name lookup requests, as doing a name lookup is a blocking action\&.
2112 See also the parameter \fBwins support\fP\&.
2115 \f(CW dns proxy = yes\fP
2117 \fBdomain admin group (G)\fP
2119 This is an \fBEXPERIMENTAL\fP parameter that is part of the unfinished
2120 Samba NT Domain Controller Code\&. It may be removed in a later release\&.
2121 To work with the latest code builds that may have more support for
2122 Samba NT Domain Controller functionality please subscribe to the
2123 mailing list \fBSamba-ntdom\fP available by sending email to
2124 \fIlistproc@samba\&.org\fP
2126 .IP "\fBdomain admin users (G)\fP"
2128 This is an \fBEXPERIMENTAL\fP parameter that is part of the unfinished
2129 Samba NT Domain Controller Code\&. It may be removed in a later release\&.
2130 To work with the latest code builds that may have more support for
2131 Samba NT Domain Controller functionality please subscribe to the
2132 mailing list \fBSamba-ntdom\fP available by sending email to
2133 \fIlistproc@samba\&.org\fP
2135 .IP "\fBdomain controller (G)\fP"
2137 This is a \fBDEPRECATED\fP parameter\&. It is currently not used within
2138 the Samba source and should be removed from all current smb\&.conf
2139 files\&. It is left behind for compatibility reasons\&.
2141 .IP "\fBdomain groups (G)\fP"
2143 This is an \fBEXPERIMENTAL\fP parameter that is part of the unfinished
2144 Samba NT Domain Controller Code\&. It may be removed in a later release\&.
2145 To work with the latest code builds that may have more support for
2146 Samba NT Domain Controller functionality please subscribe to the
2147 mailing list \fBSamba-ntdom\fP available by sending email to
2148 \fIlistproc@samba\&.org\fP
2150 .IP "\fBdomain guest group (G)\fP"
2152 This is an \fBEXPERIMENTAL\fP parameter that is part of the unfinished
2153 Samba NT Domain Controller Code\&. It may be removed in a later release\&.
2154 To work with the latest code builds that may have more support for
2155 Samba NT Domain Controller functionality please subscribe to the
2156 mailing list \fBSamba-ntdom\fP available by sending email to
2157 \fIlistproc@samba\&.org\fP
2159 .IP "\fBdomain guest users (G)\fP"
2161 This is an \fBEXPERIMENTAL\fP parameter that is part of the unfinished
2162 Samba NT Domain Controller Code\&. It may be removed in a later release\&.
2163 To work with the latest code builds that may have more support for
2164 Samba NT Domain Controller functionality please subscribe to the
2165 mailing list \fBSamba-ntdom\fP available by sending email to
2166 \fIlistproc@samba\&.org\fP
2168 .IP "\fBdomain logons (G)\fP"
2170 If set to true, the Samba server will serve Windows 95/98 Domain
2171 logons for the \fBworkgroup\fP it is in\&. For more
2172 details on setting up this feature see the file DOMAINS\&.txt in the
2173 Samba documentation directory \f(CWdocs/\fP shipped with the source code\&.
2175 Note that Win95/98 Domain logons are \fINOT\fP the same as Windows
2176 NT Domain logons\&. NT Domain logons require a Primary Domain Controller
2177 (PDC) for the Domain\&. It is intended that in a future release Samba
2178 will be able to provide this functionality for Windows NT clients
2182 \f(CW domain logons = no\fP
2184 .IP "\fBdomain master (G)\fP"
2186 Tell \fBnmbd\fP to enable WAN-wide browse list
2187 collation\&. Setting this option causes \fBnmbd\fP to
2188 claim a special domain specific NetBIOS name that identifies it as a
2189 domain master browser for its given
2190 \fBworkgroup\fP\&. Local master browsers in the same
2191 \fBworkgroup\fP on broadcast-isolated subnets will give
2192 this \fBnmbd\fP their local browse lists, and then
2193 ask \fBsmbd\fP for a complete copy of the browse list
2194 for the whole wide area network\&. Browser clients will then contact
2195 their local master browser, and will receive the domain-wide browse
2196 list, instead of just the list for their broadcast-isolated subnet\&.
2198 Note that Windows NT Primary Domain Controllers expect to be able to
2199 claim this \fBworkgroup\fP specific special NetBIOS
2200 name that identifies them as domain master browsers for that
2201 \fBworkgroup\fP by default (i\&.e\&. there is no way to
2202 prevent a Windows NT PDC from attempting to do this)\&. This means that
2203 if this parameter is set and \fBnmbd\fP claims the
2204 special name for a \fBworkgroup\fP before a Windows NT
2205 PDC is able to do so then cross subnet browsing will behave strangely
2209 \f(CW domain master = no\fP
2211 .IP "\fBdont descend (S)\fP"
2213 There are certain directories on some systems (e\&.g\&., the \f(CW/proc\fP tree
2214 under Linux) that are either not of interest to clients or are
2215 infinitely deep (recursive)\&. This parameter allows you to specify a
2216 comma-delimited list of directories that the server should always show
2219 Note that Samba can be very fussy about the exact format of the "dont
2220 descend" entries\&. For example you may need \f(CW"\&./proc"\fP instead of
2221 just \f(CW"/proc"\fP\&. Experimentation is the best policy :-)
2224 \f(CW none (i\&.e\&., all directories are OK to descend)\fP
2227 \f(CW dont descend = /proc,/dev\fP
2229 .IP "\fBdos filetime resolution (S)\fP"
2231 Under the DOS and Windows FAT filesystem, the finest granularity on
2232 time resolution is two seconds\&. Setting this parameter for a share
2233 causes Samba to round the reported time down to the nearest two second
2234 boundary when a query call that requires one second resolution is made
2237 This option is mainly used as a compatibility option for Visual C++
2238 when used against Samba shares\&. If oplocks are enabled on a share,
2239 Visual C++ uses two different time reading calls to check if a file
2240 has changed since it was last read\&. One of these calls uses a
2241 one-second granularity, the other uses a two second granularity\&. As
2242 the two second call rounds any odd second down, then if the file has a
2243 timestamp of an odd number of seconds then the two timestamps will not
2244 match and Visual C++ will keep reporting the file has changed\&. Setting
2245 this option causes the two timestamps to match, and Visual C++ is
2249 \f(CW dos filetime resolution = False\fP
2252 \f(CW dos filetime resolution = True\fP
2254 .IP "\fBdos filetimes (S)\fP"
2256 Under DOS and Windows, if a user can write to a file they can change
2257 the timestamp on it\&. Under POSIX semantics, only the owner of the file
2258 or root may change the timestamp\&. By default, Samba runs with POSIX
2259 semantics and refuses to change the timestamp on a file if the user
2260 smbd is acting on behalf of is not the file owner\&. Setting this option
2261 to True allows DOS semantics and smbd will change the file timestamp as
2265 \f(CW dos filetimes = False\fP
2268 \f(CW dos filetimes = True\fP
2270 .IP "\fBencrypt passwords (G)\fP"
2272 This boolean controls whether encrypted passwords will be negotiated
2273 with the client\&. Note that Windows NT 4\&.0 SP3 and above and also
2274 Windows 98 will by default expect encrypted passwords unless a
2275 registry entry is changed\&. To use encrypted passwords in Samba see the
2276 file ENCRYPTION\&.txt in the Samba documentation directory \f(CWdocs/\fP
2277 shipped with the source code\&.
2279 In order for encrypted passwords to work correctly
2280 \fBsmbd\fP must either have access to a local
2281 \fBsmbpasswd (5)\fP file (see the
2282 \fBsmbpasswd (8)\fP program for information on
2283 how to set up and maintain this file), or set the
2284 \fBsecurity=\fP parameter to either
2286 \fB"domain"\fP which causes
2287 \fBsmbd\fP to authenticate against another server\&.
2289 .IP "\fBexec (S)\fP"
2291 This is a synonym for \fBpreexec\fP\&.
2293 .IP "\fBfake directory create times (S)\fP"
2295 NTFS and Windows VFAT file systems keep a create time for all files
2296 and directories\&. This is not the same as the ctime - status change
2297 time - that Unix keeps, so Samba by default reports the earliest of
2298 the various times Unix does keep\&. Setting this parameter for a share
2299 causes Samba to always report midnight 1-1-1980 as the create time for
2302 This option is mainly used as a compatibility option for Visual C++
2303 when used against Samba shares\&. Visual C++ generated makefiles have
2304 the object directory as a dependency for each object file, and a make
2305 rule to create the directory\&. Also, when NMAKE compares timestamps it
2306 uses the creation time when examining a directory\&. Thus the object
2307 directory will be created if it does not exist, but once it does exist
2308 it will always have an earlier timestamp than the object files it
2311 However, Unix time semantics mean that the create time reported by
2312 Samba will be updated whenever a file is created or deleted in the
2313 directory\&. NMAKE therefore finds all object files in the object
2314 directory bar the last one built are out of date compared to the
2315 directory and rebuilds them\&. Enabling this option ensures directories
2316 always predate their contents and an NMAKE build will proceed as
2320 \f(CW fake directory create times = False\fP
2323 \f(CW fake directory create times = True\fP
2325 .IP "\fBfake oplocks (S)\fP"
2327 Oplocks are the way that SMB clients get permission from a server to
2328 locally cache file operations\&. If a server grants an oplock
2329 (opportunistic lock) then the client is free to assume that it is the
2330 only one accessing the file and it will aggressively cache file
2331 data\&. With some oplock types the client may even cache file open/close
2332 operations\&. This can give enormous performance benefits\&.
2334 When you set \f(CW"fake oplocks = yes"\fP \fBsmbd\fP will
2335 always grant oplock requests no matter how many clients are using the
2338 It is generally much better to use the real \fBoplocks\fP
2339 support rather than this parameter\&.
2341 If you enable this option on all read-only shares or shares that you
2342 know will only be accessed from one client at a time such as
2343 physically read-only media like CDROMs, you will see a big performance
2344 improvement on many operations\&. If you enable this option on shares
2345 where multiple clients may be accessing the files read-write at the
2346 same time you can get data corruption\&. Use this option carefully!
2348 This option is disabled by default\&.
2350 .IP "\fBfollow symlinks (S)\fP"
2352 This parameter allows the Samba administrator to stop
2353 \fBsmbd\fP from following symbolic links in a
2354 particular share\&. Setting this parameter to \fI"No"\fP prevents any file
2355 or directory that is a symbolic link from being followed (the user
2356 will get an error)\&. This option is very useful to stop users from
2357 adding a symbolic link to \f(CW/etc/passwd\fP in their home directory for
2358 instance\&. However it will slow filename lookups down slightly\&.
2360 This option is enabled (i\&.e\&. \fBsmbd\fP will follow
2361 symbolic links) by default\&.
2363 .IP "\fBforce create mode (S)\fP"
2365 This parameter specifies a set of UNIX mode bit permissions that will
2366 \fI*always*\fP be set on a file created by Samba\&. This is done by
2367 bitwise \'OR\'ing these bits onto the mode bits of a file that is being
2368 created\&. The default for this parameter is (in octal) 000\&. The modes
2369 in this parameter are bitwise \'OR\'ed onto the file mode after the mask
2370 set in the \fB"create mask"\fP parameter is applied\&.
2372 See also the parameter \fB"create mask"\fP for details
2373 on masking mode bits on created files\&.
2376 \f(CW force create mode = 000\fP
2379 \f(CW force create mode = 0755\fP
2381 would force all created files to have read and execute permissions set
2382 for \'group\' and \'other\' as well as the read/write/execute bits set for
2385 .IP "\fBforce directory mode (S)\fP"
2387 This parameter specifies a set of UNIX mode bit permissions that will
2388 \fI*always*\fP be set on a directory created by Samba\&. This is done by
2389 bitwise \'OR\'ing these bits onto the mode bits of a directory that is
2390 being created\&. The default for this parameter is (in octal) 0000 which
2391 will not add any extra permission bits to a created directory\&. This
2392 operation is done after the mode mask in the parameter
2393 \fB"directory mask"\fP is applied\&.
2395 See also the parameter \fB"directory mask"\fP for
2396 details on masking mode bits on created directories\&.
2399 \f(CW force directory mode = 000\fP
2402 \f(CW force directory mode = 0755\fP
2404 would force all created directories to have read and execute
2405 permissions set for \'group\' and \'other\' as well as the
2406 read/write/execute bits set for the \'user\'\&.
2408 .IP "\fBforce group (S)\fP"
2410 This specifies a UNIX group name that will be assigned as the default
2411 primary group for all users connecting to this service\&. This is useful
2412 for sharing files by ensuring that all access to files on service will
2413 use the named group for their permissions checking\&. Thus, by assigning
2414 permissions for this group to the files and directories within this
2415 service the Samba administrator can restrict or allow sharing of these
2419 \f(CW no forced group\fP
2422 \f(CW force group = agroup\fP
2424 .IP "\fBforce user (S)\fP"
2426 This specifies a UNIX user name that will be assigned as the default
2427 user for all users connecting to this service\&. This is useful for
2428 sharing files\&. You should also use it carefully as using it
2429 incorrectly can cause security problems\&.
2431 This user name only gets used once a connection is established\&. Thus
2432 clients still need to connect as a valid user and supply a valid
2433 password\&. Once connected, all file operations will be performed as the
2434 \f(CW"forced user"\fP, no matter what username the client connected as\&.
2436 This can be very useful\&.
2439 \f(CW no forced user\fP
2442 \f(CW force user = auser\fP
2444 .IP "\fBfstype (S)\fP"
2446 This parameter allows the administrator to configure the string that
2447 specifies the type of filesystem a share is using that is reported by
2448 \fBsmbd\fP when a client queries the filesystem type
2449 for a share\&. The default type is \fB"NTFS"\fP for compatibility with
2450 Windows NT but this can be changed to other strings such as "Samba" or
2451 "FAT" if required\&.
2454 \f(CW fstype = NTFS\fP
2457 \f(CW fstype = Samba\fP
2459 .IP "\fBgetwd cache (G)\fP"
2461 This is a tuning option\&. When this is enabled a caching algorithm
2462 will be used to reduce the time taken for getwd() calls\&. This can have
2463 a significant impact on performance, especially when the
2464 \fBwidelinks\fP parameter is set to False\&.
2467 \f(CW getwd cache = No\fP
2470 \f(CW getwd cache = Yes\fP
2472 .IP "\fBgroup (S)\fP"
2474 Synonym for \fB"force group"\fP\&.
2476 .IP "\fBguest account (S)\fP"
2478 This is a username which will be used for access to services which are
2479 specified as \fB\'guest ok\'\fP (see below)\&. Whatever
2480 privileges this user has will be available to any client connecting to
2481 the guest service\&. Typically this user will exist in the password
2482 file, but will not have a valid login\&. The user account \fB"ftp"\fP is
2483 often a good choice for this parameter\&. If a username is specified in
2484 a given service, the specified username overrides this one\&.
2486 One some systems the default guest account "nobody" may not be able to
2487 print\&. Use another account in this case\&. You should test this by
2488 trying to log in as your guest user (perhaps by using the \f(CW"su -"\fP
2489 command) and trying to print using the system print command such as
2490 \fBlpr (1)\fP or \fBlp (1)\fP\&.
2493 \f(CW specified at compile time, usually "nobody"\fP
2496 \f(CW guest account = ftp\fP
2498 .IP "\fBguest ok (S)\fP"
2500 If this parameter is \fI\'yes\'\fP for a service, then no password is
2501 required to connect to the service\&. Privileges will be those of the
2502 \fBguest account\fP\&.
2504 See the section below on \fBsecurity\fP for more
2505 information about this option\&.
2508 \f(CW guest ok = no\fP
2511 \f(CW guest ok = yes\fP
2513 .IP "\fBguest only (S)\fP"
2515 If this parameter is \fI\'yes\'\fP for a service, then only guest
2516 connections to the service are permitted\&. This parameter will have no
2517 affect if \fB"guest ok"\fP or \fB"public"\fP
2518 is not set for the service\&.
2520 See the section below on \fBsecurity\fP for more
2521 information about this option\&.
2524 \f(CW guest only = no\fP
2527 \f(CW guest only = yes\fP
2529 .IP "\fBhide dot files (S)\fP"
2531 This is a boolean parameter that controls whether files starting with
2532 a dot appear as hidden files\&.
2535 \f(CW hide dot files = yes\fP
2538 \f(CW hide dot files = no\fP
2540 .IP "\fBhide files(S)\fP"
2542 This is a list of files or directories that are not visible but are
2543 accessible\&. The DOS \'hidden\' attribute is applied to any files or
2544 directories that match\&.
2546 Each entry in the list must be separated by a \f(CW\'/\'\fP, which allows
2547 spaces to be included in the entry\&. \f(CW\'*\'\fP and \f(CW\'?\'\fP can be used
2548 to specify multiple files or directories as in DOS wildcards\&.
2550 Each entry must be a Unix path, not a DOS path and must not include the
2551 Unix directory separator \f(CW\'/\'\fP\&.
2553 Note that the case sensitivity option is applicable in hiding files\&.
2555 Setting this parameter will affect the performance of Samba, as it
2556 will be forced to check all files and directories for a match as they
2559 See also \fB"hide dot files"\fP, \fB"veto
2560 files"\fP and \fB"case sensitive"\fP\&.
2567 No files or directories are hidden by this option (dot files are
2568 hidden by default because of the "hide dot files" option)\&.
2575 \f(CW hide files = /\&.*/DesktopFolderDB/TrashFor%m/resource\&.frk/\fP
2577 The above example is based on files that the Macintosh SMB client
2578 (DAVE) available from \fBThursby\fP creates for
2579 internal use, and also still hides all files beginning with a dot\&.
2581 .IP "\fBhomedir map (G)\fP"
2583 If \fB"nis homedir"\fP is true, and
2584 \fBsmbd\fP is also acting as a Win95/98 \fBlogon
2585 server\fP then this parameter specifies the NIS (or YP)
2586 map from which the server for the user\'s home directory should be
2587 extracted\&. At present, only the Sun auto\&.home map format is
2588 understood\&. The form of the map is:
2590 \f(CWusername server:/some/file/system\fP
2592 and the program will extract the servername from before the first
2593 \f(CW\':\'\fP\&. There should probably be a better parsing system that copes
2594 with different map formats and also Amd (another automounter) maps\&.
2596 NB: A working NIS is required on the system for this option to work\&.
2598 See also \fB"nis homedir"\fP, \fBdomain
2602 \f(CW homedir map = auto\&.home\fP
2605 \f(CW homedir map = amd\&.homedir\fP
2607 .IP "\fBhosts allow (S)\fP"
2609 Synonym for \fBallow hosts\fP\&.
2611 .IP "\fBhosts deny (S)\fP"
2613 Synonym for \fBdenyhosts\fP\&.
2615 .IP "\fBhosts equiv (G)\fP"
2617 If this global parameter is a non-null string, it specifies the name
2618 of a file to read for the names of hosts and users who will be allowed
2619 access without specifying a password\&.
2621 This is not be confused with \fBallow hosts\fP which
2622 is about hosts access to services and is more useful for guest
2623 services\&. \fBhosts equiv\fP may be useful for NT clients which will not
2624 supply passwords to samba\&.
2626 NOTE: The use of \fBhosts equiv\fP can be a major security hole\&. This is
2627 because you are trusting the PC to supply the correct username\&. It is
2628 very easy to get a PC to supply a false username\&. I recommend that the
2629 \fBhosts equiv\fP option be only used if you really know what you are
2630 doing, or perhaps on a home network where you trust your spouse and
2631 kids\&. And only if you \fIreally\fP trust them :-)\&.
2634 \f(CW No host equivalences\fP
2637 \f(CW hosts equiv = /etc/hosts\&.equiv\fP
2639 .IP "\fBinclude (G)\fP"
2641 This allows you to include one config file inside another\&. The file
2642 is included literally, as though typed in place\&.
2644 It takes the standard substitutions, except \fB%u\fP,
2645 \fB%P\fP and \fB%S\fP\&.
2647 .IP "\fBinterfaces (G)\fP"
2649 This option allows you to setup multiple network interfaces, so that
2650 Samba can properly handle browsing on all interfaces\&.
2652 The option takes a list of ip/netmask pairs\&. The netmask may either be
2653 a bitmask, or a bitlength\&.
2655 For example, the following line:
2657 \f(CWinterfaces = 192\&.168\&.2\&.10/24 192\&.168\&.3\&.10/24\fP
2659 would configure two network interfaces with IP addresses 192\&.168\&.2\&.10
2660 and 192\&.168\&.3\&.10\&. The netmasks of both interfaces would be set to
2661 255\&.255\&.255\&.0\&.
2663 You could produce an equivalent result by using:
2665 \f(CWinterfaces = 192\&.168\&.2\&.10/255\&.255\&.255\&.0 192\&.168\&.3\&.10/255\&.255\&.255\&.0\fP
2667 if you prefer that format\&.
2669 If this option is not set then Samba will attempt to find a primary
2670 interface, but won\'t attempt to configure more than one interface\&.
2672 See also \fB"bind interfaces only"\fP\&.
2674 .IP "\fBinvalid users (S)\fP"
2676 This is a list of users that should not be allowed to login to this
2677 service\&. This is really a \fI"paranoid"\fP check to absolutely ensure an
2678 improper setting does not breach your security\&.
2680 A name starting with a \f(CW\'@\'\fP is interpreted as an NIS netgroup first
2681 (if your system supports NIS), and then as a UNIX group if the name
2682 was not found in the NIS netgroup database\&.
2684 A name starting with \f(CW\'+\'\fP is interpreted only by looking in the
2685 UNIX group database\&. A name starting with \f(CW\'&\'\fP is interpreted only
2686 by looking in the NIS netgroup database (this requires NIS to be
2687 working on your system)\&. The characters \f(CW\'+\'\fP and \f(CW\'&\'\fP may be
2688 used at the start of the name in either order so the value
2689 \f(CW"+&group"\fP means check the UNIX group database, followed by the NIS
2690 netgroup database, and the value \f(CW"&+group"\fP means check the NIS
2691 netgroup database, followed by the UNIX group database (the same as
2692 the \f(CW\'@\'\fP prefix)\&.
2694 The current servicename is substituted for
2695 \fB%S\fP\&. This is useful in the \fB[homes]\fP
2698 See also \fB"valid users"\fP\&.
2701 \f(CW No invalid users\fP
2704 \f(CW invalid users = root fred admin @wheel\fP
2706 .IP "\fBkeepalive (G)\fP"
2708 The value of the parameter (an integer) represents the number of
2709 seconds between \fB\'keepalive\'\fP packets\&. If this parameter is zero, no
2710 keepalive packets will be sent\&. Keepalive packets, if sent, allow the
2711 server to tell whether a client is still present and responding\&.
2713 Keepalives should, in general, not be needed if the socket being used
2714 has the SO_KEEPALIVE attribute set on it (see \fB"socket
2715 options"\fP)\&. Basically you should only use this option
2716 if you strike difficulties\&.
2719 \f(CW keep alive = 0\fP
2722 \f(CW keep alive = 60\fP
2724 .IP "\fBkernel oplocks (G)\fP"
2726 For UNIXs that support kernel based \fBoplocks\fP
2727 (currently only IRIX but hopefully also Linux and FreeBSD soon) this
2728 parameter allows the use of them to be turned on or off\&.
2730 Kernel oplocks support allows Samba \fBoplocks\fP to be
2731 broken whenever a local UNIX process or NFS operation accesses a file
2732 that \fBsmbd\fP has oplocked\&. This allows complete
2733 data consistency between SMB/CIFS, NFS and local file access (and is a
2734 \fIvery\fP cool feature :-)\&.
2736 This parameter defaults to \fI"On"\fP on systems that have the support,
2737 and \fI"off"\fP on systems that don\'t\&. You should never need to touch
2740 .IP "\fBldap filter (G)\fP"
2742 This parameter is part of the \fIEXPERIMENTAL\fP Samba support for a
2743 password database stored on an LDAP server back-end\&. These options
2744 are only available if your version of Samba was configured with
2745 the \fB--with-ldap\fP option\&.
2747 This parameter specifies an LDAP search filter used to search for a
2748 user name in the LDAP database\&. It must contain the string
2749 \fB%u\fP which will be replaced with the user being
2753 \f(CW empty string\&.\fP
2755 .IP "\fBldap port (G)\fP"
2757 This parameter is part of the \fIEXPERIMENTAL\fP Samba support for a
2758 password database stored on an LDAP server back-end\&. These options
2759 are only available if your version of Samba was configured with
2760 the \fB--with-ldap\fP option\&.
2762 This parameter specifies the TCP port number to use to contact
2763 the LDAP server on\&.
2766 \f(CW ldap port = 389\&.\fP
2768 .IP "\fBldap root (G)\fP"
2770 This parameter is part of the \fIEXPERIMENTAL\fP Samba support for a
2771 password database stored on an LDAP server back-end\&. These options
2772 are only available if your version of Samba was configured with
2773 the \fB--with-ldap\fP option\&.
2775 This parameter specifies the entity to bind to the LDAP server
2776 as (essentially the LDAP username) in order to be able to perform
2777 queries and modifications on the LDAP database\&.
2779 See also \fBldap root passwd\fP\&.
2782 \f(CW empty string (no user defined)\fP
2784 .IP "\fBldap root passwd (G)\fP"
2786 This parameter is part of the \fIEXPERIMENTAL\fP Samba support for a
2787 password database stored on an LDAP server back-end\&. These options
2788 are only available if your version of Samba was configured with
2789 the \fB--with-ldap\fP option\&.
2791 This parameter specifies the password for the entity to bind to the
2792 LDAP server as (the password for this LDAP username) in order to be
2793 able to perform queries and modifications on the LDAP database\&.
2795 \fIBUGS:\fP This parameter should \fINOT\fP be a readable parameter
2796 in the \fBsmb\&.conf\fP file and will be removed once a correct
2797 storage place is found\&.
2799 See also \fBldap root\fP\&.
2802 \f(CW empty string\&.\fP
2804 .IP "\fBldap server (G)\fP"
2806 This parameter is part of the \fIEXPERIMENTAL\fP Samba support for a
2807 password database stored on an LDAP server back-end\&. These options
2808 are only available if your version of Samba was configured with
2809 the \fB--with-ldap\fP option\&.
2811 This parameter specifies the DNS name of the LDAP server to use
2812 for SMB/CIFS authentication purposes\&.
2815 \f(CW ldap server = localhost\fP
2817 .IP "\fBldap suffix (G)\fP"
2819 This parameter is part of the \fIEXPERIMENTAL\fP Samba support for a
2820 password database stored on an LDAP server back-end\&. These options
2821 are only available if your version of Samba was configured with
2822 the \fB--with-ldap\fP option\&.
2824 This parameter specifies the \f(CW"dn"\fP or LDAP \fI"distinguished name"\fP
2825 that tells \fBsmbd\fP to start from when searching
2826 for an entry in the LDAP password database\&.
2829 \f(CW empty string\&.\fP
2831 .IP "\fBlm announce (G)\fP"
2833 This parameter determines if \fBnmbd\fP will produce
2834 Lanman announce broadcasts that are needed by \fBOS/2\fP clients in order
2835 for them to see the Samba server in their browse list\&. This parameter
2836 can have three values, \f(CW"true"\fP, \f(CW"false"\fP, or \f(CW"auto"\fP\&. The
2837 default is \f(CW"auto"\fP\&. If set to \f(CW"false"\fP Samba will never produce
2838 these broadcasts\&. If set to \f(CW"true"\fP Samba will produce Lanman
2839 announce broadcasts at a frequency set by the parameter \fB"lm
2840 interval"\fP\&. If set to \f(CW"auto"\fP Samba will not send Lanman
2841 announce broadcasts by default but will listen for them\&. If it hears
2842 such a broadcast on the wire it will then start sending them at a
2843 frequency set by the parameter \fB"lm interval"\fP\&.
2845 See also \fB"lm interval"\fP\&.
2848 \f(CW lm announce = auto\fP
2851 \f(CW lm announce = true\fP
2853 .IP "\fBlm interval (G)\fP"
2855 If Samba is set to produce Lanman announce broadcasts needed by
2856 \fBOS/2\fP clients (see the \fB"lm announce"\fP
2857 parameter) then this parameter defines the frequency in seconds with
2858 which they will be made\&. If this is set to zero then no Lanman
2859 announcements will be made despite the setting of the \fB"lm
2860 announce"\fP parameter\&.
2862 See also \fB"lm announce"\fP\&.
2865 \f(CW lm interval = 60\fP
2868 \f(CW lm interval = 120\fP
2870 .IP "\fBload printers (G)\fP"
2872 A boolean variable that controls whether all printers in the printcap
2873 will be loaded for browsing by default\&. See the
2874 \fB"printers"\fP section for more details\&.
2877 \f(CW load printers = yes\fP
2880 \f(CW load printers = no\fP
2882 .IP "\fBlocal master (G)\fP"
2884 This option allows \fBnmbd\fP to try and become a
2885 local master browser on a subnet\&. If set to False then
2886 \fBnmbd\fP will not attempt to become a local master
2887 browser on a subnet and will also lose in all browsing elections\&. By
2888 default this value is set to true\&. Setting this value to true doesn\'t
2889 mean that Samba will \fIbecome\fP the local master browser on a subnet,
2890 just that \fBnmbd\fP will \fIparticipate\fP in
2891 elections for local master browser\&.
2893 Setting this value to False will cause \fBnmbd\fP
2894 \fInever\fP to become a local master browser\&.
2897 \f(CW local master = yes\fP
2899 .IP "\fBlock dir (G)\fP"
2901 Synonym for \fB"lock directory"\fP\&.
2903 .IP "\fBlock directory (G)\fP"
2905 This option specifies the directory where lock files will be placed\&.
2906 The lock files are used to implement the \fB"max
2907 connections"\fP option\&.
2910 \f(CW lock directory = /tmp/samba\fP
2913 \f(CW lock directory = /usr/local/samba/var/locks\fP
2915 .IP "\fBlocking (S)\fP"
2917 This controls whether or not locking will be performed by the server
2918 in response to lock requests from the client\&.
2920 If \f(CW"locking = no"\fP, all lock and unlock requests will appear to
2921 succeed and all lock queries will indicate that the queried lock is
2924 If \f(CW"locking = yes"\fP, real locking will be performed by the server\&.
2926 This option \fImay\fP be useful for read-only filesystems which \fImay\fP
2927 not need locking (such as cdrom drives), although setting this
2928 parameter of \f(CW"no"\fP is not really recommended even in this case\&.
2930 Be careful about disabling locking either globally or in a specific
2931 service, as lack of locking may result in data corruption\&. You should
2932 never need to set this parameter\&.
2935 \f(CW locking = yes\fP
2938 \f(CW locking = no\fP
2940 .IP "\fBlog file (G)\fP"
2942 This options allows you to override the name of the Samba log file
2943 (also known as the debug file)\&.
2945 This option takes the standard substitutions, allowing you to have
2946 separate log files for each user or machine\&.
2949 \f(CW log file = /usr/local/samba/var/log\&.%m\fP
2951 .IP "\fBlog level (G)\fP"
2953 Synonym for \fB"debug level"\fP\&.
2955 .IP "\fBlogon drive (G)\fP"
2957 This parameter specifies the local path to which the home directory
2958 will be connected (see \fB"logon home"\fP) and is only
2959 used by NT Workstations\&.
2961 Note that this option is only useful if Samba is set up as a
2962 \fBlogon server\fP\&.
2965 \f(CW logon drive = h:\fP
2967 .IP "\fBlogon home (G)\fP"
2969 This parameter specifies the home directory location when a Win95/98 or
2970 NT Workstation logs into a Samba PDC\&. It allows you to do
2972 \f(CW"NET USE H: /HOME"\fP
2974 from a command prompt, for example\&.
2976 This option takes the standard substitutions, allowing you to have
2977 separate logon scripts for each user or machine\&.
2979 Note that this option is only useful if Samba is set up as a
2980 \fBlogon server\fP\&.
2983 \f(CW logon home = "\e\eremote_smb_server\e%U"\fP
2986 \f(CW logon home = "\e\e%N\e%U"\fP
2988 .IP "\fBlogon path (G)\fP"
2990 This parameter specifies the home directory where roaming profiles
2991 (USER\&.DAT / USER\&.MAN files for Windows 95/98) are stored\&.
2993 This option takes the standard substitutions, allowing you to have
2994 separate logon scripts for each user or machine\&. It also specifies
2995 the directory from which the \f(CW"desktop"\fP, \f(CW"start menu"\fP,
2996 \f(CW"network neighborhood"\fP and \f(CW"programs"\fP folders, and their
2997 contents, are loaded and displayed on your Windows 95/98 client\&.
2999 The share and the path must be readable by the user for the
3000 preferences and directories to be loaded onto the Windows 95/98
3001 client\&. The share must be writeable when the logs in for the first
3002 time, in order that the Windows 95/98 client can create the user\&.dat
3003 and other directories\&.
3005 Thereafter, the directories and any of the contents can, if required, be
3006 made read-only\&. It is not advisable that the USER\&.DAT file be made
3007 read-only - rename it to USER\&.MAN to achieve the desired effect (a
3008 \fIMAN\fPdatory profile)\&.
3010 Windows clients can sometimes maintain a connection to the [homes]
3011 share, even though there is no user logged in\&. Therefore, it is vital
3012 that the logon path does not include a reference to the homes share
3013 (i\&.e\&. setting this parameter to \f(CW\e\e%N\eHOMES\eprofile_path\fP will cause
3016 This option takes the standard substitutions, allowing you to have
3017 separate logon scripts for each user or machine\&.
3019 Note that this option is only useful if Samba is set up as a
3020 \fBlogon server\fP\&.
3023 \f(CW logon path = \e\e%N\e%U\eprofile\fP
3026 \f(CW logon path = \e\ePROFILESERVER\eHOME_DIR\e%U\ePROFILE\fP
3028 .IP "\fBlogon script (G)\fP"
3030 This parameter specifies the batch file (\&.bat) or NT command file
3031 (\&.cmd) to be downloaded and run on a machine when a user successfully
3032 logs in\&. The file must contain the DOS style cr/lf line endings\&.
3033 Using a DOS-style editor to create the file is recommended\&.
3035 The script must be a relative path to the \f(CW[netlogon]\fP service\&. If
3036 the \f(CW[netlogon]\fP service specifies a \fBpath\fP of
3037 /usr/local/samba/netlogon, and logon script = STARTUP\&.BAT, then the
3038 file that will be downloaded is:
3040 \f(CW/usr/local/samba/netlogon/STARTUP\&.BAT\fP
3042 The contents of the batch file is entirely your choice\&. A suggested
3043 command would be to add \f(CWNET TIME \e\eSERVER /SET /YES\fP, to force every
3044 machine to synchronize clocks with the same time server\&. Another use
3045 would be to add \f(CWNET USE U: \e\eSERVER\eUTILS\fP for commonly used
3046 utilities, or \f(CWNET USE Q: \e\eSERVER\eISO9001_QA\fP for example\&.
3048 Note that it is particularly important not to allow write access to
3049 the \f(CW[netlogon]\fP share, or to grant users write permission on the
3050 batch files in a secure environment, as this would allow the batch
3051 files to be arbitrarily modified and security to be breached\&.
3053 This option takes the standard substitutions, allowing you to have
3054 separate logon scripts for each user or machine\&.
3056 Note that this option is only useful if Samba is set up as a
3057 \fBlogon server\fP\&.
3060 \f(CW logon script = scripts\e%U\&.bat\fP
3062 .IP "\fBlppause command (S)\fP"
3064 This parameter specifies the command to be executed on the server host
3065 in order to stop printing or spooling a specific print job\&.
3067 This command should be a program or script which takes a printer name
3068 and job number to pause the print job\&. One way of implementing this is
3069 by using job priorities, where jobs having a too low priority won\'t be
3070 sent to the printer\&.
3072 If a \f(CW"%p"\fP is given then the printername is put in its place\&. A
3073 \f(CW"%j"\fP is replaced with the job number (an integer)\&. On HPUX (see
3074 \fBprinting=hpux\fP), if the \f(CW"-p%p"\fP option is added
3075 to the lpq command, the job will show up with the correct status,
3076 i\&.e\&. if the job priority is lower than the set fence priority it will
3077 have the PAUSED status, whereas if the priority is equal or higher it
3078 will have the SPOOLED or PRINTING status\&.
3080 Note that it is good practice to include the absolute path in the
3081 lppause command as the PATH may not be available to the server\&.
3083 See also the \fB"printing"\fP parameter\&.
3086 Currently no default value is given to this string, unless the
3087 value of the \fB"printing"\fP parameter is \f(CWSYSV\fP, in
3088 which case the default is :
3090 \f(CW lp -i %p-%j -H hold\fP
3092 or if the value of the \fB"printing"\fP parameter is \f(CWsoftq\fP,
3093 then the default is:
3095 \f(CW qstat -s -j%j -h\fP
3097 \fBExample for HPUX:\fP
3098 lppause command = /usr/bin/lpalt %p-%j -p0
3100 .IP "\fBlpq cache time (G)\fP"
3102 This controls how long lpq info will be cached for to prevent the
3103 \fBlpq\fP command being called too often\&. A separate cache is kept for
3104 each variation of the \fBlpq\fP command used by the system, so if you
3105 use different \fBlpq\fP commands for different users then they won\'t
3106 share cache information\&.
3108 The cache files are stored in \f(CW/tmp/lpq\&.xxxx\fP where xxxx is a hash of
3109 the \fBlpq\fP command in use\&.
3111 The default is 10 seconds, meaning that the cached results of a
3112 previous identical \fBlpq\fP command will be used if the cached data is
3113 less than 10 seconds old\&. A large value may be advisable if your
3114 \fBlpq\fP command is very slow\&.
3116 A value of 0 will disable caching completely\&.
3118 See also the \fB"printing"\fP parameter\&.
3121 \f(CW lpq cache time = 10\fP
3124 \f(CW lpq cache time = 30\fP
3126 .IP "\fBlpq command (S)\fP"
3128 This parameter specifies the command to be executed on the server host
3129 in order to obtain \f(CW"lpq"\fP-style printer status information\&.
3131 This command should be a program or script which takes a printer name
3132 as its only parameter and outputs printer status information\&.
3134 Currently eight styles of printer status information are supported;
3135 BSD, AIX, LPRNG, PLP, SYSV, HPUX, QNX and SOFTQ\&. This covers most UNIX
3136 systems\&. You control which type is expected using the
3137 \fB"printing ="\fP option\&.
3139 Some clients (notably Windows for Workgroups) may not correctly send
3140 the connection number for the printer they are requesting status
3141 information about\&. To get around this, the server reports on the first
3142 printer service connected to by the client\&. This only happens if the
3143 connection number sent is invalid\&.
3145 If a \f(CW%p\fP is given then the printername is put in its place\&. Otherwise
3146 it is placed at the end of the command\&.
3148 Note that it is good practice to include the absolute path in the \fBlpq
3149 command\fP as the PATH may not be available to the server\&.
3151 See also the \fB"printing"\fP parameter\&.
3154 \f(CW depends on the setting of printing =\fP
3157 \f(CW lpq command = /usr/bin/lpq %p\fP
3159 .IP "\fBlpresume command (S)\fP"
3161 This parameter specifies the command to be executed on the server host
3162 in order to restart or continue printing or spooling a specific print
3165 This command should be a program or script which takes a printer name
3166 and job number to resume the print job\&. See also the \fB"lppause
3167 command"\fP parameter\&.
3169 If a \f(CW%p\fP is given then the printername is put in its place\&. A
3170 \f(CW%j\fP is replaced with the job number (an integer)\&.
3172 Note that it is good practice to include the absolute path in the \fBlpresume
3173 command\fP as the PATH may not be available to the server\&.
3175 See also the \fB"printing"\fP parameter\&.
3179 Currently no default value is given to this string, unless the
3180 value of the \fB"printing"\fP parameter is \f(CWSYSV\fP, in
3181 which case the default is :
3183 \f(CW lp -i %p-%j -H resume\fP
3185 or if the value of the \fB"printing"\fP parameter is \f(CWsoftq\fP,
3186 then the default is:
3188 \f(CW qstat -s -j%j -r\fP
3190 \fBExample for HPUX:\fP
3191 \f(CW lpresume command = /usr/bin/lpalt %p-%j -p2\fP
3193 .IP "\fBlprm command (S)\fP"
3195 This parameter specifies the command to be executed on the server host
3196 in order to delete a print job\&.
3198 This command should be a program or script which takes a printer name
3199 and job number, and deletes the print job\&.
3201 If a \f(CW%p\fP is given then the printername is put in its place\&. A
3202 \f(CW%j\fP is replaced with the job number (an integer)\&.
3204 Note that it is good practice to include the absolute path in the
3205 \fBlprm command\fP as the PATH may not be available to the server\&.
3207 See also the \fB"printing"\fP parameter\&.
3210 \f(CW depends on the setting of "printing ="\fP
3213 \f(CW lprm command = /usr/bin/lprm -P%p %j\fP
3216 \f(CW lprm command = /usr/bin/cancel %p-%j\fP
3218 .IP "\fBmachine password timeout (G)\fP"
3220 If a Samba server is a member of an Windows NT Domain (see the
3221 \fB"security=domain"\fP) parameter) then
3222 periodically a running \fBsmbd\fP process will try and
3223 change the \fBMACHINE ACCOUNT PASWORD\fP stored in the file called
3224 \f(CW<Domain>\&.<Machine>\&.mac\fP where \f(CW<Domain>\fP is the name of the
3225 Domain we are a member of and \f(CW<Machine>\fP is the primary
3226 \fB"NetBIOS name"\fP of the machine
3227 \fBsmbd\fP is running on\&. This parameter specifies how
3228 often this password will be changed, in seconds\&. The default is one
3229 week (expressed in seconds), the same as a Windows NT Domain member
3232 See also \fBsmbpasswd (8)\fP, and the
3233 \fB"security=domain"\fP) parameter\&.
3236 \f(CW machine password timeout = 604800\fP
3238 .IP "\fBmagic output (S)\fP"
3240 This parameter specifies the name of a file which will contain output
3241 created by a magic script (see the \fB"magic
3242 script"\fP parameter below)\&.
3244 Warning: If two clients use the same \fB"magic
3245 script"\fP in the same directory the output file content
3249 \f(CW magic output = <magic script name>\&.out\fP
3252 \f(CW magic output = myfile\&.txt\fP
3254 .IP "\fBmagic script (S)\fP"
3256 This parameter specifies the name of a file which, if opened, will be
3257 executed by the server when the file is closed\&. This allows a UNIX
3258 script to be sent to the Samba host and executed on behalf of the
3261 Scripts executed in this way will be deleted upon completion,
3262 permissions permitting\&.
3264 If the script generates output, output will be sent to the file
3265 specified by the \fB"magic output"\fP parameter (see
3268 Note that some shells are unable to interpret scripts containing
3269 carriage-return-linefeed instead of linefeed as the end-of-line
3270 marker\&. Magic scripts must be executable \fI"as is"\fP on the host,
3271 which for some hosts and some shells will require filtering at the DOS
3274 Magic scripts are \fIEXPERIMENTAL\fP and should \fINOT\fP be relied upon\&.
3277 \f(CW None\&. Magic scripts disabled\&.\fP
3280 \f(CW magic script = user\&.csh\fP
3282 .IP "\fBmangle case (S)\fP"
3284 See the section on \fB"NAME MANGLING"\fP\&.
3286 .IP "\fBmangled map (S)\fP"
3288 This is for those who want to directly map UNIX file names which can
3289 not be represented on Windows/DOS\&. The mangling of names is not always
3290 what is needed\&. In particular you may have documents with file
3291 extensions that differ between DOS and UNIX\&. For example, under UNIX
3292 it is common to use \f(CW"\&.html"\fP for HTML files, whereas under
3293 Windows/DOS \f(CW"\&.htm"\fP is more commonly used\&.
3295 So to map \f(CW"html"\fP to \f(CW"htm"\fP you would use:
3297 \f(CW mangled map = (*\&.html *\&.htm)\fP
3299 One very useful case is to remove the annoying \f(CW";1"\fP off the ends
3300 of filenames on some CDROMS (only visible under some UNIXs)\&. To do
3301 this use a map of (*;1 *)\&.
3304 \f(CW no mangled map\fP
3307 \f(CW mangled map = (*;1 *)\fP
3309 .IP "\fBmangled names (S)\fP"
3311 This controls whether non-DOS names under UNIX should be mapped to
3312 DOS-compatible names ("mangled") and made visible, or whether non-DOS
3313 names should simply be ignored\&.
3315 See the section on \fB"NAME MANGLING"\fP for details
3316 on how to control the mangling process\&.
3318 If mangling is used then the mangling algorithm is as follows:
3322 The first (up to) five alphanumeric characters before the
3323 rightmost dot of the filename are preserved, forced to upper case, and
3324 appear as the first (up to) five characters of the mangled name\&.
3327 A tilde \f(CW"~"\fP is appended to the first part of the mangled
3328 name, followed by a two-character unique sequence, based on the
3329 original root name (i\&.e\&., the original filename minus its final
3330 extension)\&. The final extension is included in the hash calculation
3331 only if it contains any upper case characters or is longer than three
3334 Note that the character to use may be specified using the
3335 \fB"mangling char"\fP option, if you don\'t like
3339 The first three alphanumeric characters of the final extension
3340 are preserved, forced to upper case and appear as the extension of the
3341 mangled name\&. The final extension is defined as that part of the
3342 original filename after the rightmost dot\&. If there are no dots in the
3343 filename, the mangled name will have no extension (except in the case
3344 of \fB"hidden files"\fP - see below)\&.
3347 Files whose UNIX name begins with a dot will be presented as DOS
3348 hidden files\&. The mangled name will be created as for other filenames,
3349 but with the leading dot removed and \f(CW"___"\fP as its extension regardless
3350 of actual original extension (that\'s three underscores)\&.
3353 The two-digit hash value consists of upper case alphanumeric
3356 This algorithm can cause name collisions only if files in a directory
3357 share the same first five alphanumeric characters\&. The probability of
3358 such a clash is 1/1300\&.
3360 The name mangling (if enabled) allows a file to be copied between UNIX
3361 directories from Windows/DOS while retaining the long UNIX
3362 filename\&. UNIX files can be renamed to a new extension from
3363 Windows/DOS and will retain the same basename\&. Mangled names do not
3364 change between sessions\&.
3367 \f(CW mangled names = yes\fP
3370 \f(CW mangled names = no\fP
3372 .IP "\fBmangling char (S)\fP"
3374 This controls what character is used as the \fI"magic"\fP character in
3375 \fBname mangling\fP\&. The default is a \f(CW\'~\'\fP but
3376 this may interfere with some software\&. Use this option to set it to
3377 whatever you prefer\&.
3380 \f(CW mangling char = ~\fP
3383 \f(CW mangling char = ^\fP
3385 .IP "\fBmangled stack (G)\fP"
3387 This parameter controls the number of mangled names that should be
3388 cached in the Samba server \fBsmbd\fP\&.
3390 This stack is a list of recently mangled base names (extensions are
3391 only maintained if they are longer than 3 characters or contains upper
3394 The larger this value, the more likely it is that mangled names can be
3395 successfully converted to correct long UNIX names\&. However, large
3396 stack sizes will slow most directory access\&. Smaller stacks save
3397 memory in the server (each stack element costs 256 bytes)\&.
3399 It is not possible to absolutely guarantee correct long file names, so
3400 be prepared for some surprises!
3403 \f(CW mangled stack = 50\fP
3406 \f(CW mangled stack = 100\fP
3408 .IP "\fBmap archive (S)\fP"
3410 This controls whether the DOS archive attribute should be mapped to
3411 the UNIX owner execute bit\&. The DOS archive bit is set when a file
3412 has been modified since its last backup\&. One motivation for this
3413 option it to keep Samba/your PC from making any file it touches from
3414 becoming executable under UNIX\&. This can be quite annoying for shared
3415 source code, documents, etc\&.\&.\&.
3417 Note that this requires the \fB"create mask"\fP
3418 parameter to be set such that owner execute bit is not masked out
3419 (i\&.e\&. it must include 100)\&. See the parameter \fB"create
3420 mask"\fP for details\&.
3423 \f(CW map archive = yes\fP
3426 \f(CW map archive = no\fP
3428 .IP "\fBmap hidden (S)\fP"
3430 This controls whether DOS style hidden files should be mapped to the
3431 UNIX world execute bit\&.
3433 Note that this requires the \fB"create mask"\fP to be
3434 set such that the world execute bit is not masked out (i\&.e\&. it must
3435 include 001)\&. See the parameter \fB"create mask"\fP
3439 \f(CW map hidden = no\fP
3442 \f(CW map hidden = yes\fP
3444 .IP "\fBmap system (S)\fP"
3446 This controls whether DOS style system files should be mapped to the
3447 UNIX group execute bit\&.
3449 Note that this requires the \fB"create mask"\fP to be
3450 set such that the group execute bit is not masked out (i\&.e\&. it must
3451 include 010)\&. See the parameter \fB"create mask"\fP
3455 \f(CW map system = no\fP
3458 \f(CW map system = yes\fP
3460 .IP "\fBmap to guest (G)\fP"
3462 This parameter is only useful in \fBsecurity\fP modes
3463 other than \fB"security=share"\fP - i\&.e\&. user,
3464 server, and domain\&.
3466 This parameter can take three different values, which tell
3467 \fBsmbd\fP what to do with user login requests that
3468 don\'t match a valid UNIX user in some way\&.
3470 The three settings are :
3474 \fB"Never"\fP - Means user login requests with an invalid password
3475 are rejected\&. This is the default\&.
3478 \fB"Bad User"\fP - Means user logins with an invalid password are
3479 rejected, unless the username does not exist, in which case it is
3480 treated as a guest login and mapped into the \fB"guest
3484 \fB"Bad Password"\fP - Means user logins with an invalid
3485 password are treated as a guest login and mapped into the
3486 \fB"guest account"\fP\&. Note that this can
3487 cause problems as it means that any user incorrectly typing their
3488 password will be silently logged on a \fB"guest"\fP - and
3489 will not know the reason they cannot access files they think
3490 they should - there will have been no message given to them
3491 that they got their password wrong\&. Helpdesk services will
3492 \fI*hate*\fP you if you set the \fB"map to guest"\fP parameter
3496 Note that this parameter is needed to set up \fB"Guest"\fP share
3497 services when using \fBsecurity\fP modes other than
3498 share\&. This is because in these modes the name of the resource being
3499 requested is \fI*not*\fP sent to the server until after the server has
3500 successfully authenticated the client so the server cannot make
3501 authentication decisions at the correct time (connection to the
3502 share) for \fB"Guest"\fP shares\&.
3504 For people familiar with the older Samba releases, this parameter
3505 maps to the old compile-time setting of the GUEST_SESSSETUP value
3509 \f(CW map to guest = Never\fP
3511 \f(CW map to guest = Bad User\fP
3513 .IP "\fBmax connections (S)\fP"
3515 This option allows the number of simultaneous connections to a service
3516 to be limited\&. If \fB"max connections"\fP is greater than 0 then
3517 connections will be refused if this number of connections to the
3518 service are already open\&. A value of zero mean an unlimited number of
3519 connections may be made\&.
3521 Record lock files are used to implement this feature\&. The lock files
3522 will be stored in the directory specified by the \fB"lock
3523 directory"\fP option\&.
3526 \f(CW max connections = 0\fP
3529 \f(CW max connections = 10\fP
3531 .IP "\fBmax disk size (G)\fP"
3533 This option allows you to put an upper limit on the apparent size of
3534 disks\&. If you set this option to 100 then all shares will appear to be
3535 not larger than 100 MB in size\&.
3537 Note that this option does not limit the amount of data you can put on
3538 the disk\&. In the above case you could still store much more than 100
3539 MB on the disk, but if a client ever asks for the amount of free disk
3540 space or the total disk size then the result will be bounded by the
3541 amount specified in \fB"max disk size"\fP\&.
3543 This option is primarily useful to work around bugs in some pieces of
3544 software that can\'t handle very large disks, particularly disks over
3547 A \fB"max disk size"\fP of 0 means no limit\&.
3550 \f(CW max disk size = 0\fP
3553 \f(CW max disk size = 1000\fP
3555 .IP "\fBmax log size (G)\fP"
3557 This option (an integer in kilobytes) specifies the max size the log
3558 file should grow to\&. Samba periodically checks the size and if it is
3559 exceeded it will rename the file, adding a \f(CW"\&.old"\fP extension\&.
3561 A size of 0 means no limit\&.
3564 \f(CW max log size = 5000\fP
3567 \f(CW max log size = 1000\fP
3569 .IP "\fBmax mux (G)\fP"
3571 This option controls the maximum number of outstanding simultaneous
3572 SMB operations that samba tells the client it will allow\&. You should
3573 never need to set this parameter\&.
3576 \f(CW max mux = 50\fP
3578 .IP "\fBmaxopenfiles (G)\fP"
3580 This parameter limits the maximum number of open files that one
3581 \fBsmbd\fP file serving process may have open for
3582 a client at any one time\&. The default for this parameter is set
3583 very high (10,000) as Samba uses only one bit per unopened file\&.
3585 The limit of the number of open files is usually set by the
3586 UNIX per-process file descriptor limit rather than this parameter
3587 so you should never need to touch this parameter\&.
3590 \f(CW max open files = 10000\fP
3592 .IP "\fBmax packet (G)\fP"
3594 Synonym for (packetsize)\&.
3596 .IP "\fBmax ttl (G)\fP"
3598 This option tells \fBnmbd\fP what the default \'time
3599 to live\' of NetBIOS names should be (in seconds) when
3600 \fBnmbd\fP is requesting a name using either a
3601 broadcast packet or from a WINS server\&. You should never need to
3602 change this parameter\&. The default is 3 days\&.
3605 \f(CW max ttl = 259200\fP
3607 .IP "\fBmax wins ttl (G)\fP"
3609 This option tells \fBnmbd\fP when acting as a WINS
3610 server \fB(wins support =true)\fP what the maximum
3611 \'time to live\' of NetBIOS names that \fBnmbd\fP will
3612 grant will be (in seconds)\&. You should never need to change this
3613 parameter\&. The default is 6 days (518400 seconds)\&.
3615 See also the \fB"min wins ttl"\fP parameter\&.
3618 \f(CW max wins ttl = 518400\fP
3620 .IP "\fBmax xmit (G)\fP"
3622 This option controls the maximum packet size that will be negotiated
3623 by Samba\&. The default is 65535, which is the maximum\&. In some cases
3624 you may find you get better performance with a smaller value\&. A value
3625 below 2048 is likely to cause problems\&.
3628 \f(CW max xmit = 65535\fP
3631 \f(CW max xmit = 8192\fP
3633 .IP "\fBmessage command (G)\fP"
3635 This specifies what command to run when the server receives a WinPopup
3638 This would normally be a command that would deliver the message
3639 somehow\&. How this is to be done is up to your imagination\&.
3643 \f(CW message command = csh -c \'xedit %s;rm %s\' &\fP
3645 This delivers the message using \fBxedit\fP, then removes it
3646 afterwards\&. \fINOTE THAT IT IS VERY IMPORTANT THAT THIS COMMAND RETURN
3647 IMMEDIATELY\fP\&. That\'s why I have the \f(CW\'&\'\fP on the end\&. If it doesn\'t
3648 return immediately then your PCs may freeze when sending messages
3649 (they should recover after 30secs, hopefully)\&.
3651 All messages are delivered as the global guest user\&. The command takes
3652 the standard substitutions, although \fB%u\fP won\'t work
3653 (\fB%U\fP may be better in this case)\&.
3655 Apart from the standard substitutions, some additional ones apply\&. In
3660 \f(CW"%s"\fP = the filename containing the message\&.
3663 \f(CW"%t"\fP = the destination that the message was sent to (probably the server
3667 \f(CW"%f"\fP = who the message is from\&.
3670 You could make this command send mail, or whatever else takes your
3671 fancy\&. Please let us know of any really interesting ideas you have\&.
3673 Here\'s a way of sending the messages as mail to root:
3675 \f(CWmessage command = /bin/mail -s \'message from %f on %m\' root < %s; rm %s\fP
3677 If you don\'t have a message command then the message won\'t be
3678 delivered and Samba will tell the sender there was an
3679 error\&. Unfortunately WfWg totally ignores the error code and carries
3680 on regardless, saying that the message was delivered\&.
3682 If you want to silently delete it then try:
3684 \f(CW"message command = rm %s"\fP\&.
3687 \f(CW no message command\fP
3690 \f(CW message command = csh -c \'xedit %s;rm %s\' &\fP
3692 .IP "\fBmin print space (S)\fP"
3694 This sets the minimum amount of free disk space that must be available
3695 before a user will be able to spool a print job\&. It is specified in
3696 kilobytes\&. The default is 0, which means a user can always spool a print
3699 See also the \fBprinting\fP parameter\&.
3702 \f(CW min print space = 0\fP
3705 \f(CW min print space = 2000\fP
3707 .IP "\fBmin wins ttl (G)\fP"
3709 This option tells \fBnmbd\fP when acting as a WINS
3710 server \fB(wins support = true)\fP what the minimum
3711 \'time to live\' of NetBIOS names that \fBnmbd\fP will
3712 grant will be (in seconds)\&. You should never need to change this
3713 parameter\&. The default is 6 hours (21600 seconds)\&.
3716 \f(CW min wins ttl = 21600\fP
3718 .IP "\fBname resolve order (G)\fP"
3720 This option is used by the programs in the Samba suite to determine
3721 what naming services and in what order to resolve host names to IP
3722 addresses\&. The option takes a space separated string of different name
3723 resolution options\&.
3725 The options are :"lmhosts", "host", "wins" and "bcast"\&. They cause
3726 names to be resolved as follows :
3730 \fBlmhosts\fP : Lookup an IP address in the Samba lmhosts file\&.
3733 \fBhost\fP : Do a standard host name to IP address resolution,
3734 using the system /etc/hosts, NIS, or DNS lookups\&. This method of name
3735 resolution is operating system depended for instance on IRIX or
3736 Solaris this may be controlled by the \fI/etc/nsswitch\&.conf\fP file)\&.
3739 \fBwins\fP : Query a name with the IP address listed in the
3740 \fBwins server\fP parameter\&. If no WINS server has
3741 been specified this method will be ignored\&.
3744 \fBbcast\fP : Do a broadcast on each of the known local interfaces
3745 listed in the \fBinterfaces\fP parameter\&. This is the
3746 least reliable of the name resolution methods as it depends on the
3747 target host being on a locally connected subnet\&.
3751 \f(CW name resolve order = lmhosts host wins bcast\fP
3754 \f(CW name resolve order = lmhosts bcast host\fP
3756 This will cause the local lmhosts file to be examined first, followed
3757 by a broadcast attempt, followed by a normal system hostname lookup\&.
3759 .IP "\fBnetbios aliases (G)\fP"
3761 This is a list of NetBIOS names that \fBnmbd\fP will
3762 advertise as additional names by which the Samba server is known\&. This
3763 allows one machine to appear in browse lists under multiple names\&. If
3764 a machine is acting as a \fBbrowse server\fP or
3765 \fBlogon server\fP none of these names will be
3766 advertised as either browse server or logon servers, only the primary
3767 name of the machine will be advertised with these capabilities\&.
3769 See also \fB"netbios name"\fP\&.
3772 \f(CW empty string (no additional names)\fP
3775 \f(CW netbios aliases = TEST TEST1 TEST2\fP
3777 .IP "\fBnetbios name (G)\fP"
3779 This sets the NetBIOS name by which a Samba server is known\&. By
3780 default it is the same as the first component of the host\'s DNS name\&.
3781 If a machine is a \fBbrowse server\fP or
3782 \fBlogon server\fP this name (or the first component
3783 of the hosts DNS name) will be the name that these services are
3786 See also \fB"netbios aliases"\fP\&.
3789 \f(CW Machine DNS name\&.\fP
3792 \f(CW netbios name = MYNAME\fP
3794 .IP "\fBnis homedir (G)\fP"
3796 Get the home share server from a NIS map\&. For UNIX systems that use an
3797 automounter, the user\'s home directory will often be mounted on a
3798 workstation on demand from a remote server\&.
3800 When the Samba logon server is not the actual home directory server,
3801 but is mounting the home directories via NFS then two network hops
3802 would be required to access the users home directory if the logon
3803 server told the client to use itself as the SMB server for home
3804 directories (one over SMB and one over NFS)\&. This can be very
3807 This option allows Samba to return the home share as being on a
3808 different server to the logon server and as long as a Samba daemon is
3809 running on the home directory server, it will be mounted on the Samba
3810 client directly from the directory server\&. When Samba is returning the
3811 home share to the client, it will consult the NIS map specified in
3812 \fB"homedir map"\fP and return the server listed
3815 Note that for this option to work there must be a working NIS
3816 system and the Samba server with this option must also be a
3817 \fBlogon server\fP\&.
3820 \f(CW nis homedir = false\fP
3823 \f(CW nis homedir = true\fP
3825 .IP "\fBnt pipe support (G)\fP"
3827 This boolean parameter controls whether \fBsmbd\fP
3828 will allow Windows NT clients to connect to the NT SMB specific
3829 \f(CWIPC$\fP pipes\&. This is a developer debugging option and can be left
3833 \f(CW nt pipe support = yes\fP
3835 .IP "\fBnt smb support (G)\fP"
3837 This boolean parameter controls whether \fBsmbd\fP
3838 will negotiate NT specific SMB support with Windows NT
3839 clients\&. Although this is a developer debugging option and should be
3840 left alone, benchmarking has discovered that Windows NT clients give
3841 faster performance with this option set to \f(CW"no"\fP\&. This is still
3842 being investigated\&. If this option is set to \f(CW"no"\fP then Samba
3843 offers exactly the same SMB calls that versions prior to Samba2\&.0
3844 offered\&. This information may be of use if any users are having
3845 problems with NT SMB support\&.
3848 \f(CW nt support = yes\fP
3850 .IP "\fBnull passwords (G)\fP"
3852 Allow or disallow client access to accounts that have null passwords\&.
3854 See also \fBsmbpasswd (5)\fP\&.
3857 \f(CW null passwords = no\fP
3860 \f(CW null passwords = yes\fP
3862 .IP "\fBole locking compatibility (G)\fP"
3864 This parameter allows an administrator to turn off the byte range lock
3865 manipulation that is done within Samba to give compatibility for OLE
3866 applications\&. Windows OLE applications use byte range locking as a
3867 form of inter-process communication, by locking ranges of bytes around
3868 the 2^32 region of a file range\&. This can cause certain UNIX lock
3869 managers to crash or otherwise cause problems\&. Setting this parameter
3870 to \f(CW"no"\fP means you trust your UNIX lock manager to handle such cases
3874 \f(CW ole locking compatibility = yes\fP
3877 \f(CW ole locking compatibility = no\fP
3879 .IP "\fBonly guest (S)\fP"
3881 A synonym for \fB"guest only"\fP\&.
3883 .IP "\fBonly user (S)\fP"
3885 This is a boolean option that controls whether connections with
3886 usernames not in the \fBuser=\fP list will be allowed\&. By
3887 default this option is disabled so a client can supply a username to
3888 be used by the server\&.
3890 Note that this also means Samba won\'t try to deduce usernames from the
3891 service name\&. This can be annoying for the \fB[homes]\fP
3892 section\&. To get around this you could use "\fBuser\fP =
3893 \fB%S\fP" which means your \fB"user"\fP list
3894 will be just the service name, which for home directories is the name
3897 See also the \fBuser\fP parameter\&.
3900 \f(CW only user = False\fP
3903 \f(CW only user = True\fP
3905 .IP "\fBoplocks (S)\fP"
3907 This boolean option tells smbd whether to issue oplocks (opportunistic
3908 locks) to file open requests on this share\&. The oplock code can
3909 dramatically (approx\&. 30% or more) improve the speed of access to files
3910 on Samba servers\&. It allows the clients to aggressively cache files
3911 locally and you may want to disable this option for unreliable network
3912 environments (it is turned on by default in Windows NT Servers)\&. For
3913 more information see the file Speed\&.txt in the Samba docs/ directory\&.
3915 Oplocks may be selectively turned off on certain files on a per share basis\&.
3916 See the \'veto oplock files\' parameter\&. On some systems oplocks are recognized
3917 by the underlying operating system\&. This allows data synchronization between
3918 all access to oplocked files, whether it be via Samba or NFS or a local
3919 UNIX process\&. See the \fBkernel oplocks\fP parameter
3923 \f(CW oplocks = True\fP
3926 \f(CW oplocks = False\fP
3928 .IP "\fBos level (G)\fP"
3930 This integer value controls what level Samba advertises itself as for
3931 browse elections\&. The value of this parameter determines whether
3932 \fBnmbd\fP has a chance of becoming a local master
3933 browser for the \fBWORKGROUP\fP in the local broadcast
3934 area\&. The default is zero, which means \fBnmbd\fP will
3935 lose elections to Windows machines\&. See BROWSING\&.txt in the Samba
3936 docs/ directory for details\&.
3939 \f(CW os level = 0\fP
3942 \f(CW os level = 65 ; This will win against any NT Server\fP
3944 .IP "\fBpacket size (G)\fP"
3946 This is a deprecated parameter that how no effect on the current
3947 Samba code\&. It is left in the parameter list to prevent breaking
3948 old \fBsmb\&.conf\fP files\&.
3950 .IP "\fBpanic action (G)\fP"
3952 This is a Samba developer option that allows a system command to be
3953 called when either \fBsmbd\fP or
3954 \fBnmbd\fP crashes\&. This is usually used to draw
3955 attention to the fact that a problem occurred\&.
3958 \f(CW panic action = <empty string>\fP
3960 .IP "\fBpasswd chat (G)\fP"
3962 This string controls the \fI"chat"\fP conversation that takes places
3963 between \fBsmbd\fP and the local password changing
3964 program to change the users password\&. The string describes a sequence
3965 of response-receive pairs that \fBsmbd\fP uses to
3966 determine what to send to the \fBpasswd\fP program
3967 and what to expect back\&. If the expected output is not received then
3968 the password is not changed\&.
3970 This chat sequence is often quite site specific, depending on what
3971 local methods are used for password control (such as NIS etc)\&.
3973 The string can contain the macros \f(CW"%o"\fP and \f(CW"%n"\fP which are
3974 substituted for the old and new passwords respectively\&. It can also
3975 contain the standard macros \f(CW"\en"\fP, \f(CW"\er"\fP, \f(CW"\et"\fP and \f(CW"\es"\fP
3976 to give line-feed, carriage-return, tab and space\&.
3978 The string can also contain a \f(CW\'*\'\fP which matches any sequence of
3981 Double quotes can be used to collect strings with spaces in them into
3984 If the send string in any part of the chat sequence is a fullstop
3985 \f(CW"\&."\fP then no string is sent\&. Similarly, is the expect string is a
3986 fullstop then no string is expected\&.
3988 Note that if the \fB"unix password sync"\fP
3989 parameter is set to true, then this sequence is called \fI*AS ROOT*\fP
3990 when the SMB password in the smbpasswd file is being changed, without
3991 access to the old password cleartext\&. In this case the old password
3992 cleartext is set to \f(CW""\fP (the empty string)\&.
3994 See also \fB"unix password sync"\fP,
3995 \fB"passwd program"\fP and \fB"passwd chat
4002 passwd chat = "*Enter OLD password*" %o\en "*Enter NEW password*" %n\en "*Reenter NEW password*" %n\en "*Password changed*"
4012 passwd chat = *old*password* %o\en *new*password* %n\en *new*password* %n\en *changed*
4017 .IP "\fBpasswd chat debug (G)\fP"
4019 This boolean specifies if the passwd chat script parameter is run in
4020 \f(CW"debug"\fP mode\&. In this mode the strings passed to and received from
4021 the passwd chat are printed in the \fBsmbd\fP log with
4022 a \fB"debug level"\fP of 100\&. This is a dangerous
4023 option as it will allow plaintext passwords to be seen in the
4024 \fBsmbd\fP log\&. It is available to help Samba admins
4025 debug their \fB"passwd chat"\fP scripts when calling
4026 the \fB"passwd program"\fP and should be turned off
4027 after this has been done\&. This parameter is off by default\&.
4029 See also \fB"passwd chat"\fP, \fB"passwd
4033 \f(CW passwd chat debug = True\fP
4036 \f(CW passwd chat debug = False\fP
4038 .IP "\fBpasswd program (G)\fP"
4040 The name of a program that can be used to set UNIX user passwords\&.
4041 Any occurrences of \fB%u\fP will be replaced with the
4042 user name\&. The user name is checked for existence before calling the
4043 password changing program\&.
4045 Also note that many passwd programs insist in \fI"reasonable"\fP
4046 passwords, such as a minimum length, or the inclusion of mixed case
4047 chars and digits\&. This can pose a problem as some clients (such as
4048 Windows for Workgroups) uppercase the password before sending it\&.
4050 \fINote\fP that if the \fB"unix password sync"\fP
4051 parameter is set to \f(CW"True"\fP then this program is called \fI*AS
4052 ROOT*\fP before the SMB password in the
4053 \fBsmbpasswd\fP file is changed\&. If this UNIX
4054 password change fails, then \fBsmbd\fP will fail to
4055 change the SMB password also (this is by design)\&.
4057 If the \fB"unix password sync"\fP parameter is
4058 set this parameter \fIMUST USE ABSOLUTE PATHS\fP for \fIALL\fP programs
4059 called, and must be examined for security implications\&. Note that by
4060 default \fB"unix password sync"\fP is set to
4063 See also \fB"unix password sync"\fP\&.
4066 \f(CW passwd program = /bin/passwd\fP
4069 \f(CW passwd program = /sbin/passwd %u\fP
4071 .IP "\fBpassword level (G)\fP"
4073 Some client/server combinations have difficulty with mixed-case
4074 passwords\&. One offending client is Windows for Workgroups, which for
4075 some reason forces passwords to upper case when using the LANMAN1
4076 protocol, but leaves them alone when using COREPLUS!
4078 This parameter defines the maximum number of characters that may be
4079 upper case in passwords\&.
4081 For example, say the password given was \f(CW"FRED"\fP\&. If \fBpassword
4082 level\fP is set to 1, the following combinations would be tried if
4083 \f(CW"FRED"\fP failed:
4085 \f(CW"Fred"\fP, \f(CW"fred"\fP, \f(CW"fRed"\fP, \f(CW"frEd"\fP, \f(CW"freD"\fP
4087 If \fBpassword level\fP was set to 2, the following combinations would
4090 \f(CW"FRed"\fP, \f(CW"FrEd"\fP, \f(CW"FreD"\fP, \f(CW"fREd"\fP, \f(CW"fReD"\fP,
4091 \f(CW"frED"\fP, \f(CW\&.\&.\fP
4095 The higher value this parameter is set to the more likely it is that a
4096 mixed case password will be matched against a single case
4097 password\&. However, you should be aware that use of this parameter
4098 reduces security and increases the time taken to process a new
4101 A value of zero will cause only two attempts to be made - the password
4102 as is and the password in all-lower case\&.
4105 \f(CW password level = 0\fP
4108 \f(CW password level = 4\fP
4110 .IP "\fBpassword server (G)\fP"
4112 By specifying the name of another SMB server (such as a WinNT box)
4113 with this option, and using \fB"security = domain"\fP or
4114 \fB"security = server"\fP you can get Samba to do all
4115 its username/password validation via a remote server\&.
4117 This options sets the name of the password server to use\&. It must be a
4118 NetBIOS name, so if the machine\'s NetBIOS name is different from its
4119 internet name then you may have to add its NetBIOS name to the lmhosts
4120 file which is stored in the same directory as the \fBsmb\&.conf\fP file\&.
4122 The name of the password server is looked up using the parameter
4123 \fB"name resolve order="\fP and so may resolved
4124 by any method and order described in that parameter\&.
4126 The password server much be a machine capable of using the "LM1\&.2X002"
4127 or the "LM NT 0\&.12" protocol, and it must be in user level security
4130 NOTE: Using a password server means your UNIX box (running Samba) is
4131 only as secure as your password server\&. \fIDO NOT CHOOSE A PASSWORD
4132 SERVER THAT YOU DON\'T COMPLETELY TRUST\fP\&.
4134 Never point a Samba server at itself for password serving\&. This will
4135 cause a loop and could lock up your Samba server!
4137 The name of the password server takes the standard substitutions, but
4138 probably the only useful one is \fB%m\fP, which means
4139 the Samba server will use the incoming client as the password
4140 server\&. If you use this then you better trust your clients, and you
4141 better restrict them with hosts allow!
4143 If the \fB"security"\fP parameter is set to
4144 \fB"domain"\fP, then the list of machines in this option must be a list
4145 of Primary or Backup Domain controllers for the
4146 \fBDomain\fP, as the Samba server is cryptographicly
4147 in that domain, and will use cryptographicly authenticated RPC calls
4148 to authenticate the user logging on\&. The advantage of using
4149 \fB"security=domain"\fP is that if you list
4150 several hosts in the \fB"password server"\fP option then
4151 \fBsmbd\fP will try each in turn till it finds one
4152 that responds\&. This is useful in case your primary server goes down\&.
4154 If the \fB"security"\fP parameter is set to
4155 \fB"server"\fP, then there are different
4156 restrictions that \fB"security=domain"\fP
4157 doesn\'t suffer from:
4161 You may list several password servers in the \fB"password server"\fP
4162 parameter, however if an \fBsmbd\fP makes a connection
4163 to a password server, and then the password server fails, no more
4164 users will be able to be authenticated from this
4165 \fBsmbd\fP\&. This is a restriction of the SMB/CIFS
4166 protocol when in \fB"security=server"\fP mode
4167 and cannot be fixed in Samba\&.
4170 If you are using a Windows NT server as your password server then
4171 you will have to ensure that your users are able to login from the
4172 Samba server, as when in
4173 \fB"security=server"\fP mode the network
4174 logon will appear to come from there rather than from the users
4178 See also the \fB"security"\fP parameter\&.
4181 \f(CW password server = <empty string>\fP
4184 \f(CW password server = NT-PDC, NT-BDC1, NT-BDC2\fP
4186 .IP "\fBpath (S)\fP"
4188 This parameter specifies a directory to which the user of the service
4189 is to be given access\&. In the case of printable services, this is
4190 where print data will spool prior to being submitted to the host for
4193 For a printable service offering guest access, the service should be
4194 readonly and the path should be world-writeable and have the sticky bit
4195 set\&. This is not mandatory of course, but you probably won\'t get the
4196 results you expect if you do otherwise\&.
4198 Any occurrences of \fB%u\fP in the path will be replaced
4199 with the UNIX username that the client is using on this
4200 connection\&. Any occurrences of \fB%m\fP will be replaced
4201 by the NetBIOS name of the machine they are connecting from\&. These
4202 replacements are very useful for setting up pseudo home directories
4205 Note that this path will be based on \fB"root dir"\fP if
4206 one was specified\&.
4212 \f(CW path = /home/fred\fP
4214 .IP "\fBpostexec (S)\fP"
4216 This option specifies a command to be run whenever the service is
4217 disconnected\&. It takes the usual substitutions\&. The command may be run
4218 as the root on some systems\&.
4220 An interesting example may be do unmount server resources:
4222 \f(CWpostexec = /etc/umount /cdrom\fP
4224 See also \fBpreexec\fP\&.
4227 \f(CW none (no command executed)\fP
4230 \f(CW postexec = echo "%u disconnected from %S from %m (%I)" >> /tmp/log\fP
4232 .IP "\fBpostscript (S)\fP"
4234 This parameter forces a printer to interpret the print files as
4235 postscript\&. This is done by adding a \f(CW%!\fP to the start of print output\&.
4237 This is most useful when you have lots of PCs that persist in putting
4238 a control-D at the start of print jobs, which then confuses your
4242 \f(CW postscript = False\fP
4245 \f(CW postscript = True\fP
4247 .IP "\fBpreexec (S)\fP"
4249 This option specifies a command to be run whenever the service is
4250 connected to\&. It takes the usual substitutions\&.
4252 An interesting example is to send the users a welcome message every
4253 time they log in\&. Maybe a message of the day? Here is an example:
4259 preexec = csh -c \'echo \e"Welcome to %S!\e" | /usr/local/samba/bin/smbclient -M %m -I %I\' &
4265 Of course, this could get annoying after a while :-)
4267 See also \fBpostexec\fP\&.
4270 \f(CW none (no command executed)\fP
4273 \f(CW preexec = echo \e"%u connected to %S from %m (%I)\e" >> /tmp/log\fP
4275 .IP "\fBpreferred master (G)\fP"
4277 This boolean parameter controls if \fBnmbd\fP is a
4278 preferred master browser for its workgroup\&.
4280 If this is set to true, on startup, \fBnmbd\fP will
4281 force an election, and it will have a slight advantage in winning the
4282 election\&. It is recommended that this parameter is used in
4283 conjunction with \fB"domain master = yes"\fP, so
4284 that \fBnmbd\fP can guarantee becoming a domain
4287 Use this option with caution, because if there are several hosts
4288 (whether Samba servers, Windows 95 or NT) that are preferred master
4289 browsers on the same subnet, they will each periodically and
4290 continuously attempt to become the local master browser\&. This will
4291 result in unnecessary broadcast traffic and reduced browsing
4294 See also \fBos level\fP\&.
4297 \f(CW preferred master = no\fP
4300 \f(CW preferred master = yes\fP
4302 .IP "\fBprefered master (G)\fP"
4304 Synonym for \fB"preferred master"\fP for people
4305 who cannot spell :-)\&.
4308 Synonym for \fB"auto services"\fP\&.
4310 .IP "\fBpreserve case (S)\fP"
4312 This controls if new filenames are created with the case that the
4313 client passes, or if they are forced to be the \f(CW"default"\fP case\&.
4316 \f(CW preserve case = yes\fP
4318 See the section on \fB"NAME MANGLING"\fP for a
4319 fuller discussion\&.
4321 .IP "\fBprint command (S)\fP"
4323 After a print job has finished spooling to a service, this command
4324 will be used via a \f(CWsystem()\fP call to process the spool
4325 file\&. Typically the command specified will submit the spool file to
4326 the host\'s printing subsystem, but there is no requirement that this
4327 be the case\&. The server will not remove the spool file, so whatever
4328 command you specify should remove the spool file when it has been
4329 processed, otherwise you will need to manually remove old spool files\&.
4331 The print command is simply a text string\&. It will be used verbatim,
4332 with two exceptions: All occurrences of \f(CW"%s"\fP will be replaced by
4333 the appropriate spool file name, and all occurrences of \f(CW"%p"\fP will
4334 be replaced by the appropriate printer name\&. The spool file name is
4335 generated automatically by the server, the printer name is discussed
4338 The full path name will be used for the filename if \f(CW"%s"\fP is not
4339 preceded by a \f(CW\'/\'\fP\&. If you don\'t like this (it can stuff up some
4340 lpq output) then use \f(CW"%f"\fP instead\&. Any occurrences of \f(CW"%f"\fP get
4341 replaced by the spool filename without the full path at the front\&.
4343 The print command \fIMUST\fP contain at least one occurrence of \f(CW"%s"\fP
4344 or \f(CW"%f"\fP - the \f(CW"%p"\fP is optional\&. At the time a job is
4345 submitted, if no printer name is supplied the \f(CW"%p"\fP will be
4346 silently removed from the printer command\&.
4348 If specified in the \fB"[global]"\fP section, the print
4349 command given will be used for any printable service that does not
4350 have its own print command specified\&.
4352 If there is neither a specified print command for a printable service
4353 nor a global print command, spool files will be created but not
4354 processed and (most importantly) not removed\&.
4356 Note that printing may fail on some UNIXs from the \f(CW"nobody"\fP
4357 account\&. If this happens then create an alternative guest account that
4358 can print and set the \fB"guest account"\fP in the
4359 \fB"[global]"\fP section\&.
4361 You can form quite complex print commands by realizing that they are
4362 just passed to a shell\&. For example the following will log a print
4363 job, print the file, then remove it\&. Note that \f(CW\';\'\fP is the usual
4364 separator for command in shell scripts\&.
4366 \f(CWprint command = echo Printing %s >> /tmp/print\&.log; lpr -P %p %s; rm %s\fP
4368 You may have to vary this command considerably depending on how you
4369 normally print files on your system\&. The default for the parameter
4370 varies depending on the setting of the \fB"printing="\fP
4374 For \fB"printing="\fP BSD, AIX, QNX, LPRNG or PLP :
4375 \f(CW print command = lpr -r -P%p %s\fP
4377 For \fB"printing="\fP SYS or HPUX :
4378 \f(CW print command = lp -c -d%p %s; rm %s\fP
4380 For \fB"printing="\fP SOFTQ :
4381 \f(CW print command = lp -d%p -s %s; rm %s\fP
4384 \f(CW print command = /usr/local/samba/bin/myprintscript %p %s\fP
4386 .IP "\fBprint ok (S)\fP"
4388 Synonym for \fBprintable\fP\&.
4390 .IP "\fBprintable (S)\fP"
4392 If this parameter is \f(CW"yes"\fP, then clients may open, write to and
4393 submit spool files on the directory specified for the service\&.
4395 Note that a printable service will ALWAYS allow writing to the service
4396 path (user privileges permitting) via the spooling of print data\&. The
4397 \fB"read only"\fP parameter controls only non-printing
4398 access to the resource\&.
4401 \f(CW printable = no\fP
4404 \f(CW printable = yes\fP
4406 .IP "\fBprintcap (G)\fP"
4408 Synonym for \fBprintcapname\fP\&.
4410 .IP "\fBprintcap name (G)\fP"
4412 This parameter may be used to override the compiled-in default
4413 printcap name used by the server (usually /etc/printcap)\&. See the
4414 discussion of the \fB[printers]\fP section above for
4415 reasons why you might want to do this\&.
4417 On System V systems that use \fBlpstat\fP to list available printers you
4418 can use \f(CW"printcap name = lpstat"\fP to automatically obtain lists of
4419 available printers\&. This is the default for systems that define SYSV
4420 at configure time in Samba (this includes most System V based
4421 systems)\&. If \fB"printcap name"\fP is set to \fBlpstat\fP on these systems
4422 then Samba will launch \f(CW"lpstat -v"\fP and attempt to parse the output
4423 to obtain a printer list\&.
4425 A minimal printcap file would look something like this:
4441 where the \f(CW\'|\'\fP separates aliases of a printer\&. The fact that the
4442 second alias has a space in it gives a hint to Samba that it\'s a
4445 \fINOTE\fP: Under AIX the default printcap name is
4446 \f(CW"/etc/qconfig"\fP\&. Samba will assume the file is in AIX \f(CW"qconfig"\fP
4447 format if the string \f(CW"/qconfig"\fP appears in the printcap filename\&.
4450 \f(CW printcap name = /etc/printcap\fP
4453 \f(CW printcap name = /etc/myprintcap\fP
4455 .IP "\fBprinter (S)\fP"
4457 This parameter specifies the name of the printer to which print jobs
4458 spooled through a printable service will be sent\&.
4460 If specified in the \fB[global]\fP section, the printer
4461 name given will be used for any printable service that does not have
4462 its own printer name specified\&.
4465 none (but may be \f(CW"lp"\fP on many systems)
4468 printer name = laserwriter
4470 .IP "\fBprinter driver (S)\fP"
4472 This option allows you to control the string that clients receive when
4473 they ask the server for the printer driver associated with a
4474 printer\&. If you are using Windows95 or WindowsNT then you can use this
4475 to automate the setup of printers on your system\&.
4477 You need to set this parameter to the exact string (case sensitive)
4478 that describes the appropriate printer driver for your system\&. If you
4479 don\'t know the exact string to use then you should first try with no
4480 \fB"printer driver"\fP option set and the client will give you a list of
4481 printer drivers\&. The appropriate strings are shown in a scrollbox
4482 after you have chosen the printer manufacturer\&.
4484 See also \fB"printer driver file"\fP\&.
4487 printer driver = HP LaserJet 4L
4489 .IP "\fBprinter driver file (G)\fP"
4491 This parameter tells Samba where the printer driver definition file,
4492 used when serving drivers to Windows 95 clients, is to be found\&. If
4493 this is not set, the default is :
4495 \f(CWSAMBA_INSTALL_DIRECTORY/lib/printers\&.def\fP
4497 This file is created from Windows 95 \f(CW"msprint\&.def"\fP files found on
4498 the Windows 95 client system\&. For more details on setting up serving
4499 of printer drivers to Windows 95 clients, see the documentation file
4500 in the docs/ directory, PRINTER_DRIVER\&.txt\&.
4503 \f(CW None (set in compile)\&.\fP
4506 \f(CW printer driver file = /usr/local/samba/printers/drivers\&.def\fP
4508 See also \fB"printer driver location"\fP\&.
4510 .IP "\fBprinter driver location (S)\fP"
4512 This parameter tells clients of a particular printer share where to
4513 find the printer driver files for the automatic installation of
4514 drivers for Windows 95 machines\&. If Samba is set up to serve printer
4515 drivers to Windows 95 machines, this should be set to
4517 \f(CW\e\eMACHINE\eaPRINTER$\fP
4519 Where MACHINE is the NetBIOS name of your Samba server, and PRINTER$
4520 is a share you set up for serving printer driver files\&. For more
4521 details on setting this up see the documentation file in the docs/
4522 directory, PRINTER_DRIVER\&.txt\&.
4528 \f(CW printer driver location = \e\eMACHINE\ePRINTER$\fP
4530 See also \fB"printer driver file"\fP\&.
4532 .IP "\fBprinter name (S)\fP"
4534 Synonym for \fBprinter\fP\&.
4536 .IP "\fBprinting (S)\fP"
4538 This parameters controls how printer status information is interpreted
4539 on your system, and also affects the default values for the
4540 \fB"print command"\fP, \fB"lpq
4541 command"\fP \fB"lppause command"\fP,
4542 \fB"lpresume command"\fP, and \fB"lprm
4545 Currently eight printing styles are supported\&. They are
4546 \fB"printing=BSD"\fP, \fB"printing=AIX"\fP, \fB"printing=LPRNG"\fP,
4547 \fB"printing=PLP"\fP,
4548 \fB"printing=SYSV"\fP,\fB"printing="HPUX"\fP,\fB"printing=QNX"\fP and
4549 \fB"printing=SOFTQ"\fP\&.
4551 To see what the defaults are for the other print commands when using
4552 these three options use the \fB"testparm"\fP program\&.
4554 This option can be set on a per printer basis
4556 See also the discussion in the \fB[printers]\fP section\&.
4558 .IP "\fBprotocol (G)\fP"
4560 The value of the parameter (a string) is the highest protocol level
4561 that will be supported by the server\&.
4563 Possible values are :
4567 CORE: Earliest version\&. No concept of user names\&.
4570 COREPLUS: Slight improvements on CORE for efficiency\&.
4573 LANMAN1: First \fI"modern"\fP version of the protocol\&. Long
4577 LANMAN2: Updates to Lanman1 protocol\&.
4580 NT1: Current up to date version of the protocol\&. Used by Windows
4581 NT\&. Known as CIFS\&.
4584 Normally this option should not be set as the automatic negotiation
4585 phase in the SMB protocol takes care of choosing the appropriate
4589 \f(CW protocol = NT1\fP
4592 \f(CW protocol = LANMAN1\fP
4594 .IP "\fBpublic (S)\fP"
4596 Synonym for \fB"guest ok"\fP\&.
4598 .IP "\fBqueuepause command (S)\fP"
4600 This parameter specifies the command to be executed on the server host
4601 in order to pause the printerqueue\&.
4603 This command should be a program or script which takes a printer name
4604 as its only parameter and stops the printerqueue, such that no longer
4605 jobs are submitted to the printer\&.
4607 This command is not supported by Windows for Workgroups, but can be
4608 issued from the Printer\'s window under Windows 95 & NT\&.
4610 If a \f(CW"%p"\fP is given then the printername is put in its
4611 place\&. Otherwise it is placed at the end of the command\&.
4613 Note that it is good practice to include the absolute path in the
4614 command as the PATH may not be available to the server\&.
4617 \f(CW depends on the setting of "printing ="\fP
4620 \f(CW queuepause command = disable %p\fP
4622 .IP "\fBqueueresume command (S)\fP"
4624 This parameter specifies the command to be executed on the server host
4625 in order to resume the printerqueue\&. It is the command to undo the
4626 behavior that is caused by the previous parameter
4627 (\fB"queuepause command\fP)\&.
4629 This command should be a program or script which takes a printer name
4630 as its only parameter and resumes the printerqueue, such that queued
4631 jobs are resubmitted to the printer\&.
4633 This command is not supported by Windows for Workgroups, but can be
4634 issued from the Printer\'s window under Windows 95 & NT\&.
4636 If a \f(CW"%p"\fP is given then the printername is put in its
4637 place\&. Otherwise it is placed at the end of the command\&.
4639 Note that it is good practice to include the absolute path in the
4640 command as the PATH may not be available to the server\&.
4643 \f(CW depends on the setting of "printing ="\fP
4646 \f(CW queuepause command = enable %p\fP
4648 .IP "\fBread bmpx (G)\fP"
4650 This boolean parameter controls whether \fBsmbd\fP
4651 will support the "Read Block Multiplex" SMB\&. This is now rarely used
4652 and defaults to off\&. You should never need to set this parameter\&.
4657 .IP "\fBread list (S)\fP"
4659 This is a list of users that are given read-only access to a
4660 service\&. If the connecting user is in this list then they will not be
4661 given write access, no matter what the \fB"read only"\fP
4662 option is set to\&. The list can include group names using the syntax
4663 described in the \fB"invalid users"\fP parameter\&.
4665 See also the \fB"write list"\fP parameter and
4666 the \fB"invalid users"\fP parameter\&.
4669 \f(CW read list = <empty string>\fP
4672 \f(CW read list = mary, @students\fP
4674 .IP "\fBread only (S)\fP"
4676 Note that this is an inverted synonym for
4677 \fB"writeable"\fP and \fB"write ok"\fP\&.
4679 See also \fB"writeable"\fP and \fB"write
4682 .IP "\fBread prediction (G)\fP"
4684 \fINOTE\fP: This code is currently disabled in Samba2\&.0 and
4685 may be removed at a later date\&. Hence this parameter has
4688 This options enables or disables the read prediction code used to
4689 speed up reads from the server\&. When enabled the server will try to
4690 pre-read data from the last accessed file that was opened read-only
4691 while waiting for packets\&.
4694 \f(CW read prediction = False\fP
4696 .IP "\fBread raw (G)\fP"
4698 This parameter controls whether or not the server will support the raw
4699 read SMB requests when transferring data to clients\&.
4701 If enabled, raw reads allow reads of 65535 bytes in one packet\&. This
4702 typically provides a major performance benefit\&.
4704 However, some clients either negotiate the allowable block size
4705 incorrectly or are incapable of supporting larger block sizes, and for
4706 these clients you may need to disable raw reads\&.
4708 In general this parameter should be viewed as a system tuning tool and left
4709 severely alone\&. See also \fB"write raw"\fP\&.
4712 \f(CW read raw = yes\fP
4714 .IP "\fBread size (G)\fP"
4716 The option \fB"read size"\fP affects the overlap of disk reads/writes
4717 with network reads/writes\&. If the amount of data being transferred in
4718 several of the SMB commands (currently SMBwrite, SMBwriteX and
4719 SMBreadbraw) is larger than this value then the server begins writing
4720 the data before it has received the whole packet from the network, or
4721 in the case of SMBreadbraw, it begins writing to the network before
4722 all the data has been read from disk\&.
4724 This overlapping works best when the speeds of disk and network access
4725 are similar, having very little effect when the speed of one is much
4726 greater than the other\&.
4728 The default value is 2048, but very little experimentation has been
4729 done yet to determine the optimal value, and it is likely that the
4730 best value will vary greatly between systems anyway\&. A value over
4731 65536 is pointless and will cause you to allocate memory
4735 \f(CW read size = 2048\fP
4738 \f(CW read size = 8192\fP
4740 .IP "\fBremote announce (G)\fP"
4742 This option allows you to setup \fBnmbd\fP to
4743 periodically announce itself to arbitrary IP addresses with an
4744 arbitrary workgroup name\&.
4746 This is useful if you want your Samba server to appear in a remote
4747 workgroup for which the normal browse propagation rules don\'t
4748 work\&. The remote workgroup can be anywhere that you can send IP
4753 \f(CW remote announce = 192\&.168\&.2\&.255/SERVERS 192\&.168\&.4\&.255/STAFF\fP
4755 the above line would cause nmbd to announce itself to the two given IP
4756 addresses using the given workgroup names\&. If you leave out the
4757 workgroup name then the one given in the
4758 \fB"workgroup"\fP parameter is used instead\&.
4760 The IP addresses you choose would normally be the broadcast addresses
4761 of the remote networks, but can also be the IP addresses of known
4762 browse masters if your network config is that stable\&.
4764 See the documentation file BROWSING\&.txt in the docs/ directory\&.
4767 \f(CW remote announce = <empty string>\fP
4770 \f(CW remote announce = 192\&.168\&.2\&.255/SERVERS 192\&.168\&.4\&.255/STAFF\fP
4772 .IP "\fBremote browse sync (G)\fP"
4774 This option allows you to setup \fBnmbd\fP to
4775 periodically request synchronization of browse lists with the master
4776 browser of a samba server that is on a remote segment\&. This option
4777 will allow you to gain browse lists for multiple workgroups across
4778 routed networks\&. This is done in a manner that does not work with any
4779 non-samba servers\&.
4781 This is useful if you want your Samba server and all local clients to
4782 appear in a remote workgroup for which the normal browse propagation
4783 rules don\'t work\&. The remote workgroup can be anywhere that you can
4784 send IP packets to\&.
4788 \f(CW remote browse sync = 192\&.168\&.2\&.255 192\&.168\&.4\&.255\fP
4790 the above line would cause \fBnmbd\fP to request the
4791 master browser on the specified subnets or addresses to synchronize
4792 their browse lists with the local server\&.
4794 The IP addresses you choose would normally be the broadcast addresses
4795 of the remote networks, but can also be the IP addresses of known
4796 browse masters if your network config is that stable\&. If a machine IP
4797 address is given Samba makes NO attempt to validate that the remote
4798 machine is available, is listening, nor that it is in fact the browse
4799 master on it\'s segment\&.
4802 \f(CW remote browse sync = <empty string>\fP
4805 \f(CW remote browse sync = 192\&.168\&.2\&.255 192\&.168\&.4\&.255\fP
4807 .IP "\fBrevalidate (S)\fP"
4809 Note that this option only works with
4810 \fB"security=share"\fP and will be ignored if
4811 this is not the case\&.
4813 This option controls whether Samba will allow a previously validated
4814 username/password pair to be used to attach to a share\&. Thus if you
4815 connect to \f(CW\e\eserver\eshare1\fP then to \f(CW\e\eserver\eshare2\fP it won\'t
4816 automatically allow the client to request connection to the second
4817 share as the same username as the first without a password\&.
4819 If \fB"revalidate"\fP is \f(CW"True"\fP then the client will be denied
4820 automatic access as the same username\&.
4823 \f(CW revalidate = False\fP
4826 \f(CW revalidate = True\fP
4828 .IP "\fBroot (G)\fP"
4830 Synonym for \fB"root directory"\fP\&.
4832 .IP "\fBroot dir (G)\fP"
4834 Synonym for \fB"root directory"\fP\&.
4836 .IP "\fBroot directory (G)\fP"
4838 The server will \f(CW"chroot()"\fP (i\&.e\&. Change it\'s root directory) to
4839 this directory on startup\&. This is not strictly necessary for secure
4840 operation\&. Even without it the server will deny access to files not in
4841 one of the service entries\&. It may also check for, and deny access to,
4842 soft links to other parts of the filesystem, or attempts to use
4843 \f(CW"\&.\&."\fP in file names to access other directories (depending on the
4844 setting of the \fB"wide links"\fP parameter)\&.
4846 Adding a \fB"root directory"\fP entry other than \f(CW"/"\fP adds an extra
4847 level of security, but at a price\&. It absolutely ensures that no
4848 access is given to files not in the sub-tree specified in the \fB"root
4849 directory"\fP option, \fI*including*\fP some files needed for complete
4850 operation of the server\&. To maintain full operability of the server
4851 you will need to mirror some system files into the \fB"root
4852 directory"\fP tree\&. In particular you will need to mirror /etc/passwd
4853 (or a subset of it), and any binaries or configuration files needed
4854 for printing (if required)\&. The set of files that must be mirrored is
4855 operating system dependent\&.
4858 \f(CW root directory = /\fP
4861 \f(CW root directory = /homes/smb\fP
4863 .IP "\fBroot postexec (S)\fP"
4865 This is the same as the \fB"postexec"\fP parameter
4866 except that the command is run as root\&. This is useful for unmounting
4867 filesystems (such as cdroms) after a connection is closed\&.
4869 See also \fB"postexec"\fP\&.
4871 .IP "\fBroot preexec (S)\fP"
4873 This is the same as the \fB"preexec"\fP parameter except
4874 that the command is run as root\&. This is useful for mounting
4875 filesystems (such as cdroms) before a connection is finalized\&.
4877 See also \fB"preexec"\fP\&.
4879 .IP "\fBsecurity (G)\fP"
4881 This option affects how clients respond to Samba and is one of the most
4882 important settings in the \fBsmb\&.conf\fP file\&.
4884 The option sets the \f(CW"security mode bit"\fP in replies to protocol
4885 negotiations with \fBsmbd\fP to turn share level
4886 security on or off\&. Clients decide based on this bit whether (and how)
4887 to transfer user and password information to the server\&.
4889 The default is "security=user", as this is
4890 the most common setting needed when talking to Windows 98 and Windows
4893 The alternatives are \fB"security = share"\fP,
4894 \fB"security = server"\fP or
4895 \fB"security=domain"\fP\&.
4897 \fI*****NOTE THAT THIS DEFAULT IS DIFFERENT IN SAMBA2\&.0 THAN FOR
4898 PREVIOUS VERSIONS OF SAMBA *******\fP\&.
4900 In previous versions of Samba the default was
4901 \fB"security=share"\fP mainly because that was
4902 the only option at one stage\&.
4904 There is a bug in WfWg that has relevance to this setting\&. When in
4905 user or server level security a WfWg client will totally ignore the
4906 password you type in the "connect drive" dialog box\&. This makes it
4907 very difficult (if not impossible) to connect to a Samba service as
4908 anyone except the user that you are logged into WfWg as\&.
4910 If your PCs use usernames that are the same as their usernames on the
4911 UNIX machine then you will want to use \fB"security = user"\fP\&. If you
4912 mostly use usernames that don\'t exist on the UNIX box then use
4913 \fB"security = share"\fP\&.
4915 You should also use \fBsecurity=share\fP if
4916 you want to mainly setup shares without a password (guest
4917 shares)\&. This is commonly used for a shared printer server\&. It is more
4918 difficult to setup guest shares with
4919 \fBsecurity=user\fP, see the \fB"map to
4920 guest"\fPparameter for details\&.
4922 It is possible to use \fBsmbd\fP in a \fI"hybrid
4923 mode"\fP where it is offers both user and share level security under
4924 different \fBNetBIOS aliases\fP\&. See the
4925 \fBNetBIOS aliases\fP and the
4926 \fBinclude\fP parameters for more information\&.
4928 The different settings will now be explained\&.
4931 .IP "\fB"security=share"\fP"
4932 When clients connect to a share level
4933 security server then need not log onto the server with a valid
4934 username and password before attempting to connect to a shared
4935 resource (although modern clients such as Windows 95/98 and Windows NT
4936 will send a logon request with a username but no password when talking
4937 to a \fBsecurity=share\fP server)\&. Instead, the clients send
4938 authentication information (passwords) on a per-share basis, at the
4939 time they attempt to connect to that share\&.
4941 Note that \fBsmbd\fP \fI*ALWAYS*\fP uses a valid UNIX
4942 user to act on behalf of the client, even in \fB"security=share"\fP
4945 As clients are not required to send a username to the server
4946 in share level security, \fBsmbd\fP uses several
4947 techniques to determine the correct UNIX user to use on behalf
4950 A list of possible UNIX usernames to match with the given
4951 client password is constructed using the following methods :
4955 If the \fB"guest only"\fP parameter is set, then
4956 all the other stages are missed and only the \fB"guest
4957 account"\fP username is checked\&.
4960 Is a username is sent with the share connection request, then
4961 this username (after mapping - see \fB"username
4962 map"\fP), is added as a potential username\&.
4965 If the client did a previous \fI"logon"\fP request (the
4966 SessionSetup SMB call) then the username sent in this SMB
4967 will be added as a potential username\&.
4970 The name of the service the client requested is added
4971 as a potential username\&.
4974 The NetBIOS name of the client is added to the list as a
4975 potential username\&.
4978 Any users on the \fB"user"\fP list are added
4979 as potential usernames\&.
4982 If the \fB"guest only"\fP parameter is not set, then
4983 this list is then tried with the supplied password\&. The first user for
4984 whom the password matches will be used as the UNIX user\&.
4986 If the \fB"guest only"\fP parameter is set, or no
4987 username can be determined then if the share is marked as available to
4988 the \fB"guest account"\fP, then this guest user will
4989 be used, otherwise access is denied\&.
4991 Note that it can be \fI*very*\fP confusing in share-level security as to
4992 which UNIX username will eventually be used in granting access\&.
4994 See also the section \fB"NOTE ABOUT USERNAME/PASSWORD
4997 .IP "\fB"security=user"\fP"
4999 This is the default security setting in Samba2\&.0\&. With user-level
5000 security a client must first \f(CW"log-on"\fP with a valid username and
5001 password (which can be mapped using the \fB"username
5002 map"\fP parameter)\&. Encrypted passwords (see the
5003 \fB"encrypted passwords"\fP parameter) can also
5004 be used in this security mode\&. Parameters such as
5005 \fB"user"\fP and \fB"guest only"\fP, if set
5006 are then applied and may change the UNIX user to use on this
5007 connection, but only after the user has been successfully
5010 \fINote\fP that the name of the resource being requested is
5011 \fI*not*\fP sent to the server until after the server has successfully
5012 authenticated the client\&. This is why guest shares don\'t work in user
5013 level security without allowing the server to automatically map unknown
5014 users into the \fB"guest account"\fP\&. See the
5015 \fB"map to guest"\fP parameter for details on
5018 See also the section \fB"NOTE ABOUT USERNAME/PASSWORD
5021 .IP "\fB"security=server"\fP"
5023 In this mode Samba will try to validate the username/password by
5024 passing it to another SMB server, such as an NT box\&. If this fails it
5025 will revert to \fB"security = user"\fP, but note that if encrypted
5026 passwords have been negotiated then Samba cannot revert back to
5027 checking the UNIX password file, it must have a valid smbpasswd file
5028 to check users against\&. See the documentation file in the docs/
5029 directory ENCRYPTION\&.txt for details on how to set this up\&.
5031 \fINote\fP that from the clients point of view \fB"security=server"\fP is
5032 the same as \fB"security=user"\fP\&. It only
5033 affects how the server deals with the authentication, it does not in
5034 any way affect what the client sees\&.
5036 \fINote\fP that the name of the resource being requested is
5037 \fI*not*\fP sent to the server until after the server has successfully
5038 authenticated the client\&. This is why guest shares don\'t work in server
5039 level security without allowing the server to automatically map unknown
5040 users into the \fB"guest account"\fP\&. See the
5041 \fB"map to guest"\fP parameter for details on
5044 See also the section \fB"NOTE ABOUT USERNAME/PASSWORD
5047 See also the \fB"password server"\fP parameter\&.
5048 and the \fB"encrypted passwords"\fP parameter\&.
5050 .IP "\fB"security=domain"\fP"
5052 This mode will only work correctly if
5053 \fBsmbpasswd\fP has been used to add this machine
5054 into a Windows NT Domain\&. It expects the \fB"encrypted
5055 passwords"\fP parameter to be set to \f(CW"true"\fP\&. In
5056 this mode Samba will try to validate the username/password by passing
5057 it to a Windows NT Primary or Backup Domain Controller, in exactly the
5058 same way that a Windows NT Server would do\&.
5060 \fINote\fP that a valid UNIX user must still exist as well as the
5061 account on the Domain Controller to allow Samba to have a valid
5062 UNIX account to map file access to\&.
5064 \fINote\fP that from the clients point of view \fB"security=domain"\fP is
5065 the same as \fB"security=user"\fP\&. It only
5066 affects how the server deals with the authentication, it does not in
5067 any way affect what the client sees\&.
5069 \fINote\fP that the name of the resource being requested is
5070 \fI*not*\fP sent to the server until after the server has successfully
5071 authenticated the client\&. This is why guest shares don\'t work in domain
5072 level security without allowing the server to automatically map unknown
5073 users into the \fB"guest account"\fP\&. See the
5074 \fB"map to guest"\fP parameter for details on
5077 e,(BUG:) There is currently a bug in the implementation of
5078 \fB"security=domain\fP with respect to multi-byte character
5079 set usernames\&. The communication with a Domain Controller
5080 must be done in UNICODE and Samba currently does not widen
5081 multi-byte user names to UNICODE correctly, thus a multi-byte
5082 username will not be recognized correctly at the Domain Controller\&.
5083 This issue will be addressed in a future release\&.
5085 See also the section \fB"NOTE ABOUT USERNAME/PASSWORD
5088 See also the \fB"password server"\fP parameter\&.
5089 and the \fB"encrypted passwords"\fP parameter\&.
5093 \f(CW security = USER\fP
5096 \f(CW security = DOMAIN\fP
5098 .IP "\fBserver string (G)\fP"
5100 This controls what string will show up in the printer comment box in
5101 print manager and next to the IPC connection in \f(CW"net view"\fP\&. It can be
5102 any string that you wish to show to your users\&.
5104 It also sets what will appear in browse lists next to the machine
5107 A \f(CW"%v"\fP will be replaced with the Samba version number\&.
5109 A \f(CW"%h"\fP will be replaced with the hostname\&.
5112 \f(CW server string = Samba %v\fP
5115 \f(CW server string = University of GNUs Samba Server\fP
5117 .IP "\fBset directory (S)\fP"
5119 If \f(CW"set directory = no"\fP, then users of the service may not use the
5120 setdir command to change directory\&.
5122 The setdir command is only implemented in the Digital Pathworks
5123 client\&. See the Pathworks documentation for details\&.
5126 \f(CW set directory = no\fP
5129 \f(CW set directory = yes\fP
5131 .IP "\fBshare modes (S)\fP"
5133 This enables or disables the honoring of the \f(CW"share modes"\fP during a
5134 file open\&. These modes are used by clients to gain exclusive read or
5135 write access to a file\&.
5137 These open modes are not directly supported by UNIX, so they are
5138 simulated using shared memory, or lock files if your UNIX doesn\'t
5139 support shared memory (almost all do)\&.
5141 The share modes that are enabled by this option are DENY_DOS,
5142 DENY_ALL, DENY_READ, DENY_WRITE, DENY_NONE and DENY_FCB\&.
5144 This option gives full share compatibility and enabled by default\&.
5146 You should \fI*NEVER*\fP turn this parameter off as many Windows
5147 applications will break if you do so\&.
5150 \f(CW share modes = yes\fP
5152 .IP "\fBshared mem size (G)\fP"
5154 It specifies the size of the shared memory (in bytes) to use between
5155 \fBsmbd\fP processes\&. This parameter defaults to one
5156 megabyte of shared memory\&. It is possible that if you have a large
5157 server with many files open simultaneously that you may need to
5158 increase this parameter\&. Signs that this parameter is set too low are
5159 users reporting strange problems trying to save files (locking errors)
5160 and error messages in the smbd log looking like \f(CW"ERROR
5161 smb_shm_alloc : alloc of XX bytes failed"\fP\&.
5164 \f(CW shared mem size = 1048576\fP
5167 \f(CW shared mem size = 5242880 ; Set to 5mb for a large number of files\&.\fP
5169 .IP "\fBshort preserve case (G)\fP"
5171 This boolean parameter controls if new files which conform to 8\&.3
5172 syntax, that is all in upper case and of suitable length, are created
5173 upper case, or if they are forced to be the \f(CW"default"\fP case\&. This
5174 option can be use with \fB"preserve case
5175 =yes"\fP to permit long filenames to retain their
5176 case, while short names are lowered\&. Default \fIYes\fP\&.
5178 See the section on \fBNAME MANGLING\fP\&.
5181 \f(CW short preserve case = yes\fP
5183 .IP "\fBsmb passwd file (G)\fP"
5185 This option sets the path to the encrypted smbpasswd file\&. By default
5186 the path to the smbpasswd file is compiled into Samba\&.
5189 \f(CW smb passwd file= <compiled default>\fP
5192 \f(CW smb passwd file = /usr/samba/private/smbpasswd\fP
5194 .IP "\fBsmbrun (G)\fP"
5196 This sets the full path to the \fBsmbrun\fP binary\&. This defaults to the
5197 value in the Makefile\&.
5199 You must get this path right for many services to work correctly\&.
5201 You should not need to change this parameter so long as Samba
5202 is installed correctly\&.
5205 \f(CW smbrun=<compiled default>\fP
5208 \f(CW smbrun = /usr/local/samba/bin/smbrun\fP
5210 .IP "\fBsocket address (G)\fP"
5212 This option allows you to control what address Samba will listen for
5213 connections on\&. This is used to support multiple virtual interfaces on
5214 the one server, each with a different configuration\&.
5216 By default samba will accept connections on any address\&.
5219 \f(CW socket address = 192\&.168\&.2\&.20\fP
5221 .IP "\fBsocket options (G)\fP"
5223 This option allows you to set socket options to be used when talking
5226 Socket options are controls on the networking layer of the operating
5227 systems which allow the connection to be tuned\&.
5229 This option will typically be used to tune your Samba server for
5230 optimal performance for your local network\&. There is no way that Samba
5231 can know what the optimal parameters are for your net, so you must
5232 experiment and choose them yourself\&. We strongly suggest you read the
5233 appropriate documentation for your operating system first (perhaps
5234 \fB"man setsockopt"\fP will help)\&.
5236 You may find that on some systems Samba will say "Unknown socket
5237 option" when you supply an option\&. This means you either incorrectly
5238 typed it or you need to add an include file to includes\&.h for your OS\&.
5239 If the latter is the case please send the patch to
5240 \fIsamba-bugs@samba\&.org\fP\&.
5242 Any of the supported socket options may be combined in any way you
5243 like, as long as your OS allows it\&.
5245 This is the list of socket options currently settable using this
5280 Those marked with a \f(CW*\fP take an integer argument\&. The others can
5281 optionally take a 1 or 0 argument to enable or disable the option, by
5282 default they will be enabled if you don\'t specify 1 or 0\&.
5284 To specify an argument use the syntax SOME_OPTION=VALUE for example
5285 \f(CWSO_SNDBUF=8192\fP\&. Note that you must not have any spaces before or after
5288 If you are on a local network then a sensible option might be
5290 \f(CWsocket options = IPTOS_LOWDELAY\fP
5292 If you have a local network then you could try:
5294 \f(CWsocket options = IPTOS_LOWDELAY TCP_NODELAY\fP
5296 If you are on a wide area network then perhaps try setting
5299 Note that several of the options may cause your Samba server to fail
5300 completely\&. Use these options with caution!
5303 \f(CW socket options = TCP_NODELAY\fP
5306 \f(CW socket options = IPTOS_LOWDELAY\fP
5310 This variable is part of SSL-enabled Samba\&. This is only available if
5311 the SSL libraries have been compiled on your system and the configure
5312 option \f(CW"--with-ssl"\fP was given at configure time\&.
5314 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5315 enabled by default in any current binary version of Samba\&.
5317 This variable enables or disables the entire SSL mode\&. If it is set to
5318 "no", the SSL enabled samba behaves exactly like the non-SSL samba\&. If
5319 set to "yes", it depends on the variables \fB"ssl
5320 hosts"\fP and \fB"ssl hosts resign"\fP
5321 whether an SSL connection will be required\&.
5328 .IP "\fBssl CA certDir (G)\fP"
5330 This variable is part of SSL-enabled Samba\&. This is only available if
5331 the SSL libraries have been compiled on your system and the configure
5332 option \f(CW"--with-ssl"\fP was given at configure time\&.
5334 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5335 enabled by default in any current binary version of Samba\&.
5337 This variable defines where to look up the Certification
5338 Authorities\&. The given directory should contain one file for each CA
5339 that samba will trust\&. The file name must be the hash value over the
5340 "Distinguished Name" of the CA\&. How this directory is set up is
5341 explained later in this document\&. All files within the directory that
5342 don\'t fit into this naming scheme are ignored\&. You don\'t need this
5343 variable if you don\'t verify client certificates\&.
5346 \f(CW ssl CA certDir = /usr/local/ssl/certs\fP
5348 .IP "\fBssl CA certFile (G)\fP"
5350 This variable is part of SSL-enabled Samba\&. This is only available if
5351 the SSL libraries have been compiled on your system and the configure
5352 option \f(CW"--with-ssl"\fP was given at configure time\&.
5354 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5355 enabled by default in any current binary version of Samba\&.
5357 This variable is a second way to define the trusted CAs\&. The
5358 certificates of the trusted CAs are collected in one big file and this
5359 variable points to the file\&. You will probably only use one of the two
5360 ways to define your CAs\&. The first choice is preferable if you have
5361 many CAs or want to be flexible, the second is preferable if you only
5362 have one CA and want to keep things simple (you won\'t need to create
5363 the hashed file names)\&. You don\'t need this variable if you don\'t
5364 verify client certificates\&.
5367 \f(CW ssl CA certFile = /usr/local/ssl/certs/trustedCAs\&.pem\fP
5369 .IP "\fBssl ciphers (G)\fP"
5371 This variable is part of SSL-enabled Samba\&. This is only available if
5372 the SSL libraries have been compiled on your system and the configure
5373 option \f(CW"--with-ssl"\fP was given at configure time\&.
5375 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5376 enabled by default in any current binary version of Samba\&.
5378 This variable defines the ciphers that should be offered during SSL
5379 negotiation\&. You should not set this variable unless you know what you
5382 .IP "\fBssl client cert (G)\fP"
5384 This variable is part of SSL-enabled Samba\&. This is only available if
5385 the SSL libraries have been compiled on your system and the configure
5386 option \f(CW"--with-ssl"\fP was given at configure time\&.
5388 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5389 enabled by default in any current binary version of Samba\&.
5391 The certificate in this file is used by
5392 \fBsmbclient\fP if it exists\&. It\'s needed if the
5393 server requires a client certificate\&.
5396 \f(CW ssl client cert = /usr/local/ssl/certs/smbclient\&.pem\fP
5398 .IP "\fBssl client key (G)\fP"
5400 This variable is part of SSL-enabled Samba\&. This is only available if
5401 the SSL libraries have been compiled on your system and the configure
5402 option \f(CW"--with-ssl"\fP was given at configure time\&.
5404 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5405 enabled by default in any current binary version of Samba\&.
5407 This is the private key for \fBsmbclient\fP\&. It\'s
5408 only needed if the client should have a certificate\&.
5411 \f(CW ssl client key = /usr/local/ssl/private/smbclient\&.pem\fP
5413 .IP "\fBssl compatibility (G)\fP"
5415 This variable is part of SSL-enabled Samba\&. This is only available if
5416 the SSL libraries have been compiled on your system and the configure
5417 option \f(CW"--with-ssl"\fP was given at configure time\&.
5419 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5420 enabled by default in any current binary version of Samba\&.
5422 This variable defines whether SSLeay should be configured for bug
5423 compatibility with other SSL implementations\&. This is probably not
5424 desirable because currently no clients with SSL implementations other
5425 than SSLeay exist\&.
5428 \f(CW ssl compatibility = no\fP
5430 .IP "\fBssl hosts (G)\fP"
5432 See \fB"ssl hosts resign"\fP\&.
5434 .IP "\fBssl hosts resign (G)\fP"
5436 This variable is part of SSL-enabled Samba\&. This is only available if
5437 the SSL libraries have been compiled on your system and the configure
5438 option \f(CW"--with-ssl"\fP was given at configure time\&.
5440 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5441 enabled by default in any current binary version of Samba\&.
5443 These two variables define whether samba will go into SSL mode or
5444 not\&. If none of them is defined, samba will allow only SSL
5445 connections\&. If the \fB"ssl hosts"\fP variable lists
5446 hosts (by IP-address, IP-address range, net group or name), only these
5447 hosts will be forced into SSL mode\&. If the \fB"ssl hosts resign"\fP
5448 variable lists hosts, only these hosts will NOT be forced into SSL
5449 mode\&. The syntax for these two variables is the same as for the
5450 \fB"hosts allow"\fP and \fB"hosts
5451 deny"\fP pair of variables, only that the subject of the
5452 decision is different: It\'s not the access right but whether SSL is
5453 used or not\&. See the \fB"allow hosts"\fP parameter for
5454 details\&. The example below requires SSL connections from all hosts
5455 outside the local net (which is 192\&.168\&.*\&.*)\&.
5458 \f(CW ssl hosts = <empty string>\fP
5459 \f(CW ssl hosts resign = <empty string>\fP
5462 \f(CW ssl hosts resign = 192\&.168\&.\fP
5464 .IP "\fBssl require clientcert (G)\fP"
5466 This variable is part of SSL-enabled Samba\&. This is only available if
5467 the SSL libraries have been compiled on your system and the configure
5468 option \f(CW"--with-ssl"\fP was given at configure time\&.
5470 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5471 enabled by default in any current binary version of Samba\&.
5473 If this variable is set to \f(CW"yes"\fP, the server will not tolerate
5474 connections from clients that don\'t have a valid certificate\&. The
5475 directory/file given in \fB"ssl CA certDir"\fP and
5476 \fB"ssl CA certFile"\fP will be used to look up the
5477 CAs that issued the client\'s certificate\&. If the certificate can\'t be
5478 verified positively, the connection will be terminated\&. If this
5479 variable is set to \f(CW"no"\fP, clients don\'t need certificates\&. Contrary
5480 to web applications you really \fI*should*\fP require client
5481 certificates\&. In the web environment the client\'s data is sensitive
5482 (credit card numbers) and the server must prove to be trustworthy\&. In
5483 a file server environment the server\'s data will be sensitive and the
5484 clients must prove to be trustworthy\&.
5487 \f(CW ssl require clientcert = no\fP
5489 .IP "\fBssl require servercert (G)\fP"
5491 This variable is part of SSL-enabled Samba\&. This is only available if
5492 the SSL libraries have been compiled on your system and the configure
5493 option \f(CW"--with-ssl"\fP was given at configure time\&.
5495 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5496 enabled by default in any current binary version of Samba\&.
5498 If this variable is set to \f(CW"yes"\fP, the
5499 \fBsmbclient\fP will request a certificate from
5500 the server\&. Same as \fB"ssl require
5501 clientcert"\fP for the server\&.
5504 \f(CW ssl require servercert = no\fP
5506 .IP "\fBssl server cert (G)\fP"
5508 This variable is part of SSL-enabled Samba\&. This is only available if
5509 the SSL libraries have been compiled on your system and the configure
5510 option \f(CW"--with-ssl"\fP was given at configure time\&.
5512 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5513 enabled by default in any current binary version of Samba\&.
5515 This is the file containing the server\'s certificate\&. The server _must_
5516 have a certificate\&. The file may also contain the server\'s private key\&.
5517 See later for how certificates and private keys are created\&.
5520 \f(CW ssl server cert = <empty string>\fP
5522 .IP "\fBssl server key (G)\fP"
5524 This variable is part of SSL-enabled Samba\&. This is only available if
5525 the SSL libraries have been compiled on your system and the configure
5526 option \f(CW"--with-ssl"\fP was given at configure time\&.
5528 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5529 enabled by default in any current binary version of Samba\&.
5531 This file contains the private key of the server\&. If this variable is
5532 not defined, the key is looked up in the certificate file (it may be
5533 appended to the certificate)\&. The server \fI*must*\fP have a private key
5534 and the certificate \fI*must*\fP match this private key\&.
5537 \f(CW ssl server key = <empty string>\fP
5539 .IP "\fBssl version (G)\fP"
5541 This variable is part of SSL-enabled Samba\&. This is only available if
5542 the SSL libraries have been compiled on your system and the configure
5543 option \f(CW"--with-ssl"\fP was given at configure time\&.
5545 \fINote\fP that for export control reasons this code is \fI**NOT**\fP
5546 enabled by default in any current binary version of Samba\&.
5548 This enumeration variable defines the versions of the SSL protocol
5549 that will be used\&. \f(CW"ssl2or3"\fP allows dynamic negotiation of SSL v2
5550 or v3, \f(CW"ssl2"\fP results in SSL v2, \f(CW"ssl3"\fP results in SSL v3 and
5551 "tls1" results in TLS v1\&. TLS (Transport Layer Security) is the
5552 (proposed?) new standard for SSL\&.
5555 \f(CW ssl version = "ssl2or3"\fP
5557 .IP "\fBstat cache (G)\fP"
5559 This parameter determines if \fBsmbd\fP will use a
5560 cache in order to speed up case insensitive name mappings\&. You should
5561 never need to change this parameter\&.
5564 \f(CW stat cache = yes\fP
5566 .IP "\fBstat cache size (G)\fP"
5568 This parameter determines the number of entries in the \fBstat
5569 cache\fP\&. You should never need to change this parameter\&.
5572 \f(CW stat cache size = 50\fP
5574 .IP "\fBstatus (G)\fP"
5576 This enables or disables logging of connections to a status file that
5577 \fBsmbstatus\fP can read\&.
5579 With this disabled \fBsmbstatus\fP won\'t be able
5580 to tell you what connections are active\&. You should never need to
5581 change this parameter\&.
5586 .IP "\fBstrict locking (S)\fP"
5588 This is a boolean that controls the handling of file locking in the
5589 server\&. When this is set to \f(CW"yes"\fP the server will check every read and
5590 write access for file locks, and deny access if locks exist\&. This can
5591 be slow on some systems\&.
5593 When strict locking is \f(CW"no"\fP the server does file lock checks only
5594 when the client explicitly asks for them\&.
5596 Well behaved clients always ask for lock checks when it is important,
5597 so in the vast majority of cases \fB"strict locking = no"\fP is
5601 \f(CW strict locking = no\fP
5604 \f(CW strict locking = yes\fP
5606 .IP "\fBstrict sync (S)\fP"
5608 Many Windows applications (including the Windows 98 explorer shell)
5609 seem to confuse flushing buffer contents to disk with doing a sync to
5610 disk\&. Under UNIX, a sync call forces the process to be suspended until
5611 the kernel has ensured that all outstanding data in kernel disk
5612 buffers has been safely stored onto stable storage\&. This is very slow
5613 and should only be done rarely\&. Setting this parameter to "no" (the
5614 default) means that smbd ignores the Windows applications requests for
5615 a sync call\&. There is only a possibility of losing data if the
5616 operating system itself that Samba is running on crashes, so there is
5617 little danger in this default setting\&. In addition, this fixes many
5618 performance problems that people have reported with the new Windows98
5619 explorer shell file copies\&.
5621 See also the \fB"sync always"\fP parameter\&.
5624 \f(CW strict sync = no\fP
5627 \f(CW strict sync = yes\fP
5629 .IP "\fBstrip dot (G)\fP"
5631 This is a boolean that controls whether to strip trailing dots off
5632 UNIX filenames\&. This helps with some CDROMs that have filenames ending
5636 \f(CW strip dot = no\fP
5639 \f(CW strip dot = yes\fP
5641 .IP "\fBsync always (S)\fP"
5643 This is a boolean parameter that controls whether writes will always
5644 be written to stable storage before the write call returns\&. If this is
5645 false then the server will be guided by the client\'s request in each
5646 write call (clients can set a bit indicating that a particular write
5647 should be synchronous)\&. If this is true then every write will be
5648 followed by a fsync() call to ensure the data is written to disk\&.
5649 Note that the \fB"strict sync"\fP parameter must be
5650 set to \f(CW"yes"\fP in order for this parameter to have any affect\&.
5652 See also the \fB"strict sync"\fP parameter\&.
5655 \f(CW sync always = no\fP
5658 \f(CW sync always = yes\fP
5660 .IP "\fBsyslog (G)\fP"
5662 This parameter maps how Samba debug messages are logged onto the
5663 system syslog logging levels\&. Samba debug level zero maps onto syslog
5664 LOG_ERR, debug level one maps onto LOG_WARNING, debug level two maps
5665 onto LOG_NOTICE, debug level three maps onto LOG_INFO\&. All higher
5666 levels are mapped to LOG_DEBUG\&.
5668 This paramter sets the threshold for sending messages to syslog\&.
5669 Only messages with debug level less than this value will be sent
5675 .IP "\fBsyslog only (G)\fP"
5677 If this parameter is set then Samba debug messages are logged into the
5678 system syslog only, and not to the debug log files\&.
5681 \f(CW syslog only = no\fP
5683 .IP "\fBtime offset (G)\fP"
5685 This parameter is a setting in minutes to add to the normal GMT to
5686 local time conversion\&. This is useful if you are serving a lot of PCs
5687 that have incorrect daylight saving time handling\&.
5690 \f(CW time offset = 0\fP
5693 \f(CW time offset = 60\fP
5696 .IP "\fBtime server (G)\fP"
5698 This parameter determines if \fBnmbd\fP advertises
5699 itself as a time server to Windows clients\&. The default is False\&.
5702 \f(CW time server = False\fP
5705 \f(CW time server = True\fP
5707 .IP "\fBtimestamp logs (G)\fP"
5709 Samba2\&.0 will a timestamps to all log entries by default\&. This
5710 can be distracting if you are attempting to debug a problem\&. This
5711 parameter allows the timestamping to be turned off\&.
5714 \f(CW timestamp logs = True\fP
5717 \f(CW timestamp logs = False\fP
5719 .IP "\fBunix password sync (G)\fP"
5721 This boolean parameter controls whether Samba attempts to synchronize
5722 the UNIX password with the SMB password when the encrypted SMB
5723 password in the smbpasswd file is changed\&. If this is set to true the
5724 program specified in the \fB"passwd program"\fP
5725 parameter is called \fI*AS ROOT*\fP - to allow the new UNIX password to be
5726 set without access to the old UNIX password (as the SMB password has
5727 change code has no access to the old password cleartext, only the
5728 new)\&. By default this is set to \f(CW"false"\fP\&.
5730 See also \fB"passwd program"\fP, \fB"passwd
5734 \f(CW unix password sync = False\fP
5737 \f(CW unix password sync = True\fP
5739 .IP "\fBunix realname (G)\fP"
5741 This boolean parameter when set causes samba to supply the real name
5742 field from the unix password file to the client\&. This is useful for
5743 setting up mail clients and WWW browsers on systems used by more than
5747 \f(CW unix realname = no\fP
5750 \f(CW unix realname = yes\fP
5752 .IP "\fBupdate encrypted (G)\fP"
5754 This boolean parameter allows a user logging on with a plaintext
5755 password to have their encrypted (hashed) password in the smbpasswd
5756 file to be updated automatically as they log on\&. This option allows a
5757 site to migrate from plaintext password authentication (users
5758 authenticate with plaintext password over the wire, and are checked
5759 against a UNIX account database) to encrypted password authentication
5760 (the SMB challenge/response authentication mechanism) without forcing
5761 all users to re-enter their passwords via smbpasswd at the time the
5762 change is made\&. This is a convenience option to allow the change over
5763 to encrypted passwords to be made over a longer period\&. Once all users
5764 have encrypted representations of their passwords in the smbpasswd
5765 file this parameter should be set to \f(CW"off"\fP\&.
5767 In order for this parameter to work correctly the \fB"encrypt
5768 passwords"\fP parameter must be set to \f(CW"no"\fP when
5769 this parameter is set to \f(CW"yes"\fP\&.
5771 Note that even when this parameter is set a user authenticating to
5772 smbd must still enter a valid password in order to connect correctly,
5773 and to update their hashed (smbpasswd) passwords\&.
5776 \f(CW update encrypted = no\fP
5779 \f(CW update encrypted = yes\fP
5781 .IP "\fBuse rhosts (G)\fP"
5783 If this global parameter is a true, it specifies that the UNIX users
5784 \f(CW"\&.rhosts"\fP file in their home directory will be read to find the
5785 names of hosts and users who will be allowed access without specifying
5788 NOTE: The use of \fBuse rhosts\fP can be a major security hole\&. This is
5789 because you are trusting the PC to supply the correct username\&. It is
5790 very easy to get a PC to supply a false username\&. I recommend that the
5791 \fBuse rhosts\fP option be only used if you really know what you are
5795 \f(CW use rhosts = no\fP
5798 \f(CW use rhosts = yes\fP
5800 .IP "\fBuser (S)\fP"
5802 Synonym for \fB"username"\fP\&.
5804 .IP "\fBusers (S)\fP"
5806 Synonym for \fB"username"\fP\&.
5808 .IP "\fBusername (S)\fP"
5810 Multiple users may be specified in a comma-delimited list, in which
5811 case the supplied password will be tested against each username in
5812 turn (left to right)\&.
5814 The \fBusername=\fP line is needed only when the PC is unable to supply
5815 its own username\&. This is the case for the COREPLUS protocol or where
5816 your users have different WfWg usernames to UNIX usernames\&. In both
5817 these cases you may also be better using the \f(CW\e\eserver\eshare%user\fP
5820 The \fBusername=\fP line is not a great solution in many cases as it
5821 means Samba will try to validate the supplied password against each of
5822 the usernames in the username= line in turn\&. This is slow and a bad
5823 idea for lots of users in case of duplicate passwords\&. You may get
5824 timeouts or security breaches using this parameter unwisely\&.
5826 Samba relies on the underlying UNIX security\&. This parameter does not
5827 restrict who can login, it just offers hints to the Samba server as to
5828 what usernames might correspond to the supplied password\&. Users can
5829 login as whoever they please and they will be able to do no more
5830 damage than if they started a telnet session\&. The daemon runs as the
5831 user that they log in as, so they cannot do anything that user cannot
5834 To restrict a service to a particular set of users you can use the
5835 \fB"valid users="\fP parameter\&.
5837 If any of the usernames begin with a \f(CW\'@\'\fP then the name will be
5838 looked up first in the yp netgroups list (if Samba is compiled with
5839 netgroup support), followed by a lookup in the UNIX groups database
5840 and will expand to a list of all users in the group of that name\&.
5842 If any of the usernames begin with a \f(CW\'+\'\fP then the name will be
5843 looked up only in the UNIX groups database and will expand to a list
5844 of all users in the group of that name\&.
5846 If any of the usernames begin with a \f(CW\'&\'\fP then the name will be
5847 looked up only in the yp netgroups database (if Samba is compiled with
5848 netgroup support) and will expand to a list of all users in the
5849 netgroup group of that name\&.
5851 Note that searching though a groups database can take quite some time,
5852 and some clients may time out during the search\&.
5854 See the section \fB"NOTE ABOUT USERNAME/PASSWORD
5855 VALIDATION"\fP for more
5856 information on how this parameter determines access to the services\&.
5859 \f(CW The guest account if a guest service, else the name of the service\&.\fP
5867 username = fred, mary, jack, jane, @users, @pcgroup
5873 .IP "\fBusername level (G)\fP"
5875 This option helps Samba to try and \'guess\' at the real UNIX username,
5876 as many DOS clients send an all-uppercase username\&. By default Samba
5877 tries all lowercase, followed by the username with the first letter
5878 capitalized, and fails if the username is not found on the UNIX
5881 If this parameter is set to non-zero the behavior changes\&. This
5882 parameter is a number that specifies the number of uppercase
5883 combinations to try whilst trying to determine the UNIX user name\&. The
5884 higher the number the more combinations will be tried, but the slower
5885 the discovery of usernames will be\&. Use this parameter when you have
5886 strange usernames on your UNIX machine, such as \f(CW"AstrangeUser"\fP\&.
5889 \f(CW username level = 0\fP
5892 \f(CW username level = 5\fP
5894 .IP "\fBusername map (G)\fP"
5896 This option allows you to specify a file containing a mapping of
5897 usernames from the clients to the server\&. This can be used for several
5898 purposes\&. The most common is to map usernames that users use on DOS or
5899 Windows machines to those that the UNIX box uses\&. The other is to map
5900 multiple users to a single username so that they can more easily share
5903 The map file is parsed line by line\&. Each line should contain a single
5904 UNIX username on the left then a \f(CW\'=\'\fP followed by a list of
5905 usernames on the right\&. The list of usernames on the right may contain
5906 names of the form @group in which case they will match any UNIX
5907 username in that group\&. The special client name \f(CW\'*\'\fP is a wildcard
5908 and matches any name\&. Each line of the map file may be up to 1023
5911 The file is processed on each line by taking the supplied username and
5912 comparing it with each username on the right hand side of the \f(CW\'=\'\fP
5913 signs\&. If the supplied name matches any of the names on the right hand
5914 side then it is replaced with the name on the left\&. Processing then
5915 continues with the next line\&.
5917 If any line begins with a \f(CW\'#\'\fP or a \f(CW\';\'\fP then it is ignored
5919 If any line begins with an \f(CW\'!\'\fP then the processing will stop after
5920 that line if a mapping was done by the line\&. Otherwise mapping
5921 continues with every line being processed\&. Using \f(CW\'!\'\fP is most
5922 useful when you have a wildcard mapping line later in the file\&.
5924 For example to map from the name \f(CW"admin"\fP or \f(CW"administrator"\fP to
5925 the UNIX name \f(CW"root"\fP you would use:
5927 \f(CW root = admin administrator\fP
5929 Or to map anyone in the UNIX group \f(CW"system"\fP to the UNIX name
5930 \f(CW"sys"\fP you would use:
5932 \f(CW sys = @system\fP
5934 You can have as many mappings as you like in a username map file\&.
5936 If your system supports the NIS NETGROUP option then the netgroup
5937 database is checked before the \f(CW/etc/group\fP database for matching
5940 You can map Windows usernames that have spaces in them by using double
5941 quotes around the name\&. For example:
5943 \f(CW tridge = "Andrew Tridgell"\fP
5945 would map the windows username \f(CW"Andrew Tridgell"\fP to the unix
5948 The following example would map mary and fred to the unix user sys,
5949 and map the rest to guest\&. Note the use of the \f(CW\'!\'\fP to tell Samba
5950 to stop processing if it gets a match on that line\&.
5963 Note that the remapping is applied to all occurrences of
5964 usernames\&. Thus if you connect to \f(CW"\e\eserver\efred"\fP and \f(CW"fred"\fP
5965 is remapped to \f(CW"mary"\fP then you will actually be connecting to
5966 \f(CW"\e\eserver\emary"\fP and will need to supply a password suitable for
5967 \f(CW"mary"\fP not \f(CW"fred"\fP\&. The only exception to this is the username
5968 passed to the \fB"password server"\fP (if you have
5969 one)\&. The password server will receive whatever username the client
5970 supplies without modification\&.
5972 Also note that no reverse mapping is done\&. The main effect this has is
5973 with printing\&. Users who have been mapped may have trouble deleting
5974 print jobs as PrintManager under WfWg will think they don\'t own the
5978 \f(CW no username map\fP
5981 \f(CW username map = /usr/local/samba/lib/users\&.map\fP
5983 .IP "\fBvalid chars (S)\fP"
5985 The option allows you to specify additional characters that should be
5986 considered valid by the server in filenames\&. This is particularly
5987 useful for national character sets, such as adding u-umlaut or a-ring\&.
5989 The option takes a list of characters in either integer or character
5990 form with spaces between them\&. If you give two characters with a colon
5991 between them then it will be taken as an lowercase:uppercase pair\&.
5993 If you have an editor capable of entering the characters into the
5994 config file then it is probably easiest to use this method\&. Otherwise
5995 you can specify the characters in octal, decimal or hexadecimal form
5996 using the usual C notation\&.
5998 For example to add the single character \f(CW\'Z\'\fP to the charset (which
5999 is a pointless thing to do as it\'s already there) you could do one of
6008 valid chars = 0132:0172
6014 The last two examples above actually add two characters, and alter the
6015 uppercase and lowercase mappings appropriately\&.
6017 Note that you MUST specify this parameter after the \fB"client
6018 code page"\fP parameter if you have both set\&. If
6019 \fB"client code page"\fP is set after the
6020 \fB"valid chars"\fP parameter the \fB"valid chars"\fP settings will be
6023 See also the \fB"client code page"\fP parameter\&.
6030 Samba defaults to using a reasonable set of valid characters
6038 \f(CW valid chars = 0345:0305 0366:0326 0344:0304\fP
6040 The above example allows filenames to have the Swedish characters in
6043 NOTE: It is actually quite difficult to correctly produce a \fB"valid
6044 chars"\fP line for a particular system\&. To automate the process
6045 \fItino@augsburg\&.net\fP has written a package called \fB"validchars"\fP
6046 which will automatically produce a complete \fB"valid chars"\fP line for
6047 a given client system\&. Look in the examples/validchars/ subdirectory
6048 of your Samba source code distribution for this package\&.
6050 .IP "\fBvalid users (S)\fP"
6052 This is a list of users that should be allowed to login to this
6053 service\&. Names starting with \f(CW\'@\'\fP, \f(CW\'+\'\fP and \f(CW\'&\'\fP are
6054 interpreted using the same rules as described in the \fB"invalid
6055 users"\fP parameter\&.
6057 If this is empty (the default) then any user can login\&. If a username
6058 is in both this list and the \fB"invalid users"\fP
6059 list then access is denied for that user\&.
6061 The current servicename is substituted for
6062 \fB"%S"\fP\&. This is useful in the
6063 \fB[homes]\fP section\&.
6065 See also \fB"invalid users"\fP\&.
6068 \f(CW No valid users list\&. (anyone can login)\fP
6071 \f(CW valid users = greg, @pcusers\fP
6073 .IP "\fBveto files(S)\fP"
6075 This is a list of files and directories that are neither visible nor
6076 accessible\&. Each entry in the list must be separated by a \f(CW\'/\'\fP,
6077 which allows spaces to be included in the entry\&. \f(CW\'*\'\fP and \f(CW\'?\'\fP
6078 can be used to specify multiple files or directories as in DOS
6081 Each entry must be a unix path, not a DOS path and must \fI*not*\fP include the
6082 unix directory separator \f(CW\'/\'\fP\&.
6084 Note that the \fB"case sensitive"\fP option is
6085 applicable in vetoing files\&.
6087 One feature of the veto files parameter that it is important to be
6088 aware of, is that if a directory contains nothing but files that match
6089 the veto files parameter (which means that Windows/DOS clients cannot
6090 ever see them) is deleted, the veto files within that directory *are
6091 automatically deleted* along with it, if the user has UNIX permissions
6094 Setting this parameter will affect the performance of Samba, as it
6095 will be forced to check all files and directories for a match as they
6098 See also \fB"hide files"\fP and \fB"case
6102 \f(CW No files or directories are vetoed\&.\fP
6113 Veto any files containing the word Security,
6114 any ending in \&.tmp, and any directory containing the
6117 veto files = /*Security*/*\&.tmp/*root*/
6129 Veto the Apple specific files that a NetAtalk server
6132 veto files = /\&.AppleDouble/\&.bin/\&.AppleDesktop/Network Trash Folder/
6138 .IP "\fBveto oplock files (S)\fP"
6140 This parameter is only valid when the \fB"oplocks"\fP
6141 parameter is turned on for a share\&. It allows the Samba administrator
6142 to selectively turn off the granting of oplocks on selected files that
6143 match a wildcarded list, similar to the wildcarded list used in the
6144 \fB"veto files"\fP parameter\&.
6147 \f(CW No files are vetoed for oplock grants\&.\fP
6151 You might want to do this on files that you know will be heavily
6152 contended for by clients\&. A good example of this is in the NetBench
6153 SMB benchmark program, which causes heavy client contention for files
6154 ending in \f(CW"\&.SEM"\fP\&. To cause Samba not to grant oplocks on these
6155 files you would use the line (either in the \fB[global]\fP
6156 section or in the section for the particular NetBench share :
6158 \f(CW veto oplock files = /*\&.SEM/\fP
6160 .IP "\fBvolume (S)\fP"
6162 This allows you to override the volume label returned for a
6163 share\&. Useful for CDROMs with installation programs that insist on a
6164 particular volume label\&.
6166 The default is the name of the share\&.
6168 .IP "\fBwide links (S)\fP"
6170 This parameter controls whether or not links in the UNIX file system
6171 may be followed by the server\&. Links that point to areas within the
6172 directory tree exported by the server are always allowed; this
6173 parameter controls access only to areas that are outside the directory
6174 tree being exported\&.
6177 \f(CW wide links = yes\fP
6180 \f(CW wide links = no\fP
6182 .IP "\fBwins proxy (G)\fP"
6184 This is a boolean that controls if \fBnmbd\fP will
6185 respond to broadcast name queries on behalf of other hosts\&. You may
6186 need to set this to \f(CW"yes"\fP for some older clients\&.
6189 \f(CW wins proxy = no\fP
6191 .IP "\fBwins server (G)\fP"
6193 This specifies the IP address (or DNS name: IP address for preference)
6194 of the WINS server that \fBnmbd\fP should register with\&.
6195 If you have a WINS server on your network then you should set this to
6196 the WINS server\'s IP\&.
6198 You should point this at your WINS server if you have a
6199 multi-subnetted network\&.
6201 \fINOTE\fP\&. You need to set up Samba to point to a WINS server if you
6202 have multiple subnets and wish cross-subnet browsing to work correctly\&.
6204 See the documentation file BROWSING\&.txt in the docs/ directory of your
6205 Samba source distribution\&.
6208 \f(CW wins server = \fP
6211 \f(CW wins server = 192\&.9\&.200\&.1\fP
6213 .IP "\fBwins support (G)\fP"
6215 This boolean controls if the \fBnmbd\fP process in
6216 Samba will act as a WINS server\&. You should not set this to true
6217 unless you have a multi-subnetted network and you wish a particular
6218 \fBnmbd\fP to be your WINS server\&. Note that you
6219 should \fI*NEVER*\fP set this to true on more than one machine in your
6223 \f(CW wins support = no\fP
6225 .IP "\fBworkgroup (G)\fP"
6227 This controls what workgroup your server will appear to be in when
6228 queried by clients\&. Note that this parameter also controls the Domain
6229 name used with the \fB"security=domain"\fP
6233 \f(CW set at compile time to WORKGROUP\fP
6238 .IP "\fBwritable (S)\fP"
6240 Synonym for \fB"writeable"\fP for people who can\'t spell :-)\&.
6242 .IP "\fBwrite list (S)\fP"
6244 This is a list of users that are given read-write access to a
6245 service\&. If the connecting user is in this list then they will be
6246 given write access, no matter what the \fB"read only"\fP
6247 option is set to\&. The list can include group names using the @group
6250 Note that if a user is in both the read list and the write list then
6251 they will be given write access\&.
6253 See also the \fB"read list"\fP option\&.
6256 \f(CW write list = <empty string>\fP
6259 \f(CW write list = admin, root, @staff\fP
6261 .IP "\fBwrite ok (S)\fP"
6263 Synonym for \fBwriteable\fP\&.
6265 .IP "\fBwrite raw (G)\fP"
6267 This parameter controls whether or not the server will support raw
6268 writes SMB\'s when transferring data from clients\&. You should never
6269 need to change this parameter\&.
6272 \f(CW write raw = yes\fP
6274 .IP "\fBwriteable\fP"
6276 An inverted synonym is \fB"read only"\fP\&.
6278 If this parameter is \f(CW"no"\fP, then users of a service may not create
6279 or modify files in the service\'s directory\&.
6281 Note that a printable service \fB("printable = yes")\fP
6282 will \fI*ALWAYS*\fP allow writing to the directory (user privileges
6283 permitting), but only via spooling operations\&.
6286 \f(CW writeable = no\fP
6303 Although the configuration file permits service names to contain
6304 spaces, your client software may not\&. Spaces will be ignored in
6305 comparisons anyway, so it shouldn\'t be a problem - but be aware of the
6308 On a similar note, many clients - especially DOS clients - limit
6309 service names to eight characters\&. \fBSmbd\fP has no
6310 such limitation, but attempts to connect from such clients will fail
6311 if they truncate the service names\&. For this reason you should
6312 probably keep your service names down to eight characters in length\&.
6314 Use of the \fB[homes]\fP and \fB[printers]\fP
6315 special sections make life for an administrator easy, but the various
6316 combinations of default attributes can be tricky\&. Take extreme care
6317 when designing these sections\&. In particular, ensure that the
6318 permissions on spool directories are correct\&.
6322 This man page is correct for version 2\&.0 of the Samba suite\&.
6326 \fBsmbd (8)\fP, \fBsmbclient (1)\fP,
6327 \fBnmbd (8)\fP, \fBtestparm (1)\fP,
6328 \fBtestprns (1)\fP, \fBSamba\fP,
6329 \fBnmblookup (1)\fP, \fBsmbpasswd (5)\fP,
6330 \fBsmbpasswd (8)\fP\&.
6334 The original Samba software and related utilities were created by
6335 Andrew Tridgell \fIsamba-bugs@samba\&.org\fP\&. Samba is now developed
6336 by the Samba Team as an Open Source project similar to the way the
6337 Linux kernel is developed\&.
6339 The original Samba man pages were written by Karl Auer\&. The man page
6340 sources were converted to YODL format (another excellent piece of Open
6341 Source software, available at
6342 \fBftp://ftp\&.icce\&.rug\&.nl/pub/unix/\fP)
6343 and updated for the Samba2\&.0 release by Jeremy Allison\&.
6344 \fIsamba-bugs@samba\&.org\fP\&.
6346 See \fBsamba (7)\fP to find out how to get a full
6347 list of contributors and details on how to submit bug reports,