samba是LINUX為了要與WINDOWS可以再NETWORK(網路的芳鄰)共享檔案的服務
參考了鳥哥的文章
先確定
- samba
- samba-common
- samba-client
三個套件都已經裝了
之後因為我是剛裝完就先裝SAMBA
所以原本應該先設定的/etc/sysconfig/i18n就現在一起設定:
1 2 3 4 | LANG="zh_TW.UTF-8" SUPPORTED="zh_HK.UTF-8:zh_HK zh_SG:zh:zh_TW.UTF-8:zh_TW:z SYSFONT="latarcyrheb-sun16" |
再來是主要的設定檔/etc/samba/smb.conf:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | [global] workgroup = workgroup netbios name = justC5 server string = Just samba server unix charset = utf8 display charset = utf8 dos charset = cp950 log file = /var/log/samba/%m.log max log size = 50 socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192 dns proxy = no template shell = /bin/false winbind use default domain = no security = user encrypt passwords = yes smb passwd file = /etc/samba/smbpasswd name resolve order = lmhosts bcast host [homes] comment = Home directories browseable = no writeable = yes valid users = %S create mask = 0664 directory mask = 0775 [share] comment = the user groups work directory path = /share guest ok = yes writeable = yes [temp] comment = Temporary file space path = /tmp writeable = yes guest ok = yes |