如何在Ubuntu上安装Samba文件共享服务

系统部署
2013-10-26 12:27

安装Samba

sudo apt-fast install samba
sudo apt-fast install smbfs

配置Samba

建立共享文件夹

sudo mkdir /home/<user name>/<share dir>

编辑Samba配置文件

sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup
sudo nano /etc/samba/smb.conf

Ctrl-W 找到

;security = user 

改成

security = user
username map = /etc/samba/smbusers

并在文件末行加入共享目录

[<share dir>]
comment = Shared Folder with username and password
path = /home/<user name>/<share dir>
public = yes
writable = yes
valid users = <username>
create mask = 0777
directory mask = 0777
force user = nobody
force group = nogroup
available = yes
browseable = yes

编辑 /etc/samba/smbusers,加入

<user name> = "network username"

设置密码

sudo smbpasswd -a <user name>

测试、重启

su
加载 Disqus 评论

© 版权所有 悟理 2013-2019
Powered By Jekyll & Semantic UI

如何在Ubuntu上安装Samba文件共享服务

系统部署
2013-10-26 12:27

安装Samba

sudo apt-fast install samba
sudo apt-fast install smbfs

配置Samba

建立共享文件夹

sudo mkdir /home/<user name>/<share dir>

编辑Samba配置文件

sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup
sudo nano /etc/samba/smb.conf

Ctrl-W 找到

;security = user 

改成

security = user
username map = /etc/samba/smbusers

并在文件末行加入共享目录

[<share dir>]
comment = Shared Folder with username and password
path = /home/<user name>/<share dir>
public = yes
writable = yes
valid users = <username>
create mask = 0777
directory mask = 0777
force user = nobody
force group = nogroup
available = yes
browseable = yes

编辑 /etc/samba/smbusers,加入

<user name> = "network username"

设置密码

sudo smbpasswd -a <user name>

测试、重启

su
加载 Disqus 评论

© 版权所有 悟理 2013-2019
Powered By Jekyll & Semantic UI

如何在Ubuntu上安装Samba文件共享服务

系统部署
2013-10-26 12:27

安装Samba

sudo apt-fast install samba
sudo apt-fast install smbfs

配置Samba

建立共享文件夹

sudo mkdir /home/<user name>/<share dir>

编辑Samba配置文件

sudo cp /etc/samba/smb.conf /etc/samba/smb.conf_backup
sudo nano /etc/samba/smb.conf

Ctrl-W 找到

;security = user 

改成

security = user
username map = /etc/samba/smbusers

并在文件末行加入共享目录

[<share dir>]
comment = Shared Folder with username and password
path = /home/<user name>/<share dir>
public = yes
writable = yes
valid users = <username>
create mask = 0777
directory mask = 0777
force user = nobody
force group = nogroup
available = yes
browseable = yes

编辑 /etc/samba/smbusers,加入

<user name> = "network username"

设置密码

sudo smbpasswd -a <user name>

测试、重启

su
加载 Disqus 评论

© 版权所有 悟理 2013-2019
Powered By Jekyll & Semantic UI