`
bluerose
  • 浏览: 145987 次
  • 性别: Icon_minigender_1
  • 来自: 成都
社区版块
存档分类
最新评论

centos安装 samba

阅读更多

在linux服务器版本下编程很麻烦。还是使用samba吧。
使用 yum install samba 更新最新的 samba 包

轻松访问安装了Samba的UNIX/LINUX服务器。
1.安装centos时在防火墙中开启文档共享服务,并选择安装文档共享服务器
2.启动 Samba 服务。

# chkconfig smb on  ← 配置 Samba 自启动
# service smb start    ← 启动Samba服务
Starting SMB services:       [ OK ]
Starting NMB services:       [ OK ]
# smbpasswd -a root  ← 将系统用户 root 加入到 Samba 用户数据库
New SMB password:  ← 输入该用户用于登录 Samba 的密码
Retype new SMB password:  ← 再次确认输入该密码
Added user centospub.
 


3.配置Samba
通过编辑 /etc/samba/smb.conf 让将要被共享的目录拥有充分的读写权限属性。
在smb.conf文档最后加入下面内容

[all file]   
comment = centos all file
path = /
valid users = root
public = no
writable = yes
printable = no
create mask = 0777
directory mask = 0777


 还有需要设置workgroup为当前局域网内一样。

这样在window里的网上邻居 就可以访问到centos下的所有文件了。

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics