为什么 storage_share 无法访问我的 samba 共享?(ubuntu 服务器 11.04)

为什么 storage_share 无法访问我的 samba 共享?(ubuntu 服务器 11.04)

标题说明了一切。我不明白为什么用户无法访问共享。我的其他用户可以访问,但他是所有者。我将在下面发布 Samba 日志和配置。

smb.conf 共享(这是我尝试访问的共享“公共”):

# /media/Storage/Public Share
[Vector_Public]
   comment = Vector pulic share
   read only = no
   path = /media/Storage/Public
   guest ok = no
;   force user = server
   force group = storage_public
   create mask = 0770
   directory mask = 0770
   security mask = 0770
   force create mode = 0770
   force directory mode = 0770
   valid users = server storage_share
   browseable = yes
   writeable = yes
   vfs objects = recycle
   recycle:repository = .deleted/%U
   recycle:keeptree = yes
   recycle:touch = yes
   recycle:versions = yes
   recycle:maxsize = 0


[Vector_Private]
   comment = Vector private share (Niklas)
   read only = no
   path = /media/Storage/Private
   guest ok = no
   force user = server
   force group = server
   create mask = 0770
   directory mask = 0770
   security mask = 0770
   force create mode = 0770
   force directory mode = 0770
   valid users = server
   browseable = yes
   writeable = yes
   vfs objects = recycle
   recycle:repository = .deleted/%U
   recycle:keeptree = yes
   recycle:touch = yes
   recycle:versions = yes
   recycle:maxsize = 0

尝试连接的日志已发布这里。我将日志级别设置为 3,因此它很长 :)

目录权限:

drwxrwx--- 5 server storage_public 4096 2011-10-05 20:28 Public

谢谢大家的想法和建议!:)

答案1

链接日志的第 4 行是

    check_ntlm_password:  mapped user is: [VECTOR]\[niklas]@[NIKLAS-LAPTOP]

这意味着你尝试以用户“niklas”的身份访问,但共享定义使用

    valid users = server storage_share

这意味着:只有用户“server”和用户“storage_share”才有权访问此共享。如果您尝试访问这些共享的用户组,那么您应该写

    valid users = @server @storage_share

它将接受“servers”和“storage_share”组中的所有用户进行此共享。

答案2

chmod -R a+x /media然后再试一次。

答案3

问题出在权限流上。尝试访问共享的用户对包含共享的父文件夹没有读取权限,这以某种方式阻止了他的访问。更改后,现在一切都正常了。

相关内容