我有一个glusterfs卷。 我可以写文件就好了,但是当我试图创build一个pipe道,它给了我权限被拒绝。
[2017-09-30 15:57:57.148455] E [MSGID: 114031] [client-rpc-fops.c:237:client3_3_mknod_cbk] 0-data-client-2: remote operation failed. Path: /gitlab/data/test/test.socket [Permission denied] [2017-09-30 15:57:57.148712] W [fuse-bridge.c:471:fuse_entry_cbk] 0-glusterfs-fuse: 354460: MKNOD() /gitlab/data/test/test.socket => -1 (Permission denied)
/ etc / fstab中:
gluster01:/data /srv/gfs_data glusterfs rw,allow_other,default_permissions,_netdev 0 0
编辑:
所以在禁用并查看两个砖块的selinux日志之后,它正在阻止它。 应该在什么情况下添加?
SELinux日志
type=AVC msg=audit(1506943186.948:4039): avc: denied { create } for pid=11312 comm="glusteriotwr1" name="test" scontext=system_u:system_r:glusterd_t:s0 tcontext=system_u:object_r:svirt_sandbox_file_t:s0 tclass=fifo_file type=SYSCALL msg=audit(1506943186.948:4039): arch=c000003e syscall=133 success=no exit=-13 a0=7ff275a6c520 a1=11a4 a2=0 a3=2 items=0 ppid=1 pid=11312 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="glusteriotwr1" exe="/usr/sbin/glusterfsd" subj=system_u:system_r:glusterd_t:s0 key=(null)
解决了:
chcon -Rt glusterd_brick_t / bricks / brick1