新手菜鸟建的samba服务器配置文件

发布于 2022-10-15 09:04:20 字数 7782 浏览 41 评论 0

[global]

# ----------------------- Network Related Options -------------------------

#
        workgroup = WORKGROUP
        server string = Samba Server Version %v
;       netbios name = MYSERVER

;       interfaces = eth0
       hosts allow = 192.168.0.
;       dos charset = GB2312
;       unix charset = GB2312
;       display charset = GB2312
;       directory mask = 0777
;       force directory mode = 0777
;       directory security mask = 0777
;       force directory security mode = 0777
;       create mask = 0777 
;       force create mode = 0777
;       security mask = 0777
;       force security mode = 0777

# --------------------------- Logging Options -----------------------------

        # logs split per machine
;       log file = /var/log/samba/%m.log
        # max 50KB per log file, then rotate
;       max log size = 100

# ----------------------- Standalone Server Options ------------------------
;       security = share
;       passdb backend = tdbsam

# ----------------------- Domain Members Options ------------------------
#
# Security must be set to domain or ads
#
# Use the realm option only with security = ads
# Specifies the Active Directory realm the host is part of
#
# Backend to store user information in. New installations should
# use either tdbsam or ldapsam. smbpasswd is available for backwards
# compatibility. tdbsam requires no further configuration.
#
# Use password server option only with security = server or if you can't
# use the DNS to locate Domain Controllers
# The argument list may include:
#   password server = My_PDC_Name [My_BDC_Name] [My_Next_BDC_Name]
# or to auto-locate the domain controller/s
#   password server = *

;       security = domain
;       passdb backend = tdbsam
;       realm = MY_REALM

;       password server = <NT-Server-Name>

# ----------------------- Domain Controller Options ------------------------
#
;       security = share
;       passdb backend = tdbsam

;       domain master = yes
;       domain logons = yes

        # the login script name depends on the machine name
;       logon script = %m.bat
        # the login script name depends on the unix user used
;       logon script = %u.bat
;       logon path = \\%L\Profiles\%u
        # disables profiles support by specifing an empty path
;       logon path =

;       add user script = /usr/sbin/useradd "%u" -n -g users
;       add group script = /usr/sbin/groupadd "%g"
;       add machine script = /usr/sbin/useradd -n -c "Workstation (%u)" -M -d /nohome -s /bin/false "%u"
;       delete user script = /usr/sbin/userdel "%u"
;       delete user from group script = /usr/sbin/userdel "%u" "%g"
;       delete group script = /usr/sbin/groupdel "%g"

# ----------------------- Browser Control Options ----------------------------
;       local master = no
;       os level = 33
;       preferred master = yes

#----------------------------- Name Resolution -------------------------------
;       wins support = yes
;       wins server = w.x.y.z
;       wins proxy = yes

;       dns proxy = yes

# --------------------------- Printing Options -----------------------------
        load printers = yes
        cups options = raw

;       printcap name = /etc/printcap
;       printcap name = lpstat
;       printing = cups

# --------------------------- Filesystem Options ---------------------------
;       map archive = no
;       map hidden = no
;       map read only = no
;       map system = no
;       store dos attributes = yes

#============================ Share Definitions ==============================

[homes]
        comment = Home Directories
        browseable = yes
        writable = yes
;       valid users = %S
;       valid users = admin,root

[printers]
        comment = All Printers
        path = /var/spool/samba
        browseable = yes
        guest ok = yes
        writable = yes
        printable = yes

# Un-comment the following and create the netlogon directory for Domain Logons
;       [netlogon]
;       comment = Network Logon Service
;       path = /var/lib/samba/netlogon
;       guest ok = yes
;       writable = yes
;       share modes = yes

# Un-comment the following to provide a specific roving profile share
# the default is to use the user's home directory
;       [Profiles]
;       path = /var/lib/samba/profiles
;       browseable = yes
;       guest ok = yes

# A publicly accessible directory, but read only, except for people in
# the "staff" group
;       [public]
        comment = Public Stuff
;       path = /home/1bu,2bu,zbu
;       public = yes
;       writable = yes
;       printable = yes
;       write list = +staff
;       guest ok = yes

请大家给予指点   虽然可以用   但是我是菜鸟  想知道有什么可以改进的没

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(6

智商已欠费 2022-10-22 09:04:20

回复 1# a9632234

    你这简单   0777  

     在内网里  没别的要求 随便怎么配置 能用就行

花桑 2022-10-22 09:04:20

服务起来了没有?

玉环 2022-10-22 09:04:20

可以用了!给大家看看有什么能改进的没

抠脚大汉 2022-10-22 09:04:20

回复 4# a9632234

    改进就是安全方面的改进   

\   身份验证和权限设置

    根据实际需要来做变动

病女 2022-10-22 09:04:20

看需求,如果只是简单的共享,现在就ok了

叫嚣ゝ 2022-10-22 09:04:20

学习了!赣榆招聘http://job.ganyu.com

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文