Centos7 samba configuration

Samba configuration many times, always forget, and now write in the blog.

The main thing is free dense configuration uses two main configuration, write in [global] where:

        map to guest = Bad User
        guest ok = yes

The results after installation finished, the folder is recognized became a printer, it is because of a mismatch parameters.
That is, when the configuration of the public more time to copy a printable = Yes

    printable = Yes

All configuration:

# See smb.conf.example for a more detailed config file or
# read the smb.conf manpage.
# Run 'testparm' to verify the config is correct after
# you modified it.

[global]
        workgroup = SAMBA
        security = user

        passdb backend = tdbsam

        printing = cups
        printcap name = cups
        load printers = yes
        cups options = raw
        map to guest = Bad User
        guest ok = yes

[homes]
        comment = Home Directories
        valid users = %S, %D%w%S
        browseable = No
        read only = No
        inherit acls = Yes

[printers]
        comment = All Printers
        path = /var/tmp
        printable = Yes
        create mask = 0600
        browseable = No

[print$]
        comment = Printer Drivers
        path = /var/lib/samba/drivers
        write list = @printadmin root
        force group = @printadmin
        create mask = 0664
        directory mask = 0775

[public]
        comment = public
        path = /path/to/yourdir
        create mask = 0664
        directory mask = 0775
        public = yes
        writable = yes
        read only = no

Guess you like

Origin www.cnblogs.com/bugutian/p/12010209.html