ubuntu 9.04 下samba配置实验
原想通过rdeskp实现host和client之间的文件共享,可rdeskp的本地文件挂载实在是不理想,于是打算使用samba来实现文件共享。
一、安装samba
$sudo apt-get install samba二、samba主要的文件是/etc/samba/smb.conf1、 workgroup = EXAMPLE security = user2、在smb.conf最后增加下面一段内容[share] comment = Ubuntu File Server Share path = /srv/samba/share browsable = yes guest ok = yes read only = no create mask = 07553、建立共享目录sudo mkdir -p /srv/samba/sharesudo chown nobody.nogroup /srv/samba/share/4、重新启动sambasudo /etc/init.d/samba restart
现在已经可以通过\\ip\链接到samba上面
继续配置要求用户名密码访问
5、安装系统用户和smb用户同步的工具sudo apt-get install libpam-smbpass6、编辑/etc/samba/smb.conf
Edit /etc/samba/smb.conf, and in [share] section change:
guest ok = no
Finally, restart Samba for the new settings to take effect:
sudo /etc/init.d/samba restartread list = @qa write list = @sysadmin, vincent
Another possible Samba permission is to declare administrative permissions to a particular shared resource. Users having administrative permissions may read, write, or modify any information contained in the resource the user has been given explicit administrative permissions to.
For example, if you wanted to give the user melissa administrative permissions to the share example, you would edit the /etc/samba/smb.conf file, and add the following line under the [share] entry:
admin users = melissa
After editing /etc/samba/smb.conf, restart Samba for the changes to take effect:
sudo /etc/init.d/samba restartwrite list = @sysadmin, vincent
Another possible Samba permission is to declare administrative permissions to a particular shared resource. Users having administrative permissions may read, write, or modify any information contained in the resource the user has been given explicit administrative permissions to.
For example, if you wanted to give the user melissa administrative permissions to the share example, you would edit the /etc/samba/smb.conf file, and add the following line under the [share] entry:
admin users = melissa
After editing /etc/samba/smb.conf, restart Samba for the changes to take effect:
sudo /etc/init.d/samba restart
- 最新评论