Chinaunix首页 | 论坛 | 博客
  • 博客访问: 689851
  • 博文数量: 26
  • 博客积分: 10
  • 博客等级: 民兵
  • 技术积分: 3182
  • 用 户 组: 普通用户
  • 注册时间: 2011-02-23 14:29
个人简介

7年游戏服务器开发,擅长c/c++,javesript,php;熟悉linux,mysql/redis,elasticsearch;开源爱好者.github : https://github.com/yuyunliuhen

文章分类

全部博文(26)

文章存档

2016年(1)

2015年(3)

2014年(3)

2013年(19)

分类: LINUX

2013-11-09 16:46:48

前提:
    关掉防火墙
    service iptables stop 

    或

    chkconfig iptables off (永久关闭防火墙)

    关闭SELinux

    setenforce 0   

    或

    vi /etc/sysconfig/selinux
    把 SELINUX=enforcing 修改为SELINUX= disabled 

    退出保存,并且重启

     

一    安装
    [root@bogon lee]# yum install samba smbfs smbclient

二    创建目录
    [lee@bogon ~]$ mkdir share
    [lee@bogon ~]$ chmod 777 /home/lee/share/

三    修改samba配置文件
    [root@bogon lee]# cp /etc/samba/smb.conf smb_backup.conf
    [root@bogon lee]# vi /etc/samba/smb.conf                 
    将下面部分加入到smb.conf 末尾
        [share]
 path = /share
 available = yes
 browseable = yes
 public = yes
 writable = yes


四    创建samba账户
    [root@bogon lee]# touch /etc/samba/smbpasswd
    [root@bogon lee]# smbpasswd -a lee


如果还不能访问,尝试修改/etc/samba/smb.conf
# ----------------------- Standalone Server Options ------------------------
#
# Scurity can be set to user, share(deprecated) or server(deprecated)
#
# Backend to store user information in. New installations should
# use either tdbsam or ldapsam. smbpasswd is available for backwards
# compatibility. tdbsam requires no further configuration.

         security = user
==>  security = share

其他细节参考:
http://www.cnblogs.com/mchina/archive/2012/12/18/2816717.html
smb.7z
阅读(5270) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~