我正在开发一个samba共享解决方案,但我遇到了一个问题。 我有一个RHEL服务器,在Solaris 10服务器上安装了NFS共享文件夹;一切都在这一步。 然后,我与samba共享同一个文件夹,以便能够从MS Windows机器获得只读访问权限。
以下是我遇到的问题,我的文件夹中有以下文件:
-rw-r--r--+ 1 root root 0 Jun 13 2012 file1.log
-rw-r--r--+ 1 root root 35856 Jun 13 2012 file2.log
drwxr-xr-x+ 12 nobody grp-app 4096 Jul 8 12:45 folder1
drwxr-xr-x+ 10 root root 4096 Jun 13 2012 folder2
drwx------+ 2 root root 16384 Jun 12 2012 lost+found
但是,一旦连接到Windows服务器上的文件夹\ server-smb \ shared-folder,我只能看到:folder1。
这是我的Samba配置:
[shared-folder]
comment = Shared folder
path = /path/shared-folder
valid users = toto
read only = yes
以下是应用于这些文件的ACL:
-rw-r--r--+ 1 root root 0 Jun 13 2012 file1.log
0:owner@:read_data/write_data/append_data/read_attributes /write_attributes/read_acl/write_acl/synchronize:allow
1:user:unknown:read_data/read_attributes/read_acl/synchronize:allow
2:everyone@:read_data/read_attributes/read_acl/synchronize:allow
-rw-r--r--+ 1 root root 35856 Jun 13 2012 file2.log
0:owner@:read_data/write_data/append_data/read_attributes/write_attributes/read_acl/write_acl/synchronize:allow
1:user:unknown:read_data/read_attributes/read_acl/synchronize:allow
2:everyone@:read_data/read_attributes/read_acl/synchronize:allow
drwxr-xr-x+ 12 nobody grp-app 4096 Jul 8 12:45 folder1
0:owner@:list_directory/read_data/add_file/write_data/add_subdirectory/append_data/execute/delete_child/read_attributes/write_attributes/read_acl/write_acl/synchronize:allow
1:user:unknown:list_directory/read_data/execute/read_attributes/read_acl/synchronize:allow
2:everyone@:list_directory/read_data/execute/read_attributes/read_acl/synchronize:allow
drwxr-xr-x+ 10 root root 4096 Jun 13 2012 folder2
0:owner@:list_directory/read_data/add_file/write_data/add_subdirectory/append_data/execute/delete_child/read_attributes/write_attributes/read_acl/write_acl/synchronize:allow
1:user:unknown:list_directory/read_data/execute/read_attributes/read_acl/synchronize:allow
2:everyone@:list_directory/read_data/execute/read_attributes/read_acl/synchronize:allow
drwx------+ 2 root root 16384 Jun 12 2012 lost+found
0:owner@:list_directory/read_data/add_file/write_data/add_subdirectory/append_data/execute/delete_child/read_attributes/write_attributes/read_acl/write_acl/synchronize:allow
1:user:unknown:read_attributes/read_acl/synchronize:allow
2:everyone@:read_attributes/read_acl/synchronize:allow
您是否了解导致此问题的原因以及解决方法?
谢谢。 最好的问候,
答案 0 :(得分:-1)
错误是由于ACL。
使用NFS v3或v4时,似乎会出现ACL周围的错误。 该问题也出现在最新的Samba版本(4.1.1)中。 即使在导出上设置了“no_acl”并且在mount上设置了“noxattr”,也会出现此问题。
解决方案:在Linux和Solaris之间强制使用NFS v2。