ENCRYPTION.txt: Fixed typo.
[ira/wip.git] / docs / manpages / smb.conf.5
1 .TH SMB.CONF 5 "08 Jan 1998" "smb.conf 1.9.18"
2 .SH NAME
3 smb.conf \- configuration file for smbd
4 .SH SYNOPSIS
5 .B smb.conf
6 .SH DESCRIPTION
7 The
8 .B smb.conf
9 file is a configuration file for the Samba suite.
10
11 .B smb.conf
12 contains runtime configuration information for the
13 .B smbd
14 program. The
15 .B smbd
16 program provides LanManager-like services to clients
17 using the SMB protocol.
18 .SH FILE FORMAT
19 The file consists of sections and parameters. A section begins with the 
20 name of the section in square brackets and continues until the next
21 section begins. Sections contain parameters of the form 'name = value'.
22
23 The file is line-based - that is, each newline-terminated line represents
24 either a comment, a section name or a parameter.
25
26 Section and parameter names are not case sensitive.
27
28 Only the first equals sign in a parameter is significant. Whitespace before 
29 or after the first equals sign is discarded. Leading, trailing and internal
30 whitespace in section and parameter names is irrelevant. Leading and
31 trailing whitespace in a parameter value is discarded. Internal whitespace
32 within a parameter value is retained verbatim.
33
34 Any line beginning with a semicolon is ignored, as are lines containing 
35 only whitespace.
36
37 Any line ending in a \e is "continued" on the next line in the
38 customary UNIX fashion.
39
40 The values following the equals sign in parameters are all either a string
41 (no quotes needed) or a boolean, which may be given as yes/no, 0/1 or
42 true/false. Case is not significant in boolean values, but is preserved
43 in string values. Some items such as create modes are numeric.
44 .SH SERVICE DESCRIPTIONS
45 Each section in the configuration file describes a service. The section name
46 is the service name and the parameters within the section define the service's
47 attributes.
48
49 There are three special sections, [global], [homes] and [printers], which are
50 described under 'special sections'. The following notes apply to ordinary 
51 service descriptions.
52
53 A service consists of a directory to which access is being given plus a 
54 description of the access rights which are granted to the user of the 
55 service. Some housekeeping options are also specifiable.
56
57 Services are either filespace services (used by the client as an extension of
58 their native file systems) or printable services (used by the client to access
59 print services on the host running the server).
60
61 Services may be guest services, in which case no password is required to
62 access them. A specified guest account is used to define access privileges
63 in this case.
64
65 Services other than guest services will require a password to access
66 them. The client provides the username. As many clients only provide
67 passwords and not usernames, you may specify a list of usernames to
68 check against the password using the "user=" option in the service
69 definition. 
70
71 Note that the access rights granted by the server are masked by the access
72 rights granted to the specified or guest user by the host system. The 
73 server does not grant more access than the host system grants.
74
75 The following sample section defines a file space service. The user has write
76 access to the path /home/bar. The service is accessed via the service name 
77 "foo":
78
79         [foo]
80                 path = /home/bar
81                 writable = true
82
83 The following sample section defines a printable service. The service is 
84 readonly, but printable. That is, the only write access permitted is via 
85 calls to open, write to and close a spool file. The 'guest ok' parameter 
86 means access will be permitted as the default guest user (specified elsewhere):
87
88         [aprinter]
89                 path = /usr/spool/public
90                 read only = true
91                 printable = true
92                 public = true
93 .SH SPECIAL SECTIONS
94
95 .SS The [global] section
96 .RS 3
97 Parameters in this section apply to the server as a whole, or are defaults
98 for services which do not specifically define certain items. See the notes
99 under 'Parameters' for more information.
100 .RE
101
102 .SS The [homes] section
103 .RS 3
104 If a section called 'homes' is included in the configuration file, services
105 connecting clients to their home directories can be created on the fly by the
106 server.
107
108 When the connection request is made, the existing services are scanned. If a
109 match is found, it is used. If no match is found, the requested service name is
110 treated as a user name and looked up in the local passwords file. If the
111 name exists and the correct password has been given, a service is created
112 by cloning the [homes] section.
113
114 Some modifications are then made to the newly created section:
115
116 .RS 3
117 The service name is changed from 'homes' to the located username
118
119 If no path was given, the path is set to the user's home directory.
120 .RE
121
122 If you decide to use a path= line in your [homes] section then you may
123 find it useful to use the %S macro. For example path=/data/pchome/%S
124 would be useful if you have different home directories for your PCs
125 than for UNIX access.
126
127 This is a fast and simple way to give a large number of clients access to
128 their home directories with a minimum of fuss.
129
130 A similar process occurs if the requested service name is "homes", except that
131 the service name is not changed to that of the requesting user. This method
132 of using the [homes] section works well if different users share a client PC.
133
134 The [homes] section can specify all the parameters a normal service section
135 can specify, though some make more sense than others. The following is a 
136 typical and suitable [homes] section:
137
138         [homes]
139                 writable = yes
140
141 An important point:
142
143 .RS 3
144 If guest access is specified in the [homes] section, all home directories will
145 be accessible to all clients
146 .B without a password.
147 In the very unlikely event
148 that this is actually desirable, it would be wise to also specify read only
149 access.
150 .RE
151 .RE
152
153 Note that the browseable flag for auto home directories will be
154 inherited from the global browseable flag, not the [homes] browseable
155 flag. This is useful as it means setting browseable=no in the [homes]
156 section will hide the [homes] service but make any auto home
157 directories visible.
158
159 .SS The [printers] section
160 .RS 3
161 This section works like [homes], but for printers.
162
163 If a [printers] section occurs in the configuration file, users are able 
164 to connect to any printer specified in the local host's printcap file.
165
166 When a connection request is made, the existing services are scanned. If a
167 match is found, it is used. If no match is found, but a [homes] section
168 exists, it is used as described above. Otherwise, the requested service name is
169 treated as a printer name and the appropriate printcap file is scanned to
170 see if the requested service name is a valid printer name. If a match is
171 found, a new service is created by cloning the [printers] section.
172
173 A few modifications are then made to the newly created section:
174
175 .RS 3
176 The service name is set to the located printer name
177
178 If no printer name was given, the printer name is set to the located printer
179 name
180
181 If the service does not permit guest access and no username was given, the 
182 username is set to the located printer name.
183 .RE
184
185 Note that the [printers] service MUST be printable - if you specify otherwise,
186 the server will refuse to load the configuration file.
187
188 Typically the path specified would be that of a world-writable spool directory
189 with the sticky bit set on it. A typical [printers] entry would look like this:
190
191         [printers]
192                 path = /usr/spool/public
193                 writable = no
194                 public = yes
195                 printable = yes 
196
197 All aliases given for a printer in the printcap file are legitimate printer
198 names as far as the server is concerned. If your printing subsystem doesn't
199 work like that, you will have to set up a pseudo-printcap. This is a file
200 consisting of one or more lines like this:
201
202         alias|alias|alias|alias...
203
204 Each alias should be an acceptable printer name for your printing 
205 subsystem. In the [global] section, specify the new file as your printcap.
206 The server will then only recognise names found in your pseudo-printcap,
207 which of course can contain whatever aliases you like. The same technique
208 could be used simply to limit access to a subset of your local printers.
209
210 An alias, by the way, is defined as any component of the first entry of a 
211 printcap record. Records are separated by newlines, components (if there are 
212 more than one) are separated by vertical bar symbols ("|").
213
214 NOTE: On SYSV systems which use lpstat to determine what printers are
215 defined on the system you may be able to use "printcap name = lpstat" 
216 to automatically obtain a list of printers. See the "printcap name"
217 option for more detils.
218
219 .RE
220 .SH PARAMETERS
221 Parameters define the specific attributes of services.
222
223 Some parameters are specific to the [global] section (eg., security).
224 Some parameters are usable in all sections (eg., create mode). All others are
225 permissible only in normal sections. For the purposes of the following
226 descriptions the [homes] and [printers] sections will be considered normal.
227 The letter 'G' in parentheses indicates that a parameter is specific to the
228 [global] section. The letter 'S' indicates that a parameter can be
229 specified in a service specific section. Note that all S parameters
230 can also be specified in the [global] section - in which case they
231 will define the default behaviour for all services.
232
233 Parameters are arranged here in alphabetical order - this may not create
234 best bedfellows, but at least you can find them! Where there are synonyms,
235 the preferred synonym is described, others refer to the preferred synonym.
236
237 .SS VARIABLE SUBSTITUTIONS
238
239 Many of the strings that are settable in the config file can take
240 substitutions. For example the option "path = /tmp/%u" would be
241 interpreted as "path = /tmp/john" if the user connected with the
242 username john.
243
244 These substitutions are mostly noted in the descriptions below, but
245 there are some general substitutions which apply whenever they might be
246 relevant. These are:
247
248 %S = the name of the current service, if any
249
250 %P = the root directory of the current service, if any
251
252 %u = user name of the current service, if any
253
254 %g = primary group name of %u
255
256 %U = session user name (the user name that the client wanted, not
257 necessarily the same as the one they got)
258
259 %G = primary group name of %U
260
261 %H = the home directory of the user given by %u
262
263 %v = the Samba version
264
265 %h = the hostname that Samba is running on
266
267 %m = the netbios name of the client machine (very useful)
268
269 %L = the netbios name of the server. This allows you to change your
270 config based on what the client calls you. Your server can have a "dual
271 personality".
272
273 %M = the internet name of the client machine
274
275 %N = the name of your NIS home directory server.  This is obtained from
276 your NIS auto.map entry.  If you have not compiled Samba with -DAUTOMOUNT
277 then this value will be the same as %L.
278
279 %R = the selected protocol level after protocol negotiation. As of 
280 Samba 1.9.18 it can be one of CORE, COREPLUS, LANMAN1, LANMAN2 or NT1.
281
282 %d = The process id of the current server process
283
284 %a = the architecture of the remote machine. Only some are recognised,
285 and those may not be 100% reliable. It currently recognises Samba,
286 WfWg, WinNT and Win95. Anything else will be known as "UNKNOWN". If it
287 gets it wrong then sending me a level 3 log should allow me to fix it.
288
289 %I = The IP address of the client machine
290
291 %T = the current date and time
292
293 There are some quite creative things that can be done with these
294 substitutions and other smb.conf options.
295
296 .B New for 1.9.18p3 and above.
297
298 Thanks to a patch from Branko Cibej, Samba can now expand environment
299 variables in the smb.conf file.
300
301 To embed an environment variable, use the syntax :
302
303 %$(ENVIRONMENT_VARIABLE_NAME)
304
305 (substitute 'ENVIRONMENT_VARIABLE_NAME' with the name of the
306 environment variable you wish to have substituted at this point.
307
308 The entire '%$(ENVIRONMENT_VARIABLE_NAME)' string will be replaced
309 by the contents of the environment variable. If a non-existing
310 environment variable is specified, the original string will be
311 left alone (and will probably cause a parsing error in the smb.conf
312 at that point).
313
314 Remember, the environment used will be that of the smbd/nmbd process,
315 not that of the connecting user. As this is usually started at boot 
316 time, then it will be very different from that of a normal user. 
317 Remember to add any special variables into the environment before 
318 starting the master smbd/nmbd.
319
320 If smbd/nmbd is run from inetd, then the environment used will be
321 inherited from inetd. In this case you will need to specify
322 any special variables before starting inetd.
323
324 .SS NAME MANGLING
325
326 Samba supports "name mangling" so that DOS and Windows clients can use
327 files that don't conform to the 8.3 format. It can also be set to adjust
328 the case of 8.3 format filenames.
329
330 There are several options that control the way mangling is performed,
331 and they are grouped here rather than listed separately. For the
332 defaults look at the output of the testparm program.
333
334 All of these options can be set separately for each service (or
335 globally, of course).
336
337 The options are:
338
339 "mangle case = yes/no" controls if names that have characters that
340 aren't of the "default" case are mangled. For example, if this is yes
341 then a name like "Mail" would be mangled. Default no.
342
343 "case sensitive = yes/no" controls whether filenames are case
344 sensitive. If they aren't then Samba must do a filename search and
345 match on passed names. Default no.
346
347 "default case = upper/lower" controls what the default case is for new
348 filenames. Default lower.
349
350 "preserve case = yes/no" controls if new files are created with the
351 case that the client passes, or if they are forced to be the "default"
352 case. Default no.
353
354 "short preserve case = yes/no" controls if new files which conform to 8.3
355 syntax, that is all in upper case and of suitable length, are created
356 upper case, or if they are forced to be the "default" case. This option can
357 be use with "preserve case = yes" to permit long filenames to retain their
358 case, while short names are lowered. Default no.
359
360 .SS COMPLETE LIST OF GLOBAL PARAMETERS
361
362 Here is a list of all global parameters. See the section of each
363 parameter for details.  Note that some are synonyms.
364
365 announce as
366
367 announce version
368
369 auto services
370
371 bind interfaces only
372
373 browse list
374
375 character set
376
377 client code page
378
379 config file
380
381 deadtime
382
383 debuglevel
384
385 default
386
387 default service
388
389 dfree command
390
391 dns proxy
392
393 domain controller
394
395 domain logons
396
397 domain master
398
399 encrypt passwords
400
401 getwd cache
402
403 hide files
404
405 hide dot files
406
407 homedir map
408
409 hosts equiv
410
411 include
412
413 interfaces
414
415 keepalive
416
417 lm announce
418
419 lm interval
420
421 lock dir
422
423 load printers
424
425 local master
426
427 lock directory
428
429 log file
430
431 log level
432
433 logon drive
434
435 logon home
436
437 logon path
438
439 logon script
440
441 lpq cache time
442
443 mangled stack
444
445 max log size
446
447 max mux
448
449 max packet
450
451 max ttl
452
453 max xmit
454
455 max wins ttl
456
457 message command
458
459 min wins ttl
460
461 netbios aliases
462
463 netbios name
464
465 nis homedir
466
467 null passwords
468
469 os level
470
471 packet size
472
473 passwd chat
474
475 passwd program
476
477 password level
478
479 password server
480
481 preferred master
482
483 preload
484
485 printcap name
486
487 printer driver file
488
489 protocol
490
491 read bmpx
492
493 read prediction
494
495 read raw
496
497 read size
498
499 remote announce
500
501 remote browse sync
502
503 root
504
505 root dir
506
507 root directory
508
509 security
510
511 server string
512
513 shared file entries
514
515 shared mem size
516
517 smb passwd file
518
519 smbrun
520
521 socket address
522
523 socket options
524
525 status
526
527 strip dot
528
529 syslog
530
531 syslog only
532
533 time offset
534
535 time server
536
537 unix realname
538
539 username level
540
541 username map
542
543 use rhosts
544
545 valid chars
546
547 win95 bug compatibility
548
549 wins proxy
550
551 wins server
552
553 wins support
554
555 workgroup
556
557 write raw
558
559 .SS COMPLETE LIST OF SERVICE PARAMETERS
560
561 Here is a list of all service parameters. See the section of each
562 parameter for details. Note that some are synonyms.
563
564 admin users
565
566 allow hosts
567
568 alternate permissions
569
570 available
571
572 browseable
573
574 case sensitive
575
576 case sig names
577
578 copy
579
580 create mask
581
582 create mode
583
584 comment
585
586 default case
587
588 delete readonly
589
590 delete veto files
591
592 deny hosts
593
594 directory
595
596 directory mask
597
598 directory mode
599
600 dont descend
601
602 dos filetimes
603
604 exec
605
606 fake oplocks
607
608 follow symlinks
609
610 force create mode
611
612 force directory mode
613
614 force group
615
616 force user
617
618 guest account
619
620 guest ok
621
622 guest only
623
624 hide dot files
625
626 hosts allow
627
628 hosts deny
629
630 invalid users
631
632 locking
633
634 lppause command
635
636 lpq command
637
638 lpresume command
639
640 lprm command
641
642 magic output
643
644 magic script
645
646 mangle case
647
648 mangled names
649
650 mangling char
651
652 map archive
653
654 map hidden
655
656 map system
657
658 max connections
659
660 min print space
661
662 networkstation user login
663
664 only guest
665
666 only user
667
668 oplocks
669
670 path
671
672 postexec
673
674 postscript
675
676 preserve case
677
678 print command
679
680 printer driver
681
682 printer driver location
683
684 printing
685
686 print ok
687
688 printable
689
690 printer
691
692 printer name
693
694 public
695
696 read only
697
698 read list
699
700 revalidate
701
702 root postexec
703
704 root preexec
705
706 set directory
707
708 share modes
709
710 short preserve case
711
712 strict locking
713
714 sync always
715
716 user
717
718 username
719
720 users
721
722 valid users
723
724 veto files
725
726 veto oplock files
727
728 volume
729
730 wide links
731
732 writable
733
734 write ok
735
736 writeable
737
738 write list
739
740 .SS EXPLANATION OF EACH PARAMETER
741 .RS 3
742
743 .SS admin users (S)
744
745 This is a list of users who will be granted administrative privileges
746 on the share. This means that they will do all file operations as the
747 super-user (root).
748
749 You should use this option very carefully, as any user in this list
750 will be able to do anything they like on the share, irrespective of
751 file permissions.
752
753 .B Default:
754         no admin users
755
756 .B Example:
757         admin users = jason
758
759 .SS announce as (G)
760
761 This specifies what type of server nmbd will announce itself as in
762 browse lists. By default this is set to Windows NT. The valid options
763 are "NT", "Win95" or "WfW" meaining Windows NT, Windows 95 and
764 Windows for Workgroups respectively. Do not change this parameter
765 unless you have a specific need to stop Samba appearing as an NT
766 server as this may prevent Samba servers from participating as
767 browser servers correctly.
768
769 .B Default:
770     announce as = NT
771
772 .B Example
773     announce as = Win95
774
775 .SS announce version (G)
776
777 This specifies the major and minor version numbers that nmbd
778 will use when announcing itself as a server. The default is 4.2.
779 Do not change this parameter unless you have a specific need to
780 set a Samba server to be a downlevel server.
781
782 .B Default:
783    announce version = 4.2
784
785 .B Example:
786    announce version = 2.0
787
788 .SS auto services (G)
789 This is a list of services that you want to be automatically added to
790 the browse lists. This is most useful for homes and printers services
791 that would otherwise not be visible.
792
793 Note that if you just want all printers in your printcap file loaded
794 then the "load printers" option is easier.
795
796 .B Default:
797         no auto services
798
799 .B Example:
800         auto services = fred lp colorlp
801
802 .SS allow hosts (S)
803 A synonym for this parameter is 'hosts allow'.
804
805 This parameter is a comma delimited set of hosts which are permitted to access
806 a service. 
807
808 If specified in the [global] section then it will apply to all
809 services, regardless of whether the individual service has a different
810 setting. 
811
812 You can specify the hosts by name or IP number. For example, you could
813 restrict access to only the hosts on a Class C subnet with something like
814 "allow hosts = 150.203.5.". The full syntax of the list is described in
815 the man page
816 .BR hosts_access (5).
817
818 You can also specify hosts by network/netmask pairs and by netgroup
819 names if your system supports netgroups. The EXCEPT keyword can also
820 be used to limit a wildcard list. The following examples may provide
821 some help:
822
823 Example 1: allow all IPs in 150.203.*.* except one
824
825         hosts allow = 150.203. EXCEPT 150.203.6.66
826
827 Example 2: allow hosts that match the given network/netmask
828
829         hosts allow = 150.203.15.0/255.255.255.0
830
831 Example 3: allow a couple of hosts
832
833         hosts allow = lapland, arvidsjaur
834
835 Example 4: allow only hosts in netgroup "foonet" or localhost, but 
836 deny access from one particular host
837
838         hosts allow = @foonet, localhost
839         hosts deny = pirate
840
841 Note that access still requires suitable user-level passwords.
842
843 See
844 .BR testparm (1)
845 for a way of testing your host access to see if it
846 does what you expect.
847
848 .B Default:
849         none (i.e., all hosts permitted access)
850
851 .B Example:
852         allow hosts = 150.203.5. myhost.mynet.edu.au
853
854 .SS alternate permissions (S)
855
856 This option affects the way the "read only" DOS attribute is produced
857 for UNIX files. If this is false then the read only bit is set for
858 files on writeable shares which the user cannot write to.
859
860 If this is true then it is set for files whos user write bit is not set.
861
862 The latter behaviour is useful for when users copy files from each
863 others directories, and use a file manager that preserves
864 permissions. Without this option they may get annoyed as all copied
865 files will have the "read only" bit set.
866
867 .B Default:
868         alternate permissions = no
869
870 .B Example:
871         alternate permissions = yes
872
873 .SS available (S)
874 This parameter lets you 'turn off' a service. If 'available = no', then
875 ALL attempts to connect to the service will fail. Such failures are logged.
876
877 .B Default:
878         available = yes
879
880 .B Example:
881         available = no
882
883 .SS bind interfaces only (G)
884 This global parameter (new for 1.9.18) allows the Samba admin to limit
885 what interfaces on a machine will serve smb requests. If affects file service
886 (smbd) and name service (nmbd) in slightly different ways.
887
888 For name service it causes nmbd to bind to ports 137 and 138 on
889 the interfaces listed in the 'interfaces' parameter. nmbd also binds
890 to the 'all addresses' interface (0.0.0.0) on ports 137 and 138
891 for the purposes of reading broadcast messages. If this option is
892 not set then nmbd will service name requests on all of these
893 sockets. If "bind interfaces only" is set then nmbd will check
894 the source address of any packets coming in on the broadcast
895 sockets and discard any that don't match the broadcast addresses
896 of the interfaces in the 'interfaces' parameter list. As unicast
897 packets are received on the other sockets it allows nmbd to
898 refuse to serve names to machines that send packets that arrive
899 through any interfaces not listed in the 'interfaces' list.
900 IP Source address spoofing does defeat this simple check, however
901 so it must not be used seriously as a security feature for nmbd.
902
903 For file service it causes smbd to bind only to the interface
904 list given in the 'interfaces' parameter. This restricts the
905 networks that smbd will serve to packets coming in those interfaces.
906 Note that you should not use this parameter for machines that
907 are serving ppp or other intermittant or non-broadcast network
908 interfaces as it will not cope with non-permanent interfaces.
909
910 .B Default:
911        bind interfaces only = False
912
913 .B Example:
914        bind interfaces only = True
915
916 .SS browseable (S)
917 This controls whether this share is seen in the list of available
918 shares in a net view and in the browse list.
919
920 .B Default:
921         browseable = Yes
922
923 .B Example: 
924         browseable = No
925 .SS browse list(G)
926 This controls whether the smbd will serve a browse list to a client
927 doing a NetServerEnum call. Normally set to true. You should never
928 need to change this.
929
930 .B Default:
931         browse list = Yes
932
933 .SS case sensitive (G)
934 See the discussion on NAME MANGLING.
935
936 .SS case sig names (G)
937 See "case sensitive"
938
939 .SS character set (G)
940 This allows a smbd to map incoming characters from a DOS 850 Code page
941 to either a Western European (ISO8859-1) or Easter European (ISO8859-2)
942 code page. Normally not set, meaning no filename translation is done.
943
944 .B Default
945
946         character set =
947
948 .B Example
949
950         character set = iso8859-1
951
952 .SS client code page (G)
953 Currently (Samba 1.9.17 and above) this may be set to one of two
954 values, 850 or 437. It specifies the base DOS code page that the
955 clients accessing Samba are using. To determine this, open a DOS
956 command prompt and type the command "chcp". This will output the
957 code page. The default for USA MS-DOS, Windows 95, and Windows NT
958 releases is code page 437. The default for western european 
959 releases of the above operating systems is code page 850.
960
961 This parameter co-operates with the "valid chars" parameter in
962 determining what characters are valid in filenames and how
963 capitalization is done. It has been added as a convenience for
964 clients whose code page is either 437 or 850 so a convoluted
965 "valid chars" string does not have to be determined. If you
966 set both this parameter and the "valid chars" parameter the 
967 "client code page" parameter MUST be set before the "valid chars"
968 in the smb.conf file. The "valid chars" string will then augment
969 the character settings in the "client code page" parameter.
970
971 If "client code page" is set to a value other than 850 or 437
972 it will default to 850.
973
974 See also : "valid chars".
975
976 .B Default
977
978         client code page = 850
979
980 .B Example
981
982         client code page = 437
983
984 .SS comment (S)
985 This is a text field that is seen next to a share when a client does a
986 net view to list what shares are available.
987
988 If you want to set the string that is displayed next to the machine
989 name then see the server string command.
990
991 .B Default:
992         No comment string
993
994 .B Example:
995         comment = Fred's Files
996
997 .SS config file (G)
998
999 This allows you to override the config file to use, instead of the
1000 default (usually smb.conf). There is a chicken and egg problem here as
1001 this option is set in the config file! 
1002
1003 For this reason, if the name of the config file has changed when the
1004 parameters are loaded then it will reload them from the new config
1005 file.
1006
1007 This option takes the usual substitutions, which can be very useful.
1008
1009 If the config file doesn't exist then it won't be loaded (allowing
1010 you to special case the config files of just a few clients).
1011
1012 .B Example:
1013         config file = /usr/local/samba/lib/smb.conf.%m
1014
1015 .SS copy (S)
1016 This parameter allows you to 'clone' service entries. The specified
1017 service is simply duplicated under the current service's name. Any 
1018 parameters specified in the current section will override those in the
1019 section being copied.
1020
1021 This feature lets you set up a 'template' service and create similar 
1022 services easily. Note that the service being copied must occur earlier 
1023 in the configuration file than the service doing the copying.
1024
1025 .B Default:
1026         none
1027
1028 .B Example:
1029         copy = otherservice
1030 .SS create mask (S)
1031 A synonym for this parameter is 'create mode'.
1032
1033 When a file is created, the neccessary permissions are calculated
1034 according to the mapping from DOS modes to UNIX permissions, and
1035 the resulting UNIX mode is then bit-wise 'AND'ed with this parameter.
1036 This parameter may be thought of as a bit-wise MASK for the UNIX
1037 modes of a file. Any bit *not* set here will be removed from the
1038 modes set on a file when it is created.
1039
1040 The default value of this parameter removes the 'group' and 'other' 
1041 write and execute bits from the UNIX modes.
1042
1043 Following this Samba will bit-wise 'OR' the UNIX mode created from
1044 this parameter with the value of the "force create mode" parameter 
1045 which is set to 000 by default.
1046
1047 For Samba 1.9.17 and above this parameter no longer affects directory
1048 modes. See the parameter 'directory mode' for details.
1049
1050 See also the "force create mode" parameter for forcing particular
1051 mode bits to be set on created files.
1052 See also the "directory mode" parameter for masking mode bits on created
1053 directories.
1054
1055 .B Default:
1056         create mask = 0744
1057
1058 .B Example:
1059         create mask = 0775
1060 .SS create mode (S)
1061 See
1062 .B create mask.
1063
1064 .SS dead time (G)
1065 The value of the parameter (a decimal integer) represents the number of
1066 minutes of inactivity before a connection is considered dead, and it
1067 is disconnected. The deadtime only takes effect if the number of open files
1068 is zero.
1069
1070 This is useful to stop a server's resources being exhausted by a large
1071 number of inactive connections.
1072
1073 Most clients have an auto-reconnect feature when a connection is broken so
1074 in most cases this parameter should be transparent to users.
1075
1076 Using this parameter with a timeout of a few minutes is recommended
1077 for most systems.
1078
1079 A deadtime of zero indicates that no auto-disconnection should be performed.
1080
1081 .B Default:
1082         dead time = 0
1083
1084 .B Example:
1085         dead time = 15
1086 .SS debug level (G)
1087 The value of the parameter (an integer) allows the debug level
1088 (logging level) to be specified in the
1089 .B smb.conf
1090 file. This is to give
1091 greater flexibility in the configuration of the system.
1092
1093 The default will be the debug level specified on the command line.
1094
1095 .B Example:
1096         debug level = 3
1097 .SS default (G)
1098 See
1099 .B default service.
1100 .SS default case (S)
1101
1102 See the section on "NAME MANGLING" Also note the addition of "short
1103 preserve case"
1104
1105 .SS default service (G)
1106 A synonym for this parameter is 'default'.
1107
1108 This parameter specifies the name of a service which will be connected to
1109 if the service actually requested cannot be found. Note that the square
1110 brackets are NOT given in the parameter value (see example below).
1111
1112 There is no default value for this parameter. If this parameter is not given,
1113 attempting to connect to a nonexistent service results in an error.
1114
1115 Typically the default service would be a public, read-only service.
1116
1117 Also note that as of 1.9.14 the apparent service name will be changed to
1118 equal that of the requested service, this is very useful as it allows
1119 you to use macros like %S to make a wildcard service.
1120
1121 Note also that any _ characters in the name of the service used in the
1122 default service will get mapped to a /. This allows for interesting
1123 things.
1124
1125
1126 .B Example:
1127         default service = pub
1128         
1129         [pub]
1130              path = /%S
1131           
1132
1133 .SS delete readonly (S)
1134 This parameter allows readonly files to be deleted.  This is not normal DOS
1135 semantics, but is allowed by UNIX.
1136
1137 This option may be useful for running applications such as rcs, where UNIX
1138 file ownership prevents changing file permissions, and DOS semantics prevent
1139 deletion of a read only file.
1140
1141 .B Default:
1142         delete readonly = No
1143
1144 .B Example:
1145         delete readonly = Yes
1146 .SS deny hosts (S)
1147 A synonym for this parameter is 'hosts deny'.
1148
1149 The opposite of 'allow hosts' - hosts listed here are NOT permitted
1150 access to services unless the specific services have their own lists to
1151 override this one. Where the lists conflict, the 'allow' list takes precedence.
1152
1153 .B Default:
1154         none (i.e., no hosts specifically excluded)
1155
1156 .B Example:
1157         deny hosts = 150.203.4. badhost.mynet.edu.au
1158
1159 .SS delete veto files (S)
1160
1161 This option is used when Samba is attempting to delete a directory
1162 that contains one or more vetoed directories (see the 'veto files' option).
1163 If this option is set to False (the default) then if a vetoed directory
1164 contains any non-vetoed files or directories then the directory delete 
1165 will fail. This is usually what you want. 
1166
1167 If this option is set to True, then Samba will attempt
1168 to recursively delete any files and directories within the vetoed
1169 directory. This can be useful for integration with file serving
1170 systems such as Netatalk, which create meta-files within directories
1171 you might normally veto DOS/Windows users from seeing (eg. .AppleDouble)
1172
1173 Setting 'delete veto files = True' allows these directories to be 
1174 transparently deleted when the parent directory is deleted (so long
1175 as the user has permissions to do so).
1176
1177 .B Default:
1178     delete veto files = False
1179
1180 .B Example:
1181     delete veto files = True
1182
1183 See
1184 .B veto files
1185
1186 .SS dfree command (G)
1187 The dfree command setting should only be used on systems where a
1188 problem occurs with the internal disk space calculations. This has
1189 been known to happen with Ultrix, but may occur with other operating
1190 systems. The symptom that was seen was an error of "Abort Retry
1191 Ignore" at the end of each directory listing.
1192
1193 This setting allows the replacement of the internal routines to
1194 calculate the total disk space and amount available with an external
1195 routine. The example below gives a possible script that might fulfill
1196 this function. 
1197
1198 The external program will be passed a single parameter indicating a
1199 directory in the filesystem being queried. This will typically consist
1200 of the string "./". The script should return two integers in ascii. The
1201 first should be the total disk space in blocks, and the second should
1202 be the number of available blocks. An optional third return value
1203 can give the block size in bytes. The default blocksize is 1024 bytes.
1204
1205 Note: Your script should NOT be setuid or setgid and should be owned by
1206 (and writable only by) root!
1207
1208 .B Default:
1209         By default internal routines for determining the disk capacity
1210 and remaining space will be used.
1211
1212 .B Example:
1213         dfree command = /usr/local/samba/bin/dfree
1214
1215         Where the script dfree (which must be made executable) could be
1216
1217 .nf
1218         #!/bin/sh
1219         df $1 | tail -1 | awk '{print $2" "$4}'
1220 .fi
1221
1222         or perhaps (on Sys V)
1223
1224 .nf
1225         #!/bin/sh
1226         /usr/bin/df -k $1 | tail -1 | awk '{print $3" "$5}'
1227 .fi
1228
1229         Note that you may have to replace the command names with full
1230 path names on some systems.
1231 .SS directory (S)
1232 See
1233 .B path.
1234
1235 .SS directory mask (S)
1236 A synonym for this parameter is 'directory mode'.
1237
1238 This parameter is the octal modes which are used when converting DOS modes 
1239 to UNIX modes when creating UNIX directories.
1240
1241 When a directory is created, the neccessary permissions are calculated
1242 according to the mapping from DOS modes to UNIX permissions, and
1243 the resulting UNIX mode is then bit-wise 'AND'ed with this parameter.
1244 This parameter may be thought of as a bit-wise MASK for the UNIX
1245 modes of a directory. Any bit *not* set here will be removed from the
1246 modes set on a directory when it is created.
1247
1248 The default value of this parameter removes the 'group' and 'other'
1249 write bits from the UNIX mode, allowing only the user who owns the
1250 directory to modify it.
1251
1252 Following this Samba will bit-wise 'OR' the UNIX mode created from
1253 this parameter with the value of the "force directory mode" parameter. 
1254 This parameter is set to 000 by default (ie. no extra mode bits are added).
1255
1256 See the "force directory mode" parameter to cause particular mode
1257 bits to always be set on created directories.
1258
1259 See also the "create mode" parameter for masking mode bits on created
1260 files.
1261
1262 .B Default:
1263         directory mask = 0755
1264
1265 .B Example:
1266         directory mask = 0775
1267
1268 .SS directory mode (S)
1269 See
1270 .B directory mask.
1271
1272 .SS dns proxy (G)
1273
1274 Specifies that nmbd should (as a WINS server), on finding that a NetBIOS
1275 name has not been registered, treat the NetBIOS name word-for-word as
1276 a DNS name.
1277
1278 Note that the maximum length for a NetBIOS name is 15
1279 characters, so the DNS name (or DNS alias) can likewise only be 15
1280 characters, maximum.
1281
1282 Note also that nmbd will block completely until the DNS name is resolved.
1283 This will result in temporary loss of browsing and WINS services.
1284 Enable this option only if you are certain that DNS resolution is fast,
1285 or you can live with the consequences of periodic pauses in nmbd service.
1286
1287 .B Default:
1288          dns proxy = yes
1289
1290 .SS domain controller (G)
1291
1292 Specifies the DNS name or IP address of the machine to refer domain 
1293 logons from Win95 machines to. You should never need to set this parameter.
1294
1295 .B Default:
1296          domain controller = no
1297
1298 .SS domain logons (G)
1299
1300 If set to true, the Samba server will serve Windows 95 domain logons
1301 for the workgroup it is in. For more details on setting up this feature
1302 see the file DOMAINS.txt in the Samba source documentation directory.
1303
1304 .B Default:
1305          domain logons = no
1306
1307 .SS domain master (G)
1308
1309 Enable WAN-wide browse list collation.  Local master browsers on 
1310 broadcast-isolated subnets will give samba their local browse lists, and 
1311 ask for a complete copy of the browse list for the whole wide area network.
1312 Browser clients will then contact their local master browser, and will
1313 receive the domain-wide browse list, instead of just the list for their
1314 broadcast-isolated subnet.
1315
1316 .B Default:
1317         domain master = no
1318
1319 .SS dont descend (S)
1320 There are certain directories on some systems (eg., the /proc tree under
1321 Linux) that are either not of interest to clients or are infinitely deep
1322 (recursive). This parameter allows you to specify a comma-delimited list
1323 of directories that the server should always show as empty.
1324
1325 Note that Samba can be very fussy about the exact format of the "dont
1326 descend" entries. For example you may need "./proc" instead of just
1327 "/proc". Experimentation is the best policy :-)
1328
1329 .B Default:
1330         none (i.e., all directories are OK to descend)
1331
1332 .B Example:
1333         dont descend = /proc,/dev
1334
1335 .SS dos filetimes (S)
1336 Under DOS and Windows, if a user can write to a file they can change
1337 the timestamp on it. Under POSIX semantics, only the owner of the file
1338 or root may change the timestamp. By default, Samba runs with POSIX
1339 semantics and refuses to change the timestamp on a file if the user
1340 smbd is acting on behalf of is not the file owner. Setting this option
1341 to True allows DOS semantics and smbd will change the file timstamp as 
1342 DOS requires. This is a correct implementation of a previous compile-time
1343 options (UTIME_WORKAROUND) which was broken and is now removed.
1344
1345 .B Default:
1346         dos filetimes = False
1347
1348 .B Example:
1349         dos filetimes = True
1350
1351 .SS encrypt passwords (G)
1352
1353 This boolean controls whether encrypted passwords will be negotiated
1354 with the client. Note that this option has no effect if you haven't
1355 compiled in the necessary des libraries and encryption code. It
1356 defaults to no.
1357
1358 .SS exec (S)
1359
1360 This is an alias for preexec
1361
1362 .SS fake oplocks (S)
1363
1364 Oplocks are the way that SMB clients get permission from a server to
1365 locally cache file operations. If a server grants an oplock
1366 (opportunistic lock) then the client is free to assume that it is the
1367 only one accessing the file and it will aggressively cache file
1368 data. With some oplock types the client may even cache file open/close
1369 operations. This can give enormous performance benefits.
1370
1371 When you set "fake oplocks = yes" Samba will always grant oplock
1372 requests no matter how many clients are using the file. 
1373
1374 By enabling this option on all read-only shares or shares that you know
1375 will only be accessed from one client at a time you will see a big
1376 performance improvement on many operations. If you enable this option
1377 on shares where multiple clients may be accessing the files read-write
1378 at the same time you can get data corruption. Use this option
1379 carefully! 
1380
1381 It is generally much better to use the real oplock support except for
1382 physically read-only media such as CDROMs.
1383
1384 This option is disabled by default.
1385
1386 .SS follow symlinks (S)
1387
1388 This parameter allows the Samba administrator to stop smbd from
1389 following symbolic links in a particular share. Setting this
1390 parameter to "No" prevents any file or directory that is a 
1391 symbolic link from being followed (the user will get an error).
1392 This option is very useful to stop users from adding a symbolic
1393 link to /etc/pasword in their home directory for instance.
1394 However it will slow filename lookups down slightly.
1395
1396 This option is enabled (ie. smbd will follow symbolic links)
1397 by default.
1398
1399 .SS force create mode (S)
1400 This parameter specifies a set of UNIX mode bit permissions that
1401 will *always* be set on a file created by Samba. This is done
1402 by bitwise 'OR'ing these bits onto the mode bits of a file that
1403 is being created. The default for this parameter is (in octel)
1404 000. The modes in this parameter are bitwise 'OR'ed onto the
1405 file mode after the mask set in the "create mask" parameter
1406 is applied.
1407
1408 See also the parameter "create mask" for details on masking mode
1409 bits on created files.
1410
1411 .B Default:
1412        force create mode = 000
1413
1414 .B Example:
1415        force create mode = 0755
1416
1417 would force all created files to have read and execute permissions
1418 set for 'group' and 'other' as well as the read/write/execute bits 
1419 set for the 'user'.
1420
1421 .SS force directory mode (S)
1422 This parameter specifies a set of UNIX mode bit permissions that
1423 will *always* be set on a directory created by Samba. This is done
1424 by bitwise 'OR'ing these bits onto the mode bits of a directory that
1425 is being created. The default for this parameter is (in octel)
1426 0000 which will not add any extra permission bits to a created
1427 directory. This operation is done after the mode mask in the parameter 
1428 "directory mask" is applied.
1429
1430 See also the parameter "directory mask" for details on masking mode
1431 bits on created directories.
1432
1433 .B Default:
1434        force directory mode = 000
1435
1436 .B Example:
1437        force directory mode = 0755
1438
1439 would force all created directories to have read and execute permissions
1440 set for 'group' and 'other' as well as the read/write/execute bits 
1441 set for the 'user'.
1442
1443 .SS force group (S)
1444 This specifies a group name that all connections to this service
1445 should be made as. This may be useful for sharing files.
1446
1447 .B Default:
1448        no forced group
1449
1450 .B Example:
1451        force group = agroup
1452
1453 .SS force user (S)
1454 This specifies a user name that all connections to this service
1455 should be made as. This may be useful for sharing files. You should
1456 also use it carefully as using it incorrectly can cause security
1457 problems.
1458
1459 This user name only gets used once a connection is established. Thus
1460 clients still need to connect as a valid user and supply a valid
1461 password. Once connected, all file operations will be performed as the
1462 "forced user", not matter what username the client connected as.
1463
1464 .B Default:
1465        no forced user
1466
1467 .B Example:
1468        force user = auser
1469
1470 .SS getwd cache (G)
1471 This is a tuning option. When this is enabled a cacheing algorithm will
1472 be used to reduce the time taken for getwd() calls. This can have a
1473 significant impact on performance, especially when widelinks is False.
1474
1475 .B Default:
1476         getwd cache = No
1477
1478 .B Example:
1479         getwd cache = Yes
1480
1481 .SS group (S)
1482 This is an alias for "force group" and is only kept for compatibility
1483 with old versions of Samba. It may be removed in future versions.
1484
1485 .SS guest account (S)
1486 This is a username which will be used for access to services which are
1487 specified as 'guest ok' (see below). Whatever privileges this user has
1488 will be available to any client connecting to the guest
1489 service. Typically this user will exist in the password file, but will
1490 not have a valid login. If a username is specified in a given service,
1491 the specified username overrides this one.
1492
1493 One some systems the account "nobody" may not be able to print. Use
1494 another account in this case. You should test this by trying to log in
1495 as your guest user (perhaps by using the "su \-" command) and trying to
1496 print using
1497 .BR lpr .
1498
1499 Note that as of version 1.9 of Samba this option may be set
1500 differently for each service.
1501
1502 .B Default:
1503         specified at compile time
1504
1505 .B Example:
1506         guest account = nobody
1507 .SS guest ok (S)
1508 See
1509 .B public.
1510 .SS guest only (S)
1511 If this parameter is 'yes' for a service, then only guest connections to the
1512 service are permitted. This parameter will have no affect if "guest ok" or
1513 "public" is not set for the service.
1514
1515 See the section below on user/password validation for more information about
1516 this option.
1517
1518 .B Default:
1519         guest only = no
1520
1521 .B Example:
1522         guest only = yes
1523 .SS hide dot files (S)
1524 This is a boolean parameter that controls whether files starting with
1525 a dot appear as hidden files.
1526
1527 .B Default:
1528         hide dot files = yes
1529
1530 .B Example:
1531         hide dot files = no
1532
1533
1534 .SS hide files(S)
1535 This is a list of files or directories that are not visible but are
1536 accessible.  The DOS 'hidden' attribute is applied to any files or
1537 directories that match.
1538
1539 Each entry in the list must be separated by a "/", which allows spaces
1540 to be included in the entry.  '*' and '?' can be used to specify multiple 
1541 files or directories as in DOS wildcards.
1542
1543 Each entry must be a unix path, not a DOS path and must not include the 
1544 unix directory separator "/".
1545
1546 Note that the case sensitivity option is applicable in hiding files.
1547
1548 Setting this parameter will affect the performance of Samba, as
1549 it will be forced to check all files and directories for a match
1550 as they are scanned.
1551
1552 See also "hide dot files", "veto files" and "case sensitive"
1553
1554 .B Default
1555         No files or directories are hidden by this option (dot files are
1556     hidden by default because of the "hide dot files" option).
1557
1558 .B Example
1559         hide files = /.*/DesktopFolderDB/TrashFor%m/resource.frk/
1560
1561 The above example is based on files that the Macintosh client (DAVE)
1562 creates for internal use, and also still hides all files beginning with
1563 a dot.
1564
1565 .SS homedir map (G)
1566 If "nis homedir" is true, this parameter specifies the NIS (or YP) map
1567 from which the server for the user's home directory should be extracted.
1568 At present, only the Sun auto.home map format is understood. The form of
1569 the map is:
1570
1571 username        server:/some/file/system
1572
1573 and the program will extract the servername from before the first ':'.
1574 There should probably be a better parsing system that copes with different
1575 map formats and also Amd (another automounter) maps.
1576
1577 NB: The -DNETGROUP option is required in the Makefile for option to work
1578 and on some architectures the line -lrpcsvc needs to be added to the
1579 LIBSM variable. This is required for Solaris 2, FreeBSD and HPUX.
1580
1581 See also "nis homedir"
1582
1583 .B Default:
1584         homedir map = auto.home
1585
1586 .B Example:
1587         homedir map = amd.homedir
1588 .SS hosts allow (S)
1589 See
1590 .B allow hosts.
1591 .SS hosts deny (S)
1592 See
1593 .B deny hosts.
1594
1595 .SS hosts equiv (G)
1596 If this global parameter is a non-null string, it specifies the name of
1597 a file to read for the names of hosts and users who will be allowed access
1598 without specifying a password.
1599
1600 This is not be confused with 
1601 .B allow hosts
1602 which is about hosts access to services and is more useful for guest services.
1603 .B hosts equiv
1604 may be useful for NT clients which will not supply passwords to samba.
1605
1606 NOTE: The use of hosts.equiv can be a major security hole. This is
1607 because you are trusting the PC to supply the correct username. It is
1608 very easy to get a PC to supply a false username. I recommend that the
1609 hosts.equiv option be only used if you really know what you are doing,
1610 or perhaps on a home network where you trust your wife and kids :-)
1611
1612 .B Default
1613         No host equivalences
1614
1615 .B Example
1616         hosts equiv = /etc/hosts.equiv
1617
1618 .SS include (G)
1619
1620 This allows you to include one config file inside another.  The file is
1621 included literally, as though typed in place.
1622
1623 It takes the standard substitutions, except %u, %P and %S
1624
1625 .SS interfaces (G)
1626
1627 This option allows you to setup multiple network interfaces, so that
1628 Samba can properly handle browsing on all interfaces.
1629
1630 The option takes a list of ip/netmask pairs. The netmask may either be
1631 a bitmask, or a bitlength. 
1632
1633 For example, the following line:
1634
1635 interfaces = 192.168.2.10/24 192.168.3.10/24
1636
1637 would configure two network interfaces with IP addresses 192.168.2.10
1638 and 192.168.3.10. The netmasks of both interfaces would be set to
1639 255.255.255.0. 
1640
1641 You could produce an equivalent result by using:
1642
1643 interfaces = 192.168.2.10/255.255.255.0 192.168.3.10/255.255.255.0
1644
1645 if you prefer that format.
1646
1647 If this option is not set then Samba will attempt to find a primary
1648 interface, but won't attempt to configure more than one interface.
1649
1650 .SS invalid users (S)
1651 This is a list of users that should not be allowed to login to this
1652 service. This is really a "paranoid" check to absolutely ensure an
1653 improper setting does not breach your security.
1654
1655 A name starting with @ is interpreted as a UNIX group.
1656
1657 The current servicename is substituted for %S. This is useful in the
1658 [homes] section.
1659
1660 See also "valid users"
1661
1662 .B Default
1663         No invalid users
1664
1665 .B Example
1666         invalid users = root fred admin @wheel
1667
1668 .SS keepalive (G)
1669 The value of the parameter (an integer) represents the number of seconds 
1670 between 'keepalive' packets. If this parameter is zero, no keepalive packets
1671 will be sent. Keepalive packets, if sent, allow the server to tell whether a
1672 client is still present and responding.
1673
1674 Keepalives should, in general, not be needed if the socket being used
1675 has the SO_KEEPALIVE attribute set on it (see "socket
1676 options"). Basically you should only use this option if you strike
1677 difficulties.
1678
1679 .B Default:
1680         keep alive = 0
1681
1682 .B Example:
1683         keep alive = 60
1684
1685 .SS lm announce (G)
1686
1687 This parameter determines if Samba will produce Lanman announce
1688 broadcasts that are needed by OS/2 clients in order for them to
1689 see the Samba server in their browse list. This parameter can
1690 have three values, true, false, or auto. The default is auto.
1691 If set to False Samba will never produce these broadcasts. If
1692 set to true Samba will produce Lanman announce broadcasts at
1693 a frequency set by the parameter 'lm interval'. If set to auto
1694 Samba will not send Lanman announce broadcasts by default but
1695 will listen for them. If it hears such a broadcast on the wire
1696 it will then start sending them at a frequency set by the parameter 
1697 'lm interval'.
1698
1699 See also "lm interval".
1700
1701 .B Default:
1702        lm announce = auto
1703
1704 .B Example:
1705        lm announce = true
1706
1707 .SS lm interval (G)
1708
1709 If Samba is set to produce Lanman announce broadcasts needed
1710 by OS/2 clients (see the "lm announce" parameter) this parameter
1711 defines the frequency in seconds with which they will be made.
1712 If this is set to zero then no Lanman announcements will be
1713 made despite the setting of the "lm announce" parameter.
1714
1715 See also "lm announce".
1716
1717 .B Default:
1718         lm interval = 60
1719
1720 .B Example:
1721         lm interval = 120
1722
1723 .SS load printers (G)
1724 A boolean variable that controls whether all printers in the printcap
1725 will be loaded for browsing by default. 
1726
1727 .B Default:
1728         load printers = yes
1729
1730 .B Example:
1731         load printers = no
1732
1733 .SS local master (G)
1734 This option allows the nmbd to become a local master browser on a
1735 subnet. If set to False then nmbd will not attempt to become a local
1736 master browser on a subnet and will also lose in all browsing elections. 
1737 By default this value is set to true. Setting this value to true doesn't 
1738 mean that Samba will become the local master browser on a subnet, just 
1739 that the nmbd will participate in elections for local master browser.
1740
1741 .B Default:
1742         local master = yes
1743
1744 .SS lock directory (G)
1745 This option specifies the directory where lock files will be placed.
1746 The lock files are used to implement the "max connections" option.
1747
1748 .B Default:
1749         lock directory = /tmp/samba
1750
1751 .B Example: 
1752         lock directory = /usr/local/samba/var/locks
1753
1754 .SS locking (S)
1755 This controls whether or not locking will be performed by the server in 
1756 response to lock requests from the client.
1757
1758 If "locking = no", all lock and unlock requests will appear to succeed and 
1759 all lock queries will indicate that the queried lock is clear.
1760
1761 If "locking = yes", real locking will be performed by the server.
1762
1763 This option may be particularly useful for read-only filesystems which
1764 do not need locking (such as cdrom drives).
1765
1766 Be careful about disabling locking either globally or in a specific
1767 service, as lack of locking may result in data corruption.
1768
1769 .B Default:
1770         locking = yes
1771
1772 .B Example:
1773         locking = no
1774
1775 .SS log file (G)
1776
1777 This options allows you to override the name of the Samba log file
1778 (also known as the debug file).
1779
1780 This option takes the standard substitutions, allowing you to have
1781 separate log files for each user or machine.
1782
1783 .B Example:
1784         log file = /usr/local/samba/var/log.%m
1785
1786 .SS log level (G)
1787 see "debug level"
1788
1789 .SS logon drive (G)
1790
1791 This parameter specifies the local path to which the home directory
1792 will be connected (see "logon home") and is only used by NT Workstations.
1793
1794 .B Example:
1795         logon drive = h:
1796
1797 .SS logon home (G)
1798
1799 This parameter specifies the home directory location when a Win95 or
1800 NT Workstation logs into a Samba PDC.  It allows you to do "NET USE
1801 H: /HOME" from a command prompt, for example.
1802
1803 .B
1804 This option takes the standard substitutions, allowing you to have
1805 separate logon scripts for each user or machine.
1806
1807 .B Example:
1808         logon home = "\\\\remote_smb_server\\%U"
1809
1810 .B Default:
1811         logon home = "\\\\%N\\%U"
1812
1813 .SS logon path (G)
1814
1815 This parameter specifies the home directory where roaming profiles 
1816 (USER.DAT / USER.MAN files for Windows 95) are stored.
1817
1818 This option takes the standard substitutions, allowing you to have
1819 separate logon scripts for each user or machine.  It also specifies
1820 the directory from which the "desktop", "start menu", "nethood" and
1821 "programs" folders, and their contents, are loaded and displayed
1822 on your Windows 95 client.
1823
1824 The share and the path must be readable by the user for the preferences
1825 and directories to be loaded onto the Windows 95 client.  The share
1826 must be writeable when the logs in for the first time, in order that
1827 the Windows 95 client can create the user.dat and other directories.
1828
1829 Thereafter, the directories and any of contents can, if required,
1830 be made read-only.  It is not adviseable that the USER.DAT file be made
1831 read-only - rename it to USER.MAN to achieve the desired effect
1832 (a MANdatory profile).
1833
1834 Windows clients can sometimes maintain a connection to the [homes]
1835 share, even though there is no user logged in.  Therefore, it is
1836 vital that the logon path does not include a reference to the
1837 homes share (i.e \\\\%N\\HOMES\profile_path will cause problems).
1838
1839 .B
1840 This option takes the standard substitutions, allowing you to have
1841 separate logon scripts for each user or machine.
1842
1843 .B Default:
1844         logon path = \\\\%N\\%U\\profile
1845
1846 .B Example:
1847         logon path = \\\\PROFILESERVER\\HOME_DIR\\%U\\PROFILE
1848
1849 .SS logon script (G)
1850
1851 This parameter specifies the batch file (.bat) or NT command file (.cmd)
1852 to be downloaded and run on a machine when a user successfully logs in.
1853 The file must contain the DOS style cr/lf line endings.  Using a DOS-style
1854 editor to create the file is recommended.
1855
1856 The script must be a relative path to the [netlogon] service.  If the
1857 [netlogon] service specifies a path of /usr/local/samba/netlogon, and
1858 logon script = STARTUP.BAT, then file that will be downloaded is:
1859
1860 .B /usr/local/samba/netlogon/STARTUP.BAT
1861
1862 The contents of the batch file is entirely your choice.  A suggested
1863 command would be to add NET TIME \\\\SERVER /SET /YES, to force every
1864 machine to synchronise clocks with the same time server.  Another use
1865 would be to add NET USE U: \\\\SERVER\\UTILS for commonly used utilities,
1866 or NET USE Q: \\\\SERVER\\ISO9001_QA.
1867
1868 Note that it is particularly important not to allow write access to
1869 the [netlogon] share, or to grant users write permission on the
1870 batch files in a secure environment, as this would allow the batch
1871 files to be arbitrarily modified.
1872
1873 .B
1874 This option takes the standard substitutions, allowing you to have
1875 separate logon scripts for each user or machine.
1876
1877 .B Example:
1878         logon script = scripts/%U.bat
1879
1880 .SS lppause command (S)
1881 This parameter specifies the command to be executed on the server host in
1882 order to stop printing or spooling a specific print job.
1883
1884 This command should be a program or script which takes a printer name and
1885 job number to pause the print job. Currently I don't know of any print
1886 spooler system that can do this with a simple option, except for the PPR
1887 system from Trinity College (ppr\-dist.trincoll.edu/pub/ppr). One way
1888 of implementing this is by using job priorities, where jobs having a too
1889 low priority won't be sent to the printer. See also the
1890 .B lppause
1891 command.
1892
1893 If a %p is given then the printername is put in its place. A %j is
1894 replaced with the job number (an integer).
1895 On HPUX (see printing=hpux), if the -p%p option is added to the lpq
1896 command, the job will show up with the correct status, i.e. if the job
1897 priority is lower than the set fence priority it will have the PAUSED
1898 status, whereas if the priority is equal or higher it will have the
1899 SPOOLED or PRINTING status.
1900
1901 Note that it is good practice to include the absolute path in the lppause
1902 command as the PATH may not be available to the server.
1903
1904 .B Default:
1905         Currently no default value is given to this string
1906
1907 .B Example for HPUX:
1908         lppause command = /usr/bin/lpalt %p-%j -p0
1909
1910 .SS lpq cache time (G)
1911
1912 This controls how long lpq info will be cached for to prevent the lpq
1913 command being called too often. A separate cache is kept for each
1914 variation of the lpq command used by the system, so if you use
1915 different lpq commands for different users then they won't share cache
1916 information.
1917
1918 The cache files are stored in /tmp/lpq.xxxx where xxxx is a hash
1919 of the lpq command in use.
1920
1921 The default is 10 seconds, meaning that the cached results of a
1922 previous identical lpq command will be used if the cached data is less
1923 than 10 seconds old. A large value may be advisable if your lpq
1924 command is very slow.
1925
1926 A value of 0 will disable cacheing completely.
1927
1928 .B Default:
1929         lpq cache time = 10
1930
1931 .B Example:
1932         lpq cache time = 30
1933
1934 .SS lpq command (S)
1935 This parameter specifies the command to be executed on the server host in
1936 order to obtain "lpq"-style printer status information. 
1937
1938 This command should be a program or script which takes a printer name
1939 as its only parameter and outputs printer status information. 
1940
1941 Currently six styles of printer status information are supported; BSD,
1942 SYSV, AIX, HPUX, QNX, LPRNG and PLP. This covers most UNIX systems. You
1943 control which type is expected using the "printing =" option.
1944
1945 Some clients (notably Windows for Workgroups) may not correctly send the
1946 connection number for the printer they are requesting status information
1947 about. To get around this, the server reports on the first printer service
1948 connected to by the client. This only happens if the connection number sent
1949 is invalid.
1950
1951 If a %p is given then the printername is put in its place. Otherwise
1952 it is placed at the end of the command.
1953
1954 Note that it is good practice to include the absolute path in the lpq
1955 command as the PATH may not be available to the server.
1956
1957 .B Default:
1958         depends on the setting of "printing ="
1959
1960 .B Example:
1961         lpq command = /usr/bin/lpq %p
1962
1963 .SS lpresume command (S)
1964 This parameter specifies the command to be executed on the server host in
1965 order to restart or continue printing or spooling a specific print job.
1966
1967 This command should be a program or script which takes a printer name and
1968 job number to resume the print job. See also the lppause command.
1969
1970 If a %p is given then the printername is put in its place. A %j is
1971 replaced with the job number (an integer).
1972
1973 Note that it is good practice to include the absolute path in the lpresume
1974 command as the PATH may not be available to the server.
1975
1976 .B Default:
1977         Currently no default value is given to this string
1978
1979 .B Example for HPUX:
1980         lpresume command = /usr/bin/lpalt %p-%j -p2
1981
1982 .SS lprm command (S)
1983 This parameter specifies the command to be executed on the server host in
1984 order to delete a print job.
1985
1986 This command should be a program or script which takes a printer name
1987 and job number, and deletes the print job.
1988
1989 Currently seven styles of printer control are supported; BSD, SYSV, AIX
1990 HPUX, QNX, LPRNG and PLP. This covers most UNIX systems. You control
1991 which type is expected using the "printing =" option.
1992
1993 If a %p is given then the printername is put in its place. A %j is
1994 replaced with the job number (an integer).
1995
1996 Note that it is good practice to include the absolute path in the lprm
1997 command as the PATH may not be available to the server.
1998
1999 .B Default:
2000         depends on the setting of "printing ="
2001
2002 .B Example 1:
2003         lprm command = /usr/bin/lprm -P%p %j
2004
2005 .B Example 2:
2006         lprm command = /usr/bin/cancel %p-%j
2007
2008 .SS magic output (S)
2009 This parameter specifies the name of a file which will contain output
2010 created by a magic script (see
2011 .I magic script
2012 below).
2013
2014 Warning: If two clients use the same magic script in the same directory the
2015 output file content is undefined.
2016 .B Default:
2017         magic output = <magic script name>.out
2018
2019 .B Example:
2020         magic output = myfile.txt
2021 .SS magic script (S)
2022 This parameter specifies the name of a file which, if opened, will be
2023 executed by the server when the file is closed. This allows a UNIX script
2024 to be sent to the Samba host and executed on behalf of the connected user.
2025
2026 Scripts executed in this way will be deleted upon completion, permissions
2027 permitting.
2028
2029 If the script generates output, output will be sent to the file specified by
2030 the
2031 .I magic output
2032 parameter (see above).
2033
2034 Note that some shells are unable to interpret scripts containing
2035 carriage-return-linefeed instead of linefeed as the end-of-line
2036 marker. Magic scripts must be executable "as is" on the host, which
2037 for some hosts and some shells will require filtering at the DOS end.
2038
2039 Magic scripts are EXPERIMENTAL and should NOT be relied upon.
2040
2041 .B Default:
2042         None. Magic scripts disabled.
2043
2044 .B Example:
2045         magic script = user.csh
2046
2047 .SS mangle case (S)
2048
2049 See the section on "NAME MANGLING"
2050
2051 .SS mangled map (S)
2052 This is for those who want to directly map UNIX file names which are
2053 not representable on DOS.  The mangling of names is not always what is
2054 needed.  In particular you may have documents with file extensions
2055 that differ between DOS and UNIX. For example, under UNIX it is common
2056 to use .html for HTML files, whereas under DOS .htm is more commonly
2057 used.
2058
2059 So to map 'html' to 'htm' you put:
2060
2061   mangled map = (*.html *.htm)
2062
2063 One very useful case is to remove the annoying ;1 off the ends of
2064 filenames on some CDROMS (only visible under some UNIXes). To do this
2065 use a map of (*;1 *)
2066
2067 .B default:
2068         no mangled map
2069
2070 .B Example:
2071         mangled map = (*;1 *)
2072
2073 .SS mangled names (S)
2074 This controls whether non-DOS names under UNIX should be mapped to
2075 DOS-compatible names ("mangled") and made visible, or whether non-DOS names
2076 should simply be ignored.
2077
2078 See the section on "NAME MANGLING" for details on how to control the
2079 mangling process.
2080
2081 If mangling is used then the mangling algorithm is as follows:
2082 .RS
2083 - the first (up to) five alphanumeric characters before the rightmost dot of
2084 the filename are preserved, forced to upper case, and appear as the first (up
2085 to) five characters of the mangled name.
2086
2087 - a tilde ("~") is appended to the first part of the mangled name, followed
2088 by a two-character unique sequence, based on the original root name 
2089 (i.e., the original filename minus its final extension). The final
2090 extension is included in the hash calculation only if it contains any upper
2091 case characters or is longer than three characters.
2092
2093 Note that the character to use may be specified using the "mangling
2094 char" option, if you don't like ~.
2095
2096 - the first three alphanumeric characters of the final extension are preserved,
2097 forced to upper case and appear as the extension of the mangled name. The 
2098 final extension is defined as that part of the original filename after the
2099 rightmost dot. If there are no dots in the filename, the mangled name will
2100 have no extension (except in the case of hidden files - see below).
2101
2102 - files whose UNIX name begins with a dot will be presented as DOS hidden
2103 files. The mangled name will be created as for other filenames, but with the
2104 leading dot removed and "___" as its extension regardless of actual original
2105 extension (that's three underscores).
2106 .RE
2107
2108 The two-digit hash value consists of upper case alphanumeric characters.
2109
2110 This algorithm can cause name collisions only if files in a directory share
2111 the same first five alphanumeric characters. The probability of such a clash 
2112 is 1/1300.
2113
2114 The name mangling (if enabled) allows a file to be copied between UNIX
2115 directories from DOS while retaining the long UNIX filename. UNIX files can
2116 be renamed to a new extension from DOS and will retain the same basename. 
2117 Mangled names do not change between sessions.
2118
2119 .B Default:
2120         mangled names = yes
2121
2122 .B Example:
2123         mangled names = no
2124 .SS mangling char (S)
2125 This controls what character is used as the "magic" character in name
2126 mangling. The default is a ~ but this may interfere with some
2127 software. Use this option to set it to whatever you prefer.
2128
2129 .B Default:
2130         mangling char = ~
2131
2132 .B Example:
2133         mangling char = ^
2134
2135 .SS mangled stack (G)
2136 This parameter controls the number of mangled names that should be cached in
2137 the Samba server.
2138
2139 This stack is a list of recently mangled base names (extensions are only
2140 maintained if they are longer than 3 characters or contains upper case
2141 characters).
2142
2143 The larger this value, the more likely it is that mangled names can be
2144 successfully converted to correct long UNIX names. However, large stack
2145 sizes will slow most directory access. Smaller stacks save memory in the
2146 server (each stack element costs 256 bytes).
2147
2148 It is not possible to absolutely guarantee correct long file names, so
2149 be prepared for some surprises!
2150
2151 .B Default:
2152         mangled stack = 50
2153
2154 .B Example:
2155         mangled stack = 100
2156
2157 .SS map archive (S)
2158 This controls whether the DOS archive attribute should be mapped to the
2159 UNIX owner execute bit.  The DOS archive bit is set when a file has been modified
2160 since its last backup.  One motivation for this option it to keep Samba/your
2161 PC from making any file it touches from becoming executable under UNIX.
2162 This can be quite annoying for shared source code, documents,  etc...
2163
2164 Note that this requires the 'create mask' to be set such that owner
2165 execute bit is not masked out (ie. it must include 100). See the 
2166 parameter "create mask" for details.
2167
2168 .B Default:
2169       map archive = yes
2170
2171 .B Example:
2172       map archive = no
2173
2174 .SS map hidden (S)
2175 This controls whether DOS style hidden files should be mapped to the
2176 UNIX world execute bit.
2177
2178 Note that this requires the 'create mask' to be set such that the world
2179 execute bit is not masked out (ie. it must include 001). 
2180 See the parameter "create mask" for details.
2181
2182 .B Default:
2183         map hidden = no
2184
2185 .B Example:
2186         map hidden = yes
2187 .SS map system (S)
2188 This controls whether DOS style system files should be mapped to the
2189 UNIX group execute bit.
2190
2191 Note that this requires the 'create mask' to be set such that the group
2192 execute bit is not masked out (ie. it must include 010). See the parameter 
2193 "create mask" for details.
2194
2195 .B Default:
2196         map system = no
2197
2198 .B Example:
2199         map system = yes
2200 .SS max connections (S)
2201 This option allows the number of simultaneous connections to a
2202 service to be limited. If "max connections" is greater than 0 then
2203 connections will be refused if this number of connections to the
2204 service are already open. A value of zero mean an unlimited number of
2205 connections may be made.
2206
2207 Record lock files are used to implement this feature. The lock files
2208 will be stored in the directory specified by the "lock directory" option.
2209
2210 .B Default:
2211         max connections = 0
2212
2213 .B Example:
2214         max connections = 10
2215
2216 .SS max disk size (G)
2217 This option allows you to put an upper limit on the apparent size of
2218 disks. If you set this option to 100 then all shares will appear to be
2219 not larger than 100 MB in size.
2220
2221 Note that this option does not limit the amount of data you can put on
2222 the disk. In the above case you could still store much more than 100
2223 MB on the disk, but if a client ever asks for the amount of free disk
2224 space or the total disk size then the result will be bounded by the
2225 amount specified in "max disk size".
2226
2227 This option is primarily useful to work around bugs in some pieces of
2228 software that can't handle very large disks, particularly disks over
2229 1GB in size.
2230
2231 A "max disk size" of 0 means no limit.
2232
2233 .B Default:
2234         max disk size = 0
2235
2236 .B Example:
2237         max disk size = 1000
2238
2239 .SS max log size (G)
2240
2241 This option (an integer in kilobytes) specifies the max size the log
2242 file should grow to. Samba periodically checks the size and if it is
2243 exceeded it will rename the file, adding a .old extension.
2244
2245 A size of 0 means no limit.
2246
2247 .B Default:
2248         max log size = 5000
2249
2250 .B Example:
2251         max log size = 1000
2252
2253 .SS max mux (G)
2254
2255 This option controls the maximum number of outstanding simultaneous SMB 
2256 operations that samba tells the client it will allow. You should never need 
2257 to set this parameter.
2258
2259 .B Default:
2260         max mux = 50
2261
2262 .SS max packet (G)
2263
2264 A synonym for this parameter is 'packet size'.
2265
2266 .SS max ttl (G)
2267
2268 This option tells nmbd what the default 'time to live' of NetBIOS
2269 names should be (in seconds) when nmbd is requesting a name using
2270 either a broadcast or from a WINS server. You should never need to 
2271 change this parameter.
2272
2273 .B Default:
2274         max ttl = 14400
2275
2276 .SS max wins ttl (G)
2277
2278 This option tells nmbd when acting as a WINS server (wins support = true)
2279 what the maximum 'time to live' of NetBIOS names that nmbd will grant will
2280 be (in seconds). You should never need to change this parameter.     
2281 The default is 3 days (259200 seconds).
2282
2283 .B Default:
2284         max wins ttl = 259200
2285
2286 .SS max xmit (G)
2287
2288 This option controls the maximum packet size that will be negotiated
2289 by Samba. The default is 65535, which is the maximum. In some cases
2290 you may find you get better performance with a smaller value. A value
2291 below 2048 is likely to cause problems.
2292
2293 .B Default:
2294         max xmit = 65535
2295
2296 .B Example:
2297         max xmit = 8192
2298
2299 .SS message command (G)
2300
2301 This specifies what command to run when the server receives a WinPopup
2302 style message.
2303
2304 This would normally be a command that would deliver the message
2305 somehow. How this is to be done is up to your imagination.
2306
2307 What I use is:
2308
2309    message command = csh -c 'xedit %s;rm %s' &
2310
2311 This delivers the message using xedit, then removes it
2312 afterwards. NOTE THAT IT IS VERY IMPORTANT THAT THIS COMMAND RETURN
2313 IMMEDIATELY. That's why I have the & on the end. If it doesn't return
2314 immediately then your PCs may freeze when sending messages (they
2315 should recover after 30secs, hopefully).
2316
2317 All messages are delivered as the global guest user. The command takes
2318 the standard substitutions, although %u won't work (%U may be better
2319 in this case).
2320
2321 Apart from the standard substitutions, some additional ones apply. In
2322 particular:
2323
2324 %s = the filename containing the message
2325
2326 %t = the destination that the message was sent to (probably the server
2327 name)
2328
2329 %f = who the message is from
2330
2331 You could make this command send mail, or whatever else takes your
2332 fancy. Please let me know of any really interesting ideas you have.
2333
2334 Here's a way of sending the messages as mail to root:
2335
2336 message command = /bin/mail -s 'message from %f on %m' root < %s; rm %s
2337
2338 If you don't have a message command then the message won't be
2339 delivered and Samba will tell the sender there was an
2340 error. Unfortunately WfWg totally ignores the error code and carries
2341 on regardless, saying that the message was delivered.
2342
2343 If you want to silently delete it then try "message command = rm %s".
2344
2345 For the really adventurous, try something like this:
2346
2347 message command = csh -c 'csh < %s |& /usr/local/samba/bin/smbclient \e
2348                   -M %m; rm %s' &
2349
2350 this would execute the command as a script on the server, then give
2351 them the result in a WinPopup message. Note that this could cause a
2352 loop if you send a message from the server using smbclient! You better
2353 wrap the above in a script that checks for this :-)
2354
2355 .B Default:
2356         no message command
2357
2358 .B Example:
2359         message command = csh -c 'xedit %s;rm %s' &
2360
2361 .SS min print space (S)
2362
2363 This sets the minimum amount of free disk space that must be available
2364 before a user will be able to spool a print job. It is specified in
2365 kilobytes. The default is 0, which means no limit.
2366
2367 .B Default:
2368         min print space = 0
2369
2370 .B Example:
2371         min print space = 2000
2372
2373 .SS min wins ttl (G)
2374
2375 This option tells nmbd when acting as a WINS server (wins support = true)
2376 what the minimum 'time to live' of NetBIOS names that nmbd will grant will
2377 be (in seconds). You should never need to change this parameter.
2378 The default is 6 hours (21600 seconds).
2379
2380 .B Default:
2381         min wins ttl = 21600
2382
2383
2384 .SS netbios aliases (G)
2385
2386 This is a list of names that nmbd will advertise as additional
2387 names by which the Samba server is known. This allows one machine
2388 to appear in browse lists under multiple names. If a machine is
2389 acting as a browse server or logon server none of these names
2390 will be advertised as either browse server or logon servers, only
2391 the primary name of the machine will be advertised with these
2392 capabilities.
2393
2394 See also 'netbios name'.
2395
2396 .B Example:
2397    netbios aliases = TEST TEST1 TEST2
2398
2399 .SS netbios name (G)
2400
2401 This sets the NetBIOS name by which a Samba server is known. By
2402 default it is the same as the first component of the host's DNS name.
2403 If a machine is a browse server or logon server this name (or the
2404 first component of the hosts DNS name) will be the name that these
2405 services are advertised under.
2406
2407 See also 'netbios aliases'.
2408
2409 .B Example:
2410    netbios name = MYNAME
2411
2412 .SS nis homedir (G)
2413 Get the home share server from a NIS (or YP) map. For unix systems that
2414 use an automounter, the user's home directory will often be mounted on
2415 a workstation on demand from a remote server. When the Samba logon server
2416 is not the actual home directory server, two network hops are required
2417 to access the home directory and this can be very slow especially with 
2418 writing via Samba to an NFS mounted directory. This option allows samba
2419 to return the home share as being on a different server to the logon
2420 server and as long as a samba daemon is running on the home directory 
2421 server, it will be mounted on the Samba client directly from the directory
2422 server. When Samba is returning the home share to the client, it will
2423 consult the NIS (or YP) map specified in "homedir map" and return the
2424 server listed there.
2425
2426 .B Default:
2427         nis homedir = false
2428
2429 .B Example:
2430         nis homedir = true
2431
2432 .SS networkstation user login (G)
2433 This global parameter (new for 1.9.18p3) affects server level security.
2434 With this set (recommended) samba will do a full NetWkstaUserLogon to
2435 confirm that the client really should have login rights. This can cause
2436 problems with machines in trust relationships in which case you can
2437 disable it here, but be warned, we have heard that some NT machines
2438 will then allow anyone in with any password! Make sure you test it.
2439
2440 .B Default:
2441         networkstation user login = yes
2442
2443 .B Example:
2444         networkstation user login = no
2445
2446 .SS null passwords (G)
2447 Allow or disallow access to accounts that have null passwords. 
2448
2449 .B Default:
2450         null passwords = no
2451
2452 .B Example:
2453         null passwords = yes
2454
2455 .SS only guest (S)
2456 A synonym for this command is 'guest only'.
2457
2458 .SS only user (S)
2459 This is a boolean option that controls whether connections with
2460 usernames not in the user= list will be allowed. By default this
2461 option is disabled so a client can supply a username to be used by
2462 the server.
2463
2464 Note that this also means Samba won't try to deduce usernames from the
2465 service name. This can be annoying for the [homes] section. To get
2466 around this you could use "user = %S" which means your "user" list
2467 will be just the service name, which for home directories is the name
2468 of the user.
2469
2470 .B Default: 
2471         only user = False
2472
2473 .B Example: 
2474         only user = True
2475
2476 .SS oplocks (S)
2477 This boolean option tells smbd whether to issue oplocks (opportunistic
2478 locks) to file open requests on this share. The oplock code was introduced in
2479 Samba 1.9.18 and can dramatically (approx 30% or more) improve the speed
2480 of access to files on Samba servers. It allows the clients to agressively
2481 cache files locally and you may want to disable this option for unreliable
2482 network environments (it is turned on by default in Windows NT Servers).
2483 For more information see the file Speed.txt in the Samba docs/ directory.
2484
2485 Oplocks may be selectively turned off on certain files on a per share basis.
2486 See the 'veto oplock files' parameter.
2487
2488 .B Default:
2489     oplocks = True
2490
2491 .B Example:
2492     oplocks = False
2493
2494
2495 .SS os level (G)
2496 This integer value controls what level Samba advertises itself as for
2497 browse elections. See BROWSING.txt for details.
2498
2499 .SS packet size (G)
2500 The maximum transmit packet size during a raw read. This option is no
2501 longer implemented as of version 1.7.00, and is kept only so old
2502 configuration files do not become invalid.
2503
2504 .SS passwd chat (G)
2505 This string controls the "chat" conversation that takes places
2506 between smbd and the local password changing program to change the
2507 users password. The string describes a sequence of response-receive
2508 pairs that smbd uses to determine what to send to the passwd program
2509 and what to expect back. If the expected output is not received then
2510 the password is not changed.
2511
2512 This chat sequence is often quite site specific, depending on what
2513 local methods are used for password control (such as NIS+ etc).
2514
2515 The string can contain the macros %o and %n which are substituted for
2516 the old and new passwords respectively. It can also contain the
2517 standard macros \en \er \et and \es to give line-feed, carriage-return,
2518 tab and space.
2519
2520 The string can also contain a * which matches any sequence of
2521 characters.
2522
2523 Double quotes can be used to collect strings with spaces in them into
2524 a single string.
2525
2526 If the send string in any part of the chat sequence is a fullstop "."
2527 then no string is sent. Similarly, is the expect string is a fullstop
2528 then no string is expected.
2529
2530 .B Example:
2531         passwd chat = "*Enter OLD password*" %o\en "*Enter NEW password*" %n\en \e
2532                        "*Reenter NEW password*" %n\en "*Password changed*"
2533
2534
2535 .B Default:
2536        passwd chat = *old*password* %o\en *new*password* %n\en *new*password* %n\en *changed*
2537
2538 .SS passwd program (G)
2539 The name of a program that can be used to set user passwords.
2540
2541 This is only necessary if you have enabled remote password changing at
2542 compile time. Any occurrences of %u will be replaced with the user
2543 name.
2544
2545 Also note that many passwd programs insist in "reasonable" passwords,
2546 such as a minimum length, or the inclusion of mixed case chars and
2547 digits. This can pose a problem as some clients (such as Windows for
2548 Workgroups) uppercase the password before sending it. 
2549
2550 .B Default:
2551         passwd program = /bin/passwd
2552
2553 .B Example:
2554         passwd program = /sbin/passwd %u
2555
2556 .SS password level (G)
2557 Some client/server combinations have difficulty with mixed-case passwords.
2558 One offending client is Windows for Workgroups, which for some reason forces
2559 passwords to upper case when using the LANMAN1 protocol, but leaves them alone
2560 when using COREPLUS!
2561
2562 This parameter defines the maximum number of characters that may be upper case
2563 in passwords.
2564
2565 For example, say the password given was "FRED". If
2566 .B password level
2567 is set to 1 (one), the following combinations would be tried if "FRED" failed:
2568 "Fred", "fred", "fRed", "frEd", "freD". If
2569 .B password level was set to 2 (two), the following combinations would also be
2570 tried: "FRed", "FrEd", "FreD", "fREd", "fReD", "frED". And so on.
2571
2572 The higher value this parameter is set to the more likely it is that a mixed
2573 case password will be matched against a single case password. However, you
2574 should be aware that use of this parameter reduces security and increases the
2575 time taken to process a new connection.
2576
2577 A value of zero will cause only two attempts to be made - the password as is
2578 and the password in all-lower case.
2579
2580 If you find the connections are taking too long with this option then
2581 you probably have a slow crypt() routine. Samba now comes with a fast
2582 "ufc crypt" that you can select in the Makefile. You should also make
2583 sure the PASSWORD_LENGTH option is correct for your system in local.h
2584 and includes.h. On most systems only the first 8 chars of a password
2585 are significant so PASSWORD_LENGTH should be 8, but on some longer
2586 passwords are significant. The includes.h file tries to select the
2587 right length for your system.
2588
2589 .B Default:
2590         password level = 0
2591
2592 .B Example:
2593         password level = 4
2594
2595 .SS password server (G)
2596
2597 By specifying the name of another SMB server (such as a WinNT box)
2598 with this option, and using "security = server" you can get Samba to
2599 do all its username/password validation via a remote server.
2600
2601 This options sets the name of the password server to use. It must be a
2602 netbios name, so if the machine's netbios name is different from its
2603 internet name then you may have to add its netbios name to
2604 /etc/hosts.
2605
2606 The password server much be a machine capable of using the "LM1.2X002"
2607 or the "LM NT 0.12" protocol, and it must be in user level security
2608 mode. 
2609
2610 NOTE: Using a password server means your UNIX box (running Samba) is
2611 only as secure as your password server. DO NOT CHOOSE A PASSWORD
2612 SERVER THAT YOU DON'T COMPLETELY TRUST.
2613
2614 Never point a Samba server at itself for password serving. This will
2615 cause a loop and could lock up your Samba server!
2616
2617 The name of the password server takes the standard substitutions, but
2618 probably the only useful one is %m, which means the Samba server will
2619 use the incoming client as the password server. If you use this then
2620 you better trust your clients, and you better restrict them with hosts
2621 allow!
2622
2623 If you list several hosts in the "password server" option then smbd
2624 will try each in turn till it finds one that responds. This is useful
2625 in case your primary server goes down.
2626
2627 If you are using a WindowsNT server as your password server then you
2628 will have to ensure that your users are able to login from the Samba 
2629 server, as the network logon will appear to come from there rather
2630 than from the users workstation.
2631
2632 .SS path (S)
2633 A synonym for this parameter is 'directory'.
2634
2635 This parameter specifies a directory to which the user of the service is to
2636 be given access. In the case of printable services, this is where print data 
2637 will spool prior to being submitted to the host for printing.
2638
2639 For a printable service offering guest access, the service should be readonly
2640 and the path should be world-writable and have the sticky bit set. This is not
2641 mandatory of course, but you probably won't get the results you expect if you
2642 do otherwise.
2643
2644 Any occurrences of %u in the path will be replaced with the username
2645 that the client is connecting as. Any occurrences of %m will be
2646 replaced by the name of the machine they are connecting from. These
2647 replacements are very useful for setting up pseudo home directories
2648 for users.
2649
2650 Note that this path will be based on 'root dir' if one was specified.
2651 .B Default:
2652         none
2653
2654 .B Example:
2655         path = /home/fred+ 
2656
2657 .SS postexec (S)
2658
2659 This option specifies a command to be run whenever the service is
2660 disconnected. It takes the usual substitutions. The command may be run
2661 as the root on some systems.
2662
2663 An interesting example may be do unmount server resources:
2664
2665 postexec = /etc/umount /cdrom
2666
2667 See also preexec
2668
2669 .B Default:
2670       none (no command executed)
2671
2672 .B Example:
2673       postexec = echo \e"%u disconnected from %S from %m (%I)\e" >> /tmp/log
2674
2675 .SS postscript (S)
2676 This parameter forces a printer to interpret the print files as
2677 postscript. This is done by adding a %! to the start of print output. 
2678
2679 This is most useful when you have lots of PCs that persist in putting
2680 a control-D at the start of print jobs, which then confuses your
2681 printer.
2682
2683 .B Default: 
2684         postscript = False
2685
2686 .B Example: 
2687         postscript = True
2688
2689 .SS preexec (S)
2690
2691 This option specifies a command to be run whenever the service is
2692 connected to. It takes the usual substitutions.
2693
2694 An interesting example is to send the users a welcome message every
2695 time they log in. Maybe a message of the day? Here is an example:
2696
2697 preexec = csh -c 'echo \e"Welcome to %S!\e" | \e
2698        /usr/local/samba/bin/smbclient -M %m -I %I' &
2699
2700 Of course, this could get annoying after a while :-)
2701
2702 See also postexec
2703
2704 .B Default:
2705         none (no command executed)
2706
2707 .B Example:
2708         preexec = echo \e"%u connected to %S from %m (%I)\e" >> /tmp/log
2709
2710 .SS preferred master (G)
2711 This boolean parameter controls if Samba is a preferred master browser
2712 for its workgroup.
2713 If this is set to true, on startup, samba will force an election, 
2714 and it will have a slight advantage in winning the election.  
2715 It is recommended that this parameter is used in conjunction 
2716 with domain master = yes, so that samba can guarantee becoming 
2717 a domain master.  
2718
2719 Use this option with caution, because if there are several hosts
2720 (whether samba servers, Windows 95 or NT) that are preferred master
2721 browsers on the same subnet, they will each periodically and continuously
2722 attempt to become the local master browser.  This will result in
2723 unnecessary broadcast traffic and reduced browsing capabilities.
2724
2725 See
2726 .B os level = nn
2727
2728 .B Default:
2729         preferred master = no
2730
2731 .SS preload
2732 This is an alias for "auto services"
2733
2734 .SS preserve case (S)
2735
2736 This controls if new filenames are created with the case that the
2737 client passes, or if they are forced to be the "default" case.
2738
2739 .B Default:
2740        preserve case = no
2741
2742 See the section on "NAME MANGLING" for a fuller discussion.
2743
2744 .SS print command (S)
2745 After a print job has finished spooling to a service, this command will be
2746 used via a system() call to process the spool file. Typically the command 
2747 specified will submit the spool file to the host's printing subsystem, but
2748 there is no requirement that this be the case. The server will not remove the
2749 spool file, so whatever command you specify should remove the spool file when
2750 it has been processed, otherwise you will need to manually remove old spool
2751 files.
2752
2753 The print command is simply a text string. It will be used verbatim,
2754 with two exceptions: All occurrences of "%s" will be replaced by the
2755 appropriate spool file name, and all occurrences of "%p" will be
2756 replaced by the appropriate printer name. The spool file name is
2757 generated automatically by the server, the printer name is discussed
2758 below.
2759
2760 The full path name will be used for the filename if %s is not preceded
2761 by a /. If you don't like this (it can stuff up some lpq output) then
2762 use %f instead. Any occurrences of %f get replaced by the spool
2763 filename without the full path at the front.
2764
2765 The print command MUST contain at least one occurrence of "%s" or %f -
2766 the "%p" is optional. At the time a job is submitted, if no printer
2767 name is supplied the "%p" will be silently removed from the printer
2768 command.
2769
2770 If specified in the [global] section, the print command given will be used
2771 for any printable service that does not have its own print command specified.
2772
2773 If there is neither a specified print command for a printable service nor a 
2774 global print command, spool files will be created but not processed and (most
2775 importantly) not removed.
2776
2777 Note that printing may fail on some UNIXes from the "nobody"
2778 account. If this happens then create an alternative guest account that
2779 can print and set the "guest account" in the [global] section.
2780
2781 You can form quite complex print commands by realising that they are
2782 just passed to a shell. For example the following will log a print
2783 job, print the file, then remove it. Note that ; is the usual
2784 separator for command in shell scripts.
2785
2786 print command = echo Printing %s >> /tmp/print.log; lpr -P %p %s; rm %s
2787
2788 You may have to vary this command considerably depending on how you
2789 normally print files on your system.
2790
2791 .B Default:
2792         print command = lpr -r -P %p %s
2793
2794 .B Example:
2795         print command = /usr/local/samba/bin/myprintscript %p %s
2796 .SS print ok (S)
2797 See
2798 .B printable.
2799 .SS printable (S)
2800 A synonym for this parameter is 'print ok'.
2801
2802 If this parameter is 'yes', then clients may open, write to and submit spool 
2803 files on the directory specified for the service.
2804
2805 Note that a printable service will ALWAYS allow writing to the service path
2806 (user privileges permitting) via the spooling of print data. The 'read only'
2807 parameter controls only non-printing access to the resource.
2808
2809 .B Default:
2810         printable = no
2811
2812 .B Example:
2813         printable = yes
2814
2815 .SS printcap name (G)
2816 This parameter may be used to override the compiled-in default printcap
2817 name used by the server (usually /etc/printcap). See the discussion of the
2818 [printers] section above for reasons why you might want to do this.
2819
2820 On SystemV systems that use lpstat to list available printers you
2821 can use "printcap name = lpstat" to automatically obtain lists of
2822 available printers. This is the default for systems that define 
2823 SYSV at compile time in Samba (this includes most SystemV based
2824 systems). If "printcap name" is set to lpstat on these systems then
2825 Samba will launch "lpstat -v" and attempt to parse the output to
2826 obtain a printer list.
2827
2828 A minimal printcap file would look something like this:
2829
2830 print1|My Printer 1
2831 .br
2832 print2|My Printer 2
2833 .br
2834 print3|My Printer 3
2835 .br
2836 print4|My Printer 4
2837 .br
2838 print5|My Printer 5
2839
2840 where the | separates aliases of a printer. The fact that the second
2841 alias has a space in it gives a hint to Samba that it's a comment.
2842
2843 NOTE: Under AIX the default printcap name is "/etc/qconfig". Samba
2844 will assume the file is in AIX "qconfig" format if the string
2845 "/qconfig" appears in the printcap filename.
2846
2847 .B Default:
2848         printcap name = /etc/printcap
2849
2850 .B Example:
2851         printcap name = /etc/myprintcap
2852
2853 .SS printer (S)
2854 A synonym for this parameter is 'printer name'.
2855
2856 This parameter specifies the name of the printer to which print jobs spooled
2857 through a printable service will be sent.
2858
2859 If specified in the [global] section, the printer name given will be used
2860 for any printable service that does not have its own printer name specified.
2861
2862 .B Default:
2863         none (but may be 'lp' on many systems)
2864
2865 .B Example:
2866         printer name = laserwriter
2867
2868 .SS printer driver (S)
2869 This option allows you to control the string that clients receive when
2870 they ask the server for the printer driver associated with a
2871 printer. If you are using Windows95 or WindowsNT then you can use this
2872 to automate the setup of printers on your system.
2873
2874 You need to set this parameter to the exact string (case sensitive)
2875 that describes the appropriate printer driver for your system. 
2876 If you don't know the exact string to use then you should first try
2877 with no "printer driver" option set and the client will give you a
2878 list of printer drivers. The appropriate strings are shown in a
2879 scrollbox after you have chosen the printer manufacturer.
2880
2881 .B Example:
2882         printer driver = HP LaserJet 4L
2883
2884 .SS printer name (S)
2885 See
2886 .B printer.
2887
2888 .SS printer driver file (G)
2889 This parameter tells Samba where the printer driver definition file,
2890 used when serving drivers to Windows 95 clients, is to be found. If
2891 this is not set, the default is :
2892
2893 SAMBA_INSTALL_DIRECTORY/lib/printers.def
2894
2895 This file is created from Windows 95 'msprint.def' files found on the
2896 Windows 95 client system. For more details on setting up serving of
2897 printer drivers to Windows 95 clients, see the documentation file
2898 docs/PRINTER_DRIVER.txt.
2899
2900 .B Default:
2901     None (set in compile).
2902
2903 .B Example:
2904     printer driver file = /usr/local/samba/printers/drivers.def
2905
2906 Related parameters.
2907 .B printer driver location
2908
2909 .SS printer driver location (S)
2910 This parameter tells clients of a particular printer share where
2911 to find the printer driver files for the automatic installation
2912 of drivers for Windows 95 machines. If Samba is set up to serve
2913 printer drivers to Windows 95 machines, this should be set to
2914
2915 \e\eMACHINE\ePRINTER$
2916
2917 Where MACHINE is the NetBIOS name of your Samba server, and PRINTER$ 
2918 is a share you set up for serving printer driver files. For more 
2919 details on setting this up see the documentation file 
2920 docs/PRINTER_DRIVER.txt.
2921
2922 .B Default:
2923     None
2924
2925 .B Example:
2926     printer driver location = \e\eMACHINE\ePRINTER$
2927
2928 Related paramerers.
2929 .B printer driver file
2930
2931
2932 .SS printing (S)
2933 This parameters controls how printer status information is interpreted
2934 on your system, and also affects the default values for the "print
2935 command", "lpq command" and "lprm command".
2936
2937 Currently six printing styles are supported. They are "printing =
2938 bsd", "printing = sysv", "printing = hpux", "printing = aix",
2939 "printing = qnx" and "printing = plp".
2940
2941 To see what the defaults are for the other print commands when using
2942 these three options use the "testparm" program.
2943
2944 As of version 1.9.18 of Samba this option can be set on a per printer basis
2945
2946 .SS protocol (G)
2947 The value of the parameter (a string) is the highest protocol level that will
2948 be supported by the server. 
2949
2950 Possible values are CORE, COREPLUS, LANMAN1, LANMAN2 and NT1. The relative
2951 merits of each are discussed in the README file.
2952
2953 Normally this option should not be set as the automatic negotiation
2954 phase in the SMB protocol takes care of choosing the appropriate protocol.
2955
2956 .B Default:
2957         protocol = NT1
2958
2959 .B Example:
2960         protocol = LANMAN1
2961 .SS public (S)
2962 A synonym for this parameter is 'guest ok'.
2963
2964 If this parameter is 'yes' for a service, then no password is required
2965 to connect to the service. Privileges will be those of the guest
2966 account.
2967
2968 See the section below on user/password validation for more information about
2969 this option.
2970
2971 .B Default:
2972         public = no
2973
2974 .B Example:
2975         public = yes
2976 .SS read list (S)
2977 This is a list of users that are given read-only access to a
2978 service. If the connecting user is in this list then they will
2979 not be given write access, no matter what the "read only" option
2980 is set to. The list can include group names using the @group syntax.
2981
2982 See also the "write list" option
2983
2984 .B Default:
2985      read list =
2986
2987 .B Example:
2988      read list = mary, @students
2989
2990 .SS read only (S)
2991 See
2992 .B writable
2993 and
2994 .B write ok.
2995 Note that this is an inverted synonym for writable and write ok.
2996 .SS read prediction (G)
2997 This options enables or disables the read prediction code used to
2998 speed up reads from the server. When enabled the server will try to
2999 pre-read data from the last accessed file that was opened read-only
3000 while waiting for packets.
3001
3002 .SS Default:
3003         read prediction = False
3004
3005 .SS Example:
3006         read prediction = True
3007 .SS read raw (G)
3008 This parameter controls whether or not the server will support raw reads when
3009 transferring data to clients.
3010
3011 If enabled, raw reads allow reads of 65535 bytes in one packet. This
3012 typically provides a major performance benefit.
3013
3014 However, some clients either negotiate the allowable block size incorrectly
3015 or are incapable of supporting larger block sizes, and for these clients you
3016 may need to disable raw reads.
3017
3018 In general this parameter should be viewed as a system tuning tool and left
3019 severely alone. See also
3020 .B write raw.
3021
3022 .B Default:
3023         read raw = yes
3024
3025 .B Example:
3026         read raw = no
3027 .SS read size (G)
3028
3029 The option "read size" affects the overlap of disk reads/writes with
3030 network reads/writes. If the amount of data being transferred in
3031 several of the SMB commands (currently SMBwrite, SMBwriteX and
3032 SMBreadbraw) is larger than this value then the server begins writing
3033 the data before it has received the whole packet from the network, or
3034 in the case of SMBreadbraw, it begins writing to the network before
3035 all the data has been read from disk.
3036
3037 This overlapping works best when the speeds of disk and network access
3038 are similar, having very little effect when the speed of one is much
3039 greater than the other.
3040
3041 The default value is 2048, but very little experimentation has been
3042 done yet to determine the optimal value, and it is likely that the best
3043 value will vary greatly between systems anyway. A value over 65536 is
3044 pointless and will cause you to allocate memory unnecessarily.
3045
3046 .B Default:
3047         read size = 2048
3048
3049 .B Example:
3050         read size = 8192
3051
3052 .SS remote announce (G)
3053
3054 This option allows you to setup nmbd to periodically announce itself
3055 to arbitrary IP addresses with an arbitrary workgroup name. 
3056
3057 This is useful if you want your Samba server to appear in a remote
3058 workgroup for which the normal browse propagation rules don't
3059 work. The remote workgroup can be anywhere that you can send IP
3060 packets to.
3061
3062 For example:
3063
3064        remote announce = 192.168.2.255/SERVERS 192.168.4.255/STAFF
3065
3066 the above line would cause nmbd to announce itself to the two given IP
3067 addresses using the given workgroup names. If you leave out the
3068 workgroup name then the one given in the "workgroup" option is used
3069 instead. 
3070
3071 The IP addresses you choose would normally be the broadcast addresses
3072 of the remote networks, but can also be the IP addresses of known
3073 browse masters if your network config is that stable.
3074
3075 This option replaces similar functionality from the nmbd lmhosts file.
3076
3077 .SS remote browse sync (G)
3078
3079 This option allows you to setup nmbd to periodically request synchronisation
3080 of browse lists with the master browser of a samba server that is on a remote
3081 segment. This option will allow you to gain browse lists for multiple
3082 workgroups across routed networks. This is done in a manner that does not work
3083 with any non-samba servers.
3084
3085 This is useful if you want your Samba server and all local clients
3086 to appear in a remote workgroup for which the normal browse propagation
3087 rules don't work. The remote workgroup can be anywhere that you can send IP
3088 packets to.
3089
3090 For example:
3091
3092        remote browse sync = 192.168.2.255 192.168.4.255
3093
3094 the above line would cause nmbd to request the master browser on the
3095 specified subnets or addresses to synchronise their browse lists with
3096 the local server.
3097
3098 The IP addresses you choose would normally be the broadcast addresses
3099 of the remote networks, but can also be the IP addresses of known
3100 browse masters if your network config is that stable. If a machine IP
3101 address is given Samba makes NO attempt to validate that the remote
3102 machine is available, is listening, nor that it is in fact the browse
3103 master on it's segment.
3104
3105
3106 .SS revalidate (S)
3107
3108 This options controls whether Samba will allow a previously validated
3109 username/password pair to be used to attach to a share. Thus if you
3110 connect to \e\eserver\eshare1 then to \e\eserver\eshare2 it won't
3111 automatically allow the client to request connection to the second
3112 share as the same username as the first without a password.
3113
3114 If "revalidate" is True then the client will be denied automatic
3115 access as the same username.
3116
3117 .B Default:
3118         revalidate = False
3119
3120 .B Example:
3121         revalidate = True
3122
3123 .SS root (G)
3124 See
3125 .B root directory.
3126 .SS root dir (G)
3127 See
3128 .B root directory.
3129 .SS root directory (G)
3130 Synonyms for this parameter are 'root dir' and 'root'.
3131
3132 The server will chroot() to this directory on startup. This is not 
3133 strictly necessary for secure operation. Even without it the server
3134 will deny access to files not in one of the service entries. It may 
3135 also check for, and deny access to, soft links to other parts of the 
3136 filesystem, or attempts to use .. in file names to access other 
3137 directories (depending on the setting of the "wide links" parameter).
3138
3139 Adding a "root dir" entry other than "/" adds an extra level of security, 
3140 but at a price. It absolutely ensures that no access is given to files not
3141 in the sub-tree specified in the "root dir" option, *including* some files 
3142 needed for complete operation of the server. To maintain full operability
3143 of the server you will need to mirror some system files into the "root dir"
3144 tree. In particular you will need to mirror /etc/passwd (or a subset of it),
3145 and any binaries or configuration files needed for printing (if required). 
3146 The set of files that must be mirrored is operating system dependent.
3147
3148 .B Default:
3149         root directory = /
3150
3151 .B Example:
3152         root directory = /homes/smb
3153 .SS root postexec (S)
3154
3155 This is the same as postexec except that the command is run as
3156 root. This is useful for unmounting filesystems (such as cdroms) after
3157 a connection is closed.
3158
3159 .SS root preexec (S)
3160
3161 This is the same as preexec except that the command is run as
3162 root. This is useful for mounting filesystems (such as cdroms) before
3163 a connection is finalised.
3164
3165 .SS security (G)
3166 This option affects how clients respond to Samba.
3167
3168 The option sets the "security mode bit" in replies to protocol negotiations
3169 to turn share level security on or off. Clients decide based on this bit 
3170 whether (and how) to transfer user and password information to the server.
3171
3172 The default is "security=SHARE", mainly because that was the only
3173 option at one stage.
3174
3175 The alternatives are "security = user" or "security = server". 
3176
3177 If your PCs use usernames that are the same as their usernames on the
3178 UNIX machine then you will want to use "security = user". If you
3179 mostly use usernames that don't exist on the UNIX box then use
3180 "security = share".
3181
3182 There is a bug in WfWg that may affect your decision. When in user
3183 level security a WfWg client will totally ignore the password you type
3184 in the "connect drive" dialog box. This makes it very difficult (if
3185 not impossible) to connect to a Samba service as anyone except the
3186 user that you are logged into WfWg as.
3187
3188 If you use "security = server" then Samba will try to validate the
3189 username/password by passing it to another SMB server, such as an NT
3190 box. If this fails it will revert to "security = USER".
3191
3192 See the "password server" option for more details.
3193
3194 .B Default:
3195         security = SHARE
3196
3197 .B Example:
3198         security = USER
3199 .SS server string (G)
3200 This controls what string will show up in the printer comment box in
3201 print manager and next to the IPC connection in "net view". It can be
3202 any string that you wish to show to your users.
3203
3204 It also sets what will appear in browse lists next to the machine name.
3205
3206 A %v will be replaced with the Samba version number.
3207
3208 A %h will be replaced with the hostname.
3209
3210 .B Default:
3211         server string = Samba %v
3212
3213 .B Example:
3214         server string = University of GNUs Samba Server
3215
3216 .SS set directory (S)
3217 If 'set directory = no', then users of the service may not use the setdir
3218 command to change directory.
3219
3220 The setdir command is only implemented in the Digital Pathworks client. See the
3221 Pathworks documentation for details.
3222
3223 .B Default:
3224         set directory = no
3225
3226 .B Example:
3227         set directory = yes
3228
3229 .SS shared file entries (G)
3230 This parameter has been removed (as of Samba 1.9.18 and above). The new
3231 System V shared memory code prohibits the user from allocating the
3232 share hash bucket size directly.
3233
3234 .SS shared mem size (G)
3235 This parameter is only useful when Samba has been compiled with FAST_SHARE_MODES.
3236 It specifies the size of the shared memory (in bytes) to use between smbd 
3237 processes. You should never change this parameter unless you have studied 
3238 the source and know what you are doing. This parameter defaults to 1024
3239 multiplied by the setting of the maximum number of open files in the
3240 file local.h in the Samba source code. MAX_OPEN_FILES is normally set
3241 to 100, so this parameter defaults to 102400 bytes.
3242
3243 .B Default
3244         shared mem size = 102400
3245
3246 .SS smb passwd file (G)
3247 This option sets the path to the encrypted smbpasswd file. This is a *VERY
3248 DANGEROUS OPTION* if the smb.conf is user writable. By default the path
3249 to the smbpasswd file is compiled into Samba.
3250
3251 .SS smbrun (G)
3252 This sets the full path to the smbrun binary. This defaults to the
3253 value in the Makefile.
3254
3255 You must get this path right for many services to work correctly.
3256
3257 .B Default:
3258 taken from Makefile
3259
3260 .B Example:
3261         smbrun = /usr/local/samba/bin/smbrun
3262
3263 .SS share modes (S)
3264
3265 This enables or disables the honouring of the "share modes" during a
3266 file open. These modes are used by clients to gain exclusive read or
3267 write access to a file. 
3268
3269 These open modes are not directly supported by UNIX, so they are
3270 simulated using lock files in the "lock directory". The "lock
3271 directory" specified in smb.conf must be readable by all users.
3272
3273 The share modes that are enabled by this option are DENY_DOS,
3274 DENY_ALL, DENY_READ, DENY_WRITE, DENY_NONE and DENY_FCB.
3275
3276 Enabling this option gives full share compatibility but may cost a bit
3277 of processing time on the UNIX server. They are enabled by default.
3278
3279 .B Default:
3280         share modes = yes
3281
3282 .B Example:
3283         share modes = no
3284
3285 .SS short preserve case (S)
3286
3287 This controls if new short filenames are created with the case that
3288 the client passes, or if they are forced to be the "default" case.
3289
3290 .B Default:
3291        short preserve case = no
3292
3293 See the section on "NAME MANGLING" for a fuller discussion.
3294
3295 .SS socket address (G)
3296
3297 This option allows you to control what address Samba will listen for
3298 connections on. This is used to support multiple virtual interfaces on
3299 the one server, each with a different configuration.
3300
3301 By default samba will accept connections on any address.
3302
3303 .B Example:
3304         socket address = 192.168.2.20
3305
3306 .SS socket options (G)
3307 This option (which can also be invoked with the -O command line
3308 option) allows you to set socket options to be used when talking with
3309 the client.
3310
3311 Socket options are controls on the networking layer of the operating
3312 systems which allow the connection to be tuned.
3313
3314 This option will typically be used to tune your Samba server for
3315 optimal performance for your local network. There is no way that Samba
3316 can know what the optimal parameters are for your net, so you must
3317 experiment and choose them yourself. I strongly suggest you read the
3318 appropriate documentation for your operating system first (perhaps
3319 "man setsockopt" will help).
3320
3321 You may find that on some systems Samba will say "Unknown socket
3322 option" when you supply an option. This means you either mis-typed it
3323 or you need to add an include file to includes.h for your OS. If the
3324 latter is the case please send the patch to me
3325 (samba-bugs@samba.anu.edu.au).
3326
3327 Any of the supported socket options may be combined in any way you
3328 like, as long as your OS allows it.
3329
3330 This is the list of socket options currently settable using this
3331 option:
3332
3333   SO_KEEPALIVE
3334
3335   SO_REUSEADDR
3336
3337   SO_BROADCAST
3338
3339   TCP_NODELAY
3340
3341   IPTOS_LOWDELAY
3342
3343   IPTOS_THROUGHPUT
3344
3345   SO_SNDBUF *
3346
3347   SO_RCVBUF *
3348
3349   SO_SNDLOWAT *
3350
3351   SO_RCVLOWAT *
3352
3353 Those marked with a * take an integer argument. The others can
3354 optionally take a 1 or 0 argument to enable or disable the option, by
3355 default they will be enabled if you don't specify 1 or 0.
3356
3357 To specify an argument use the syntax SOME_OPTION=VALUE for example
3358 SO_SNDBUF=8192. Note that you must not have any spaces before or after
3359 the = sign.
3360
3361 If you are on a local network then a sensible option might be
3362
3363 socket options = IPTOS_LOWDELAY
3364
3365 If you have an almost unloaded local network and you don't mind a lot
3366 of extra CPU usage in the server then you could try
3367
3368 socket options = IPTOS_LOWDELAY TCP_NODELAY
3369
3370 If you are on a wide area network then perhaps try setting
3371 IPTOS_THROUGHPUT. 
3372
3373 Note that several of the options may cause your Samba server to fail
3374 completely. Use these options with caution!
3375
3376 .B Default:
3377         no socket options
3378
3379 .B Example:
3380         socket options = IPTOS_LOWDELAY 
3381
3382
3383
3384
3385 .SS status (G)
3386 This enables or disables logging of connections to a status file that
3387 .B smbstatus
3388 can read.
3389
3390 With this disabled
3391 .B smbstatus
3392 won't be able to tell you what
3393 connections are active.
3394
3395 .B Default:
3396         status = yes
3397
3398 .B Example:
3399         status = no
3400
3401 .SS strict locking (S)
3402 This is a boolean that controls the handling of file locking in the
3403 server. When this is set to yes the server will check every read and
3404 write access for file locks, and deny access if locks exist. This can
3405 be slow on some systems.
3406
3407 When strict locking is "no" the server does file lock checks only when
3408 the client explicitly asks for them. 
3409
3410 Well behaved clients always ask for lock checks when it is important,
3411 so in the vast majority of cases "strict locking = no" is preferable.
3412
3413 .B Default:
3414         strict locking = no
3415
3416 .B Example:
3417         strict locking = yes
3418
3419 .SS strip dot (G)
3420 This is a boolean that controls whether to strip trailing dots off
3421 UNIX filenames. This helps with some CDROMs that have filenames ending in a
3422 single dot.
3423
3424 .B Default:
3425         strip dot = no
3426
3427 .B Example:
3428     strip dot = yes
3429
3430 .SS syslog (G)
3431 This parameter maps how Samba debug messages are logged onto the
3432 system syslog logging levels. Samba debug level zero maps onto
3433 syslog LOG_ERR, debug level one maps onto LOG_WARNING, debug
3434 level two maps to LOG_NOTICE, debug level three maps onto LOG_INFO.
3435 The paramter sets the threshold for doing the mapping, all Samba
3436 debug messages above this threashold are mapped to syslog LOG_DEBUG
3437 messages.
3438
3439 .B Default:
3440
3441         syslog = 1
3442
3443 .SS syslog only (G)
3444 If this parameter is set then Samba debug messages are logged into
3445 the system syslog only, and not to the debug log files.
3446
3447 .B Default:
3448         syslog only = no
3449
3450 .SS sync always (S)
3451
3452 This is a boolean parameter that controls whether writes will always
3453 be written to stable storage before the write call returns. If this is
3454 false then the server will be guided by the client's request in each
3455 write call (clients can set a bit indicating that a particular write
3456 should be synchronous). If this is true then every write will be
3457 followed by a fsync() call to ensure the data is written to disk.
3458
3459 .B Default:
3460         sync always = no
3461
3462 .B Example:
3463         sync always = yes
3464
3465 .SS time offset (G)
3466 This parameter is a setting in minutes to add to the normal GMT to
3467 local time conversion. This is useful if you are serving a lot of PCs
3468 that have incorrect daylight saving time handling.
3469
3470 .B Default:
3471         time offset = 0
3472
3473 .B Example:
3474         time offset = 60
3475
3476 .SS time server (G)
3477 This parameter determines if nmbd advertises itself as a time server
3478 to Windows clients. The default is False.
3479
3480 .B Default:
3481         time server = False
3482
3483 .B Example:
3484         time server = True
3485
3486 .SS unix realname (G)
3487 This boolean parameter when set causes samba to supply the real name field
3488 from the unix password file to the client. This is useful for setting up
3489 mail clients and WWW browsers on systems used by more than one person.
3490
3491 .B Default:
3492         unix realname = no
3493
3494 .B Example:
3495         unix realname = yes
3496
3497 .SS user (S)
3498 See
3499 .B username.
3500 .SS username (S)
3501 A synonym for this parameter is 'user'.
3502
3503 Multiple users may be specified in a comma-delimited list, in which case the
3504 supplied password will be tested against each username in turn (left to right).
3505
3506 The username= line is needed only when the PC is unable to supply its own
3507 username. This is the case for the coreplus protocol or where your
3508 users have different WfWg usernames to UNIX usernames. In both these
3509 cases you may also be better using the \e\eserver\eshare%user syntax
3510 instead. 
3511
3512 The username= line is not a great solution in many cases as it means Samba
3513 will try to validate the supplied password against each of the
3514 usernames in the username= line in turn. This is slow and a bad idea for
3515 lots of users in case of duplicate passwords. You may get timeouts or
3516 security breaches using this parameter unwisely.
3517
3518 Samba relies on the underlying UNIX security. This parameter does not
3519 restrict who can login, it just offers hints to the Samba server as to
3520 what usernames might correspond to the supplied password. Users can
3521 login as whoever they please and they will be able to do no more
3522 damage than if they started a telnet session. The daemon runs as the
3523 user that they log in as, so they cannot do anything that user cannot
3524 do.
3525
3526 To restrict a service to a particular set of users you can use the
3527 "valid users=" line.
3528
3529 If any of the usernames begin with a @ then the name will be looked up
3530 in the groups file and will expand to a list of all users in the group
3531 of that name. Note that searching though a groups file can take quite
3532 some time, and some clients may time out during the search.
3533
3534 See the section below on username/password validation for more information
3535 on how this parameter determines access to the services.
3536
3537 .B Default:
3538         The guest account if a guest service, else the name of the service.
3539
3540 .B Examples:
3541         username = fred
3542         username = fred, mary, jack, jane, @users, @pcgroup
3543
3544 .SS username level (G)
3545
3546 This option helps Samba to try and 'guess' at the real UNIX username,
3547 as many DOS clients send an all-uppercase username. By default Samba
3548 tries all lowercase, followed by the username with the first letter
3549 capitalized, and fails if the username is not found on the UNIX machine.
3550
3551 If this parameter is set to non-zero the behaviour changes. This 
3552 parameter is a number that specifies the number of uppercase combinations 
3553 to try whilst trying to determine the UNIX user name. The higher the number
3554 the more combinations will be tried, but the slower the discovery
3555 of usernames will be. Use this parameter when you have strange
3556 usernames on your UNIX machine, such as 'AstrangeUser'.
3557
3558 .B Default:
3559     username level = 0
3560
3561 .B Example:
3562     username level = 5
3563
3564 .SS username map (G)
3565
3566 This option allows you to to specify a file containing a mapping of
3567 usernames from the clients to the server. This can be used for several
3568 purposes. The most common is to map usernames that users use on DOS or
3569 Windows machines to those that the UNIX box uses. The other is to map
3570 multiple users to a single username so that they can more easily share
3571 files.
3572
3573 The map file is parsed line by line. Each line should contain a single
3574 UNIX username on the left then a '=' followed by a list of usernames
3575 on the right. The list of usernames on the right may contain names of
3576 the form @group in which case they will match any UNIX username in
3577 that group. The special client name '*' is a wildcard and matches any
3578 name.
3579
3580 The file is processed on each line by taking the supplied username and
3581 comparing it with each username on the right hand side of the '='
3582 signs. If the supplied name matches any of the names on the right
3583 hand side then it is replaced with the name on the left. Processing
3584 then continues with the next line.
3585
3586 If any line begins with a '#' or a ';' then it is ignored
3587
3588 If any line begins with an ! then the processing will stop after that
3589 line if a mapping was done by the line. Otherwise mapping continues
3590 with every line being processed. Using ! is most useful when you have
3591 a wildcard mapping line later in the file.
3592
3593 For example to map from the name "admin" or "administrator" to the UNIX
3594 name "root" you would use
3595
3596         root = admin administrator
3597
3598 Or to map anyone in the UNIX group "system" to the UNIX name "sys" you
3599 would use
3600
3601         sys = @system
3602
3603 You can have as many mappings as you like in a username map file.
3604
3605 You can map Windows usernames that have spaces in them by using double
3606 quotes around the name. For example:
3607
3608         tridge = "Andrew Tridgell"
3609
3610 would map the windows username "Andrew Tridgell" to the unix username
3611 tridge.
3612
3613 The following example would map mary and fred to the unix user sys,
3614 and map the rest to guest. Note the use of the ! to tell Samba to stop
3615 processing if it gets a match on that line.
3616
3617         !sys = mary fred
3618         guest = *
3619
3620
3621 Note that the remapping is applied to all occurrences of
3622 usernames. Thus if you connect to "\e\eserver\efred" and "fred" is
3623 remapped to "mary" then you will actually be connecting to
3624 "\e\eserver\emary" and will need to supply a password suitable for
3625 "mary" not "fred". The only exception to this is the username passed
3626 to the "password server" (if you have one). The password server will
3627 receive whatever username the client supplies without modification.
3628
3629 Also note that no reverse mapping is done. The main effect this has is
3630 with printing. Users who have been mapped may have trouble deleting
3631 print jobs as PrintManager under WfWg will think they don't own the
3632 print job.
3633
3634 .B Default
3635         no username map
3636
3637 .B Example
3638         username map = /usr/local/samba/lib/users.map
3639
3640 .SS valid chars (S)
3641
3642 The option allows you to specify additional characters that should be
3643 considered valid by the server in filenames. This is particularly
3644 useful for national character sets, such as adding u-umlaut or a-ring.
3645
3646 The option takes a list of characters in either integer or character
3647 form with spaces between them. If you give two characters with a colon
3648 between them then it will be taken as an lowercase:uppercase pair.
3649
3650 If you have an editor capable of entering the characters into the
3651 config file then it is probably easiest to use this method. Otherwise
3652 you can specify the characters in octal, decimal or hexadecimal form
3653 using the usual C notation.
3654
3655 For example to add the single character 'Z' to the charset (which is a
3656 pointless thing to do as it's already there) you could do one of the
3657 following
3658
3659 valid chars = Z
3660 valid chars = z:Z
3661 valid chars = 0132:0172
3662
3663 The last two examples above actually add two characters, and alter
3664 the uppercase and lowercase mappings appropriately.
3665
3666 Note that you MUST specify this parameter after the "client code page"
3667 parameter if you have both set. If "client code page" is set after
3668 the "valid chars" parameter the "valid chars" settings will be
3669 overwritten.
3670
3671 See also the "client code page" parameter.
3672
3673 .B Default
3674 .br
3675         Samba defaults to using a reasonable set of valid characters
3676 .br
3677         for english systems
3678
3679 .B Example
3680         valid chars = 0345:0305 0366:0326 0344:0304
3681
3682 The above example allows filenames to have the swedish characters in
3683 them. 
3684
3685 NOTE: It is actually quite difficult to correctly produce a "valid
3686 chars" line for a particular system. To automate the process
3687 tino@augsburg.net has written a package called "validchars" which will
3688 automatically produce a complete "valid chars" line for a given client
3689 system. Look in the examples subdirectory for this package.
3690
3691 .SS valid users (S)
3692 This is a list of users that should be allowed to login to this
3693 service. A name starting with @ is interpreted as a UNIX group.
3694
3695 If this is empty (the default) then any user can login. If a username
3696 is in both this list and the "invalid users" list then access is
3697 denied for that user.
3698
3699 The current servicename is substituted for %S. This is useful in the
3700 [homes] section.
3701
3702 See also "invalid users"
3703
3704 .B Default
3705         No valid users list. (anyone can login)
3706
3707 .B Example
3708         valid users = greg, @pcusers
3709
3710
3711 .SS veto files(S)
3712 This is a list of files and directories that are neither visible nor
3713 accessible.  Each entry in the list must be separated by a "/", which
3714 allows spaces to be included in the entry.  '*' and '?' can be used to
3715 specify multiple files or directories as in DOS wildcards.
3716
3717 Each entry must be a unix path, not a DOS path and must not include the 
3718 unix directory separator "/".
3719
3720 Note that the case sensitivity option is applicable in vetoing files.
3721
3722 One feature of the veto files parameter that it is important to be
3723 aware of, is that if a directory contains nothing but files that
3724 match the veto files parameter (which means that Windows/DOS clients
3725 cannot ever see them) is deleted, the veto files within that directory
3726 *are automatically deleted* along with it, if the user has UNIX permissions
3727 to do so.
3728  
3729 Setting this parameter will affect the performance of Samba, as
3730 it will be forced to check all files and directories for a match
3731 as they are scanned.
3732
3733 See also "hide files" and "case sensitive"
3734
3735 .B Default
3736         No files or directories are vetoed.
3737
3738 .B Examples
3739     Example 1.
3740     Veto any files containing the word Security, 
3741     any ending in .tmp, and any directory containing the
3742     word root.
3743
3744         veto files = /*Security*/*.tmp/*root*/
3745
3746     Example 2.
3747     Veto the Apple specific files that a NetAtalk server
3748     creates.
3749
3750     veto files = /.AppleDouble/.bin/.AppleDesktop/Network Trash Folder/
3751
3752 .SS veto oplock files (S)
3753 This parameter is only valid when the 'oplocks' parameter is turned on
3754 for a share. It allows the Samba administrator to selectively turn off
3755 the granting of oplocks on selected files that match a wildcarded list,
3756 similar to the wildcarded list used in the 'veto files' parameter.
3757
3758 .B Default
3759     No files are vetoed for oplock grants.
3760
3761 .B Examples
3762 You might want to do this on files that you know will be heavily
3763 contended for by clients. A good example of this is in the NetBench
3764 SMB benchmark program, which causes heavy client contention for files
3765 ending in .SEM. To cause Samba not to grant oplocks on these files
3766 you would use the line (either in the [global] section or in the section
3767 for the particular NetBench share :
3768
3769      veto oplock files = /*.SEM/
3770
3771 .SS volume (S)
3772 This allows you to override the volume label returned for a
3773 share. Useful for CDROMs with installation programs that insist on a
3774 particular volume label.
3775
3776 The default is the name of the share
3777
3778 .SS wide links (S)
3779 This parameter controls whether or not links in the UNIX file system may be
3780 followed by the server. Links that point to areas within the directory tree
3781 exported by the server are always allowed; this parameter controls access 
3782 only to areas that are outside the directory tree being exported.
3783
3784 .B Default:
3785         wide links = yes
3786
3787 .B Example:
3788         wide links = no
3789
3790 .SS win95 bug compatibility (G)
3791
3792 This boolean controls the behavior of smbd with respect to the reporting
3793 of 'access time' on files and directories. With this set to true, Samba
3794 will return the modify time (UNIX mtime) as the access time to the client.
3795
3796 This is sometimes desirable due to the fact that in Windows, a files
3797 access time is only updated when the file is closed, whereas on UNIX,
3798 a files access time is updated as soon as it is read. For Visual C++
3799 to work correctly on a Samba share with oplocks, it is desirable to
3800 set this parameter to 'yes'. This parameter also causes Samba to
3801 swap the Date and Time information in two of the trans2 SMB calls,
3802 as a Windows 95 server does. Other bug-for-bug compatible fixes
3803 will also be turned on by setting this flag as the need arises
3804 to be bug compatible with a Windows 95 server.
3805
3806 .B Default:
3807         win95 bug compatibility = no
3808
3809 .B Example:
3810         win95 bug compatibility = yes
3811
3812 .SS wins proxy (G)
3813
3814 This is a boolean that controls if nmbd will respond to broadcast name
3815 queries on behalf of other hosts. You may need to set this to no for
3816 some older clients.
3817
3818 .B Default:
3819         wins proxy = no
3820 .SS wins server (G)
3821
3822 This specifies the DNS name (or IP address) of the WINS server that Samba 
3823 should register with. If you have a WINS server on your network then you
3824 should set this to the WINS servers name.
3825
3826 You should point this at your WINS server if you have a multi-subnetted
3827 network.
3828 .B Default:
3829         wins server = 
3830
3831 .SS wins support (G)
3832
3833 This boolean controls if the nmbd process in Samba will act as a WINS server. 
3834 You should not set this to true unless you have a multi-subnetted network and
3835 you wish a particular nmbd to be your WINS server. Note that you
3836 should *NEVER* set this to true on more than one machine in your
3837 network.
3838
3839 .B Default:
3840         wins support = no
3841
3842 .SS workgroup (G)
3843
3844 This controls what workgroup your server will appear to be in when
3845 queried by clients. 
3846
3847 .B Default:
3848         set in the Makefile
3849
3850 .B Example:
3851         workgroup = MYGROUP
3852
3853 .SS writable (S)
3854 A synonym for this parameter is 'write ok'. An inverted synonym is 'read only'.
3855
3856 If this parameter is 'no', then users of a service may not create or modify
3857 files in the service's directory.
3858
3859 Note that a printable service ('printable = yes') will ALWAYS allow 
3860 writing to the directory (user privileges permitting), but only via
3861 spooling operations.
3862
3863 .B Default:
3864         writable = no
3865
3866 .B Examples:
3867         read only = no
3868         writable = yes
3869         write ok = yes
3870 .SS write list (S)
3871 This is a list of users that are given read-write access to a
3872 service. If the connecting user is in this list then they will be
3873 given write access, no matter what the "read only" option is set
3874 to. The list can include group names using the @group syntax.
3875
3876 Note that if a user is in both the read list and the write list then
3877 they will be given write access.
3878
3879 See also the "read list" option
3880
3881 .B Default:
3882      write list =
3883
3884 .B Example:
3885      write list = admin, root, @staff
3886
3887 .SS write ok (S)
3888 See
3889 .B writable
3890 and
3891 .B read only.
3892 .SS write raw (G)
3893 This parameter controls whether or not the server will support raw writes when
3894 transferring data from clients.
3895
3896 .B Default:
3897         write raw = yes
3898
3899 .B Example:
3900         write raw = no
3901 .SH NOTE ABOUT USERNAME/PASSWORD VALIDATION
3902 There are a number of ways in which a user can connect to a
3903 service. The server follows the following steps in determining if it
3904 will allow a connection to a specified service. If all the steps fail
3905 then the connection request is rejected. If one of the steps pass then
3906 the following steps are not checked.
3907
3908 If the service is marked "guest only = yes" then steps 1 to 5 are skipped
3909
3910 Step 1: If the client has passed a username/password pair and that
3911 username/password pair is validated by the UNIX system's password
3912 programs then the connection is made as that username. Note that this
3913 includes the \e\eserver\eservice%username method of passing a username.
3914
3915 Step 2: If the client has previously registered a username with the
3916 system and now supplies a correct password for that username then the
3917 connection is allowed.
3918
3919 Step 3: The client's netbios name and any previously used user names
3920 are checked against the supplied password, if they match then the
3921 connection is allowed as the corresponding user.
3922
3923 Step 4: If the client has previously validated a username/password
3924 pair with the server and the client has passed the validation token
3925 then that username is used. This step is skipped if "revalidate = yes" 
3926 for this service.
3927
3928 Step 5: If a "user = " field is given in the smb.conf file for the
3929 service and the client has supplied a password, and that password
3930 matches (according to the UNIX system's password checking) with one of
3931 the usernames from the user= field then the connection is made as the
3932 username in the "user=" line. If one of the username in the user= list
3933 begins with a @ then that name expands to a list of names in the group
3934 of the same name.
3935
3936 Step 6: If the service is a guest service then a connection is made as
3937 the username given in the "guest account =" for the service,
3938 irrespective of the supplied password.
3939 .SH WARNINGS
3940 Although the configuration file permits service names to contain spaces, 
3941 your client software may not. Spaces will be ignored in comparisons anyway,
3942 so it shouldn't be a problem - but be aware of the possibility.
3943
3944 On a similar note, many clients - especially DOS clients - limit service
3945 names to eight characters. Smbd has no such limitation, but attempts
3946 to connect from such clients will fail if they truncate the service names.
3947 For this reason you should probably keep your service names down to eight 
3948 characters in length.
3949
3950 Use of the [homes] and [printers] special sections make life for an 
3951 administrator easy, but the various combinations of default attributes can be
3952 tricky. Take extreme care when designing these sections. In particular,
3953 ensure that the permissions on spool directories are correct.
3954 .SH VERSION
3955 This man page is (mostly) correct for version 1.9.18 of the Samba suite, plus some
3956 of the recent patches to it. These notes will necessarily lag behind 
3957 development of the software, so it is possible that your version of 
3958 the server has extensions or parameter semantics that differ from or are not 
3959 covered by this man page. Please notify these to the address below for 
3960 rectification.
3961
3962 Prior to version 1.5.21 of the Samba suite, the configuration file was
3963 radically different (more primitive). If you are using a version earlier than
3964 1.8.05, it is STRONGLY recommended that you upgrade.
3965 .SH OPTIONS
3966 Not applicable.
3967 .SH FILES
3968 Not applicable.
3969 .SH ENVIRONMENT VARIABLES
3970 Not applicable.
3971 .SH SEE ALSO
3972 .BR smbd (8),
3973 .BR smbclient (1),
3974 .BR nmbd (8),
3975 .BR testparm (1), 
3976 .BR testprns (1),
3977 .BR lpq (1),
3978 .BR hosts_access (5)
3979 .SH DIAGNOSTICS
3980 [This section under construction]
3981
3982 Most diagnostics issued by the server are logged in a specified log file. The
3983 log file name is specified at compile time, but may be overridden on the
3984 smbd command line (see
3985 .BR smbd (8)).
3986
3987 The number and nature of diagnostics available depends on the debug level used
3988 by the server. If you have problems, set the debug level to 3 and peruse the
3989 log files.
3990
3991 Most messages are reasonably self-explanatory. Unfortunately, at time of
3992 creation of this man page the source code is still too fluid to warrant
3993 describing each and every diagnostic. At this stage your best bet is still
3994 to grep the source code and inspect the conditions that gave rise to the 
3995 diagnostics you are seeing.
3996 .SH BUGS
3997 None known.
3998
3999 Please send bug reports, comments and so on to:
4000
4001 .RS 3
4002 .B samba-bugs@samba.anu.edu.au (Andrew Tridgell)
4003
4004 .RS 3
4005 or to the mailing list:
4006 .RE
4007
4008 .B samba@listproc.anu.edu.au
4009
4010 .RE
4011 You may also like to subscribe to the announcement channel:
4012
4013 .RS 3
4014 .B samba-announce@listproc.anu.edu.au
4015 .RE
4016
4017 To subscribe to these lists send a message to
4018 listproc@listproc.anu.edu.au with a body of "subscribe samba Your
4019 Name" or "subscribe samba-announce Your Name".
4020
4021 Errors or suggestions for improvements to the Samba man pages should be 
4022 mailed to:
4023
4024 .RS 3
4025 .B samba-bugs@samba.anu.edu.au (Andrew Tridgell)
4026 .RE
4027