配置samba服务

简介:
目得:一直使用Xmanagelinux传文件,今天试用到期没去找注册码就安装一个简单的samba服务给linux传文件,顺便把过程记录了一下,方便以后用时查看.

1.      安装samba

chenxy

2.创建samba用户及设置密码

.创建用户
chenxy
设置密码
chenxy

3.修改smb配置文件

只需简单的去几个”;”号就可以了
修改成如下,或直接用以下配置文件就OK
copy /etc/samba/smb.conf  /etc/samba/smb.conf.bak
vi smb.conf
#添加如下代码,如果修改以前的配置文件,红色的为修改的地方
[global]
       workgroup = MYGROUP
       server string = Samba Server Version %v
       netbios name = MYSERVER
       interfaces = lo eth0 192.168.0.0/24
       hosts allow = 127. 192.168.0. 192.168.13.
       # logs split per machine
       log file = /var/log/samba/%m.log
       # max 50KB per log file, then rotate
       security = user
       passdb backend = tdbsam
       load printers = yes
       cups options = raw
       idmap uid = 16777216-33554431
   idmap gid = 16777216-33554431
   template shell = /bin/false
   winbind use default domain = no
[homes]
       comment = Home Directories
       browseable = no
       writable = yes
[printers]
       comment = All Printers
       path = /var/spool/samba
       browseable = no
       guest ok = no
       writable = no
printable = yes
#,仿照[public]可以发布更多的目录,但一定要注意在目录上给777的权限,
#security = user
#passdb backend = tdbsam
#上面两行设小权限
[public]
    comment = Public Stuff
    path = /home/samba
    public = yes
    writable = yes
    printable = no
    write list = +staff

4.重新启动samba

chenxy
5.客启端登录
开始/运行

chenxy

输入用户名和密码
可以使用了(只有它自己的家目录有读写权)
chenxy




本文转自 vfast_chenxy 51CTO博客,原文链接:http://blog.51cto.com/chenxy/166687 ,如需转载请自行联系原作者

目录
相关文章
|
网络协议 Unix Linux
Samba服务的安装与配置
Samba服务的安装与配置
2513 0
|
安全 开发工具
SAMBA 服务器安装与配置
#!/bin/bash #SAMBA  window co-connect linux #SAMBA  NETBIOS #SAMBA nmbd:137 138  smbd:139 445 #samba samba-client samba-common /etc/samba/smb.
922 0
|
Linux 数据安全/隐私保护
|
数据安全/隐私保护 安全 Linux
|
测试技术 Linux 数据库
|
安全 数据库 数据安全/隐私保护
|
Web App开发 网络协议 安全