Linux samba 创建共享盘

1.安装samba
sudo apt-get install samba

2.在/home下创建文件夹用以共享
home$ sudo mkdir share
home$ sudo chmod 777 share

3. /etc/samba/smb.conf 编辑smb.conf 文件
[Share]
comment = Shared Folder
path = /home/share
public = yes
writeable = yes
#valid users = friend
create mask = 0700
directory mask = 0700
#force user = nobody
#force group = nogroup
available = yes
browseable = yes
security = user
map to guest = bad user

4.再搜索[global]
在workgroup = workgroup下面增加如下:
display charset = UTF-8
unix charset = UTF-8
dos charset = cp936

5.增加friend账户
sudo useradd friend

为friend设置smb密码
sudo smbpasswd -a friend

6.重启smbd
sudo service smbd restart

上一篇:C++友元函数和友元类(C++ friend关键字)


下一篇:庖丁解InnoDB之REDO LOG