| may97.tar |
Listing 1: Samba configuration template
; SAMBA on $servername ; ***************************** ; SAMBA Config Template ; Mark Nassal 1997 ; ; For more information on setting ; see the smb.conf man page. You ; can view the page by changing ; to the samba/bin dir and ; entering nroff -man ; smb.conf.5 | more. ; ; You should also view the ; document BROWSING.txt. ; ***************************** ; Use your editor to search for $ (user config) ; *************** ; Global Settings ; *************** [global] ; Location and name of the SAMBA configuration file ; the path for your smb.conf file config file = /usr/local/samba/lib/smb.conf ; Server Connection String ( change $servername to the name of ; your server ; %v will display the SAMBA version) server string = $servername (%v, %h) ; Set the SAMBA password server, if you are using NIS point to ; the NIS server. Un-comment the line bellow and replace ; $servername with the password server name ;password server = $servername ; LanManager browser level ; If you want your server to be a master browser un-comment line ; and set the value of $xx to a number above 33. ; os level = $xx ; Security type is normally set to share security = share ; If you are connecting with NT make sure encryption is yes encrypt passwords = yes ; Change $workgroup to the workgroup you want the server to ; belong to. workgroup = $workgroupname ; To monitor connections set status to yes status = yes ; Adjust debug to the level you want logged debug level = 2 ; Log level should be left at 2 unless trouble shooting, because ; it will decrease performance. log level = 2 ; Change LOGPATH to the path for SAMBA log files (be sure to ; create the samba directory ) log file = /usr/local/samba/log.%m ; For guest login account. Most servers already have a user ; nobody that will work. guest account = $guestacct ; List either allowed hosts, networks or ; subnets (175.60.50.4 200.100.) hosts allow = $xxx.xxx. ; List dis-allowed hosts ;hosts deny = $xxx.xxx.xxx.xxx ; Password level, see BROWSING.txt and WinNT.txt before changing password level = 9 ; To increase performance leave this entry as is socket options = TCP_NODELAY ; Change LOCKS to the path and directory you want lock files to ; be written to (directory and files should be set to 666) lock directory = /var/tmp/samba ; Enable file sharing and locking share modes = yes ; To check each file transaction for locking strict locking = yes ; To prevent drops on large networks keep alive = 30 ; To hide dot files un-comment ; hide dot files = no ; if you want to load printers leave as yes load printers = yes ; **************** ; Printer Settings ; **************** ; load printer info from the printcap file ;[printers] ; browseable = no ; comment = printers in printcap ; guest ok = yes ; path = /usr/spool/public ; read only = no ; print ok = yes ; public = yes ; Share one of the printers ;[$printername] ; Create this spool directory path = /usr/spool/public read only = no print ok = yes public = yes printable = yes ; Set the path for lpr on your system, with one works with Sparc ; and SunOs print command = /usr/ucb/lpr -P %p %s; rm %s ; ****************** ; Shared Directories ; ****************** ; Simple copy and past the share types. Then make needed changes ; to the options. ; Setup a CDROM drive share ;[cdrom] ; comment = CDROM 1 ; path = /cdrom ; ; set for read only files ; read only = yes ; ; locking is not needed since it is read only ; locking = no ; ; get rid of the ";1" from some UNIX CDROM file listings ; mangled map = (*;1 *) ; ; if you want to truncate long file names un-comment ; ;mangled names = yes ; Share home directories ;[homes] ; comment = Home Directories ; ; prevent others from scanning dir ; browseable = no ; ; only those with permission can see the files ; guest ok = no ; read only = no ; ; What file mod should files we marked ; create mode = 0755 ; ; if you want to truncate long file names un-comment ; ;mangled names = yes ;;Public Share (no password, user becomes the guest user) ;[public] ; comment = Public ; ;Path to DIR ; path = /export/public ; ;Allow other users to scan the directory ; browseable = yes ; public = yes ; ;Allow guest users (no password) ; guest ok = yes ; ;Users can Read and Write ; read only = no ; locking = yes ; ;UNIX File mod ; create mode = 0666 ; ; if you want to truncate long file names un-comment ; ;mangled names = yes ;Create a Group Share (all can view, but only those in a group can write) ;[group] ; comment = My Groups Directory ; ;Path for the Share ; path = /home/samba ; ;Make it Available to everyone ; public = yes ; ;Writable by Group Members ; writable = yes ; ;Require a password ; guest ok = no ; locking = yes ; printable = no ; ;Group which has Write Privileges ; write list = $users ; ; if you want to truncate long file names un-comment ; ;mangled names = yes ;General Share (let UNIX determine privs) ;[general] ; comment = General Purpose Share ; ;Set path ; path = /opt/local ; ;Allow users to view files according to UNIX privileges ; browseable = yes ; public = no ; ;Require a Password ; guest ok = no ; ;Allow users with Privs to Write ; read only = no ; locking = yes ; create mode = 0755 ; ; if you want to truncate long file names un-comment ; ;mangled names = yes ; ******************** ; End Config File ; ********************
|