不验证访问samba
[root@xxzx ~]# service iptables stop#关闭防火墙 [root@xxzx ~]# vi /etc/selinux/config#关闭selinux安全 SELINUX=disabled [root@xxzx ~]# setenforce 0 [root@xxzx ~]# yum -y install samba samba-client samba-swat#安装samba相关软件 [root@xxzx ~]# vi /etc/samba/smb.conf # ----------------------- Network Related Options ------------------------- workgroup = MYGROUP#更改群组名称 #============================ Share Definitions ============================== [public] comment = Public Stuff path = /share#共享路径 public = yes [root@xxzx /]# mkdir /share [root@xxzx /]# cd share/ [root@xxzx share]# touch samba.txt [root@xxzx share]# touch aa.txt [root@xxzx /]# chown -R nobody:nobody share/ [root@xxzx /]# service smb restart
2.单群组
[root@xxzx ~]# groupadd ts [root@xxzx ~]# useradd -g ts test1 [root@xxzx ~]# useradd -g ts test2 [root@xxzx ~]# passwd test1 [root@xxzx ~]# passwd test2 [root@xxzx ~]# mkdir /ts [root@xxzx ~]# touch /ts/ceshi.txt [root@xxzx ~]# yum install samba samba-client samba-swat [root@xxzx ~]# smbpasswd test1 [root@xxzx ~]# smbpasswd test2 [root@xxzx ~]# vi /etc/samba/smb.conf # ----------------------- Network Related Options ------------------------- workgroup = MYGROUP#更改群组名称 #============================ Share Definitions ============================== [public] comment = Public Stuff path = /share#共享路径 public = yes [ts] comment = TS path = /ts valid users = @ts [root@xxzx ~]# service smb restart
原文地址:http://keefe.blog.51cto.com/9548710/1691986