LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 2076|回复: 8

Windows无法访问Share模式的Samba

[复制链接]
发表于 2008-12-24 09:56:30 | 显示全部楼层 |阅读模式
[root@studio01 ~]# cat /etc/samba/smb.conf
[global]
        workgroup = seakingmovies
        server string = linux share

        netbios name = redhat01

;       interfaces = lo eth0 192.168.12.2/24 192.168.13.2/24
;       hosts allow = 127. 192.168.12. 192.168.13.
        log file = /var/log/samba/%m.log
        max log size = 50

        security = share
        passdb backend = tdbsam

;       load printers = yes
;       cups options = raw
;       encrypt passwords = yes
;       guest ok = yes
;       guest account = root

;       printcap name = /etc/printcap
;       printcap name = lpstat
;       printing = cups

[share]
        path = /root/share
        writeable = yes
        browseable = yes
        guest ok = yes

能够看到共享的文件夹share,点击时直接提示没有权限访问
发表于 2008-12-24 18:35:58 | 显示全部楼层
smbpasswd -a 增加用户
回复 支持 反对

使用道具 举报

发表于 2008-12-25 13:20:25 | 显示全部楼层
[share]
path = /root/share

换个目录,这里不安全,估计是不能访问的。
回复 支持 反对

使用道具 举报

发表于 2008-12-26 14:59:40 | 显示全部楼层
selinux 防火墙 设置了没?
回复 支持 反对

使用道具 举报

发表于 2008-12-30 21:21:35 | 显示全部楼层
估计就是/root/share目录的权限
回复 支持 反对

使用道具 举报

发表于 2009-1-3 20:00:21 | 显示全部楼层
你要建一个用户 再设置一个smbpasswd 把你要共享的文件CP到这个用户的文件夹里面就可以了
设置密码后在windows里面点击你所建立的用户文件夹输入密码就可以了~!
回复 支持 反对

使用道具 举报

发表于 2009-1-3 23:12:28 | 显示全部楼层
#chkconfig smb on
#setsebool -P samba_enable_home_dirs on      
#iptables -A INPUT -p tcp -m state --state NEW --dport 445 -j ACCEPT
#service smb start
#vi /etc/samba/smb.conf
security = user
#groupadd -g 10000 share
#useradd -G share -s /sbin/nologin joe  
#smbpasswd -a joe
#mkdir /home/share
#chgrp share /home/share
#chmod 3770 /home/share
#vi /etc/samba/smb.conf
[share]
comment = share files
path = /home/share
browseable = yes
write list = @share
create mask = 0660
host allow = 192.168.1
#service smb restart
回复 支持 反对

使用道具 举报

发表于 2009-1-10 10:50:14 | 显示全部楼层
我的防火墙都关了,有本地用户,是share模式的,用testparm和smbclient测试的时候能够看到samba的共享服务器,在win 中就看不到,请教中。
回复 支持 反对

使用道具 举报

发表于 2009-1-10 19:30:20 | 显示全部楼层
windows 中有没有开启NETBIOS
SELINUX 设置 semanage fcontext -t samba_share_t 共享目录
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表