天天看點

SMB 配置

1. yum -y install samba samba-common

2. cd /etc/samba

vim smb.conf

# 1). 先設定好伺服器整體環境方面的參數

[global]

# 與主機名有關的設定資訊

workgroup = vbirdhouse

netbios name = vbirdserver

server string = this is vbird's samba server

# 與語系方面有關的設定項目喔,為何如此設定請參考前面的說明

unix charset = utf8

display charset = utf8

dos charset = cp950

# 與登入檔案有關的設定項目,注意變量 (%m)

log file = /var/log/samba/log.%m

max log size = 50

# 這裡才是與密碼有關的設定項目哩!

security = share

# 修改一下列印機的加載方式,不要加載啦!

load printers = no

# 2). 分享的資源設定方面:主要得将舊的批注,新的加入!

# 先取消 [homes], [printers] 的項目,然後針對 /tmp 的設定,可浏覽且可寫入喔

[temp] <==分享資源名稱

comment = temporary file space <==簡單的解釋此資源

path = /tmp <==實際 linux 分享的目錄

writable = yes <==是否可寫入?在此例為是的

browseable = yes <==能不能被浏覽到資源名稱

guest ok = yes <==單純分享時,讓使用者随意登入的設定值

3. service smb start

service nmb start

SMB