码迷,mamicode.com
首页 > 其他好文 > 详细

Centos7 samba配置

时间:2019-12-09 14:15:15      阅读:94      评论:0      收藏:0      [点我收藏+]

标签:安装   option   就是   comm   ack   sea   ali   path   user   

Samba配置了很多次,总是忘,现在写在博客里。

最主要的是免密配置,主要用到了两个配置,要写在[global]里:

        map to guest = Bad User
        guest ok = yes

结果安装完了之后,文件夹被识别成了打印机,那是因为错配了一个参数。
就是在配置public的时候复制时多了一个printable = Yes

    printable = Yes

所有配置:

# 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

Centos7 samba配置

标签:安装   option   就是   comm   ack   sea   ali   path   user   

原文地址:https://www.cnblogs.com/bugutian/p/12010209.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!