Bug 1634220 - md-cache: some problems of cache virtual glusterfs ACLs for ganesha
Summary: md-cache: some problems of cache virtual glusterfs ACLs for ganesha
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: md-cache
Version: mainline
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
Assignee: bugs@gluster.org
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-09-29 03:24 UTC by Kinglong Mee
Modified: 2019-03-25 16:31 UTC (History)
2 users (show)

Fixed In Version: glusterfs-6.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-03-25 16:31:10 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Gluster.org Gerrit 21410 0 None Open md-cache: remove xattr setting after new file created 2018-11-06 10:17:48 UTC
Gluster.org Gerrit 21411 0 None Open md-cache: removexattr must be send to glusterfsd 2018-11-02 06:26:10 UTC
Gluster.org Gerrit 21412 0 None Open md-cache: extends xa_time when previous attributes equals cached attributes 2018-11-06 10:18:27 UTC
Gluster.org Gerrit 21414 0 None Open md-cache: request ACLs related xattrs when mode change 2018-11-12 04:07:32 UTC
Gluster.org Gerrit 21415 0 None Open md-cache: request cached xattrs at getxattr/fgetxattr 2018-11-06 10:18:50 UTC
Gluster.org Gerrit 21418 0 None Open md-cache: new option \"cache-glusterfs-acl\" for virtual glusterfs ACLs 2018-11-06 10:19:14 UTC

Description Kinglong Mee 2018-09-29 03:24:28 UTC
Description of problem:


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Kinglong Mee 2018-10-10 03:51:03 UTC
Md-cache has option "cache-posix-acl" that controls caching of posix ACLs ("system.posix_acl_access"/"system.posix_acl_default") and virtual glusterfs ACLs ("glusterfs.posix.acl"/"glusterfs.posix.default_acl") now.

But, _posix_xattr_get_set does not fill virtual glusterfs ACLs when lookup requests.
So, md-cache caches bad virtual glusterfs ACLs.

After I turn on "cache-posix-acl" option to cache ACLs at md-cache, nfs client gets many EIO errors.

https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/427305

There are two chooses for cache virtual glusterfs ACLs in md-cache,
1. Cache it separately as posix ACLs (a new option maybe "cache-glusterfs-acl" is added);
   And make sure _posix_xattr_get_set fills them when lookup requests.

2. Does not cache it, only cache posix ACLs;
   If gfapi request it, md-cache lookup according posix ACL at cache,
   if exist, make the virtual glusterfs ACL locally and return to gfapi;
   otherwise, send the request to glusterfsd.

Virtual glusterfs ACLs are another format of posix ACLs, there are larger than posix ACLs, 
and always exist no matter the really posix ACL exist or not.

So, I'd prefer #2.

Comment 2 Worker Ant 2018-10-15 11:29:24 UTC
REVIEW: https://review.gluster.org/21410 (md-cache: remove xattr setting after new file created) posted (#2) for review on master by Kinglong Mee

Comment 3 Worker Ant 2018-10-15 11:30:55 UTC
REVIEW: https://review.gluster.org/21412 (md-cache: extends xa_time when previous attributes equals cached attributes) posted (#2) for review on master by Kinglong Mee

Comment 4 Worker Ant 2018-10-15 11:31:55 UTC
REVIEW: https://review.gluster.org/21411 (md-cache: removexattr must be send to glusterfsd) posted (#2) for review on master by Kinglong Mee

Comment 5 Worker Ant 2018-10-15 11:32:56 UTC
REVIEW: https://review.gluster.org/21413 (md-cache: request cached xattrs at stat/fstat) posted (#2) for review on master by Kinglong Mee

Comment 6 Worker Ant 2018-10-15 11:34:00 UTC
REVIEW: https://review.gluster.org/21414 (md-cache: request GF_POSIX_ACL_* xattrs when mode/uid/gid changing) posted (#2) for review on master by Kinglong Mee

Comment 7 Worker Ant 2018-10-15 11:35:01 UTC
REVIEW: https://review.gluster.org/21415 (md-cache: request cached xattrs at getxattr/fgetxattr) posted (#2) for review on master by Kinglong Mee

Comment 8 Worker Ant 2018-10-15 11:36:02 UTC
REVIEW: https://review.gluster.org/21417 (posix: return more xattrs at getxattr/fgetxattr when client request) posted (#2) for review on master by Kinglong Mee

Comment 9 Worker Ant 2018-10-15 11:37:06 UTC
REVIEW: https://review.gluster.org/21416 (posix: fill glusterfs.posix.* acl xattrs at dict) posted (#2) for review on master by Kinglong Mee

Comment 10 Worker Ant 2018-10-15 11:38:07 UTC
REVIEW: https://review.gluster.org/21418 (md-cache: new option \"cache-glusterfs-acl\" for virtual glusterfs ACLs) posted (#2) for review on master by Kinglong Mee

Comment 11 Worker Ant 2018-10-17 10:21:02 UTC
COMMIT: https://review.gluster.org/21417 committed in master by "Amar Tumballi" <amarts@redhat.com> with a commit message- posix: return more xattrs at getxattr/fgetxattr when client request

Change-Id: I37ac6186b3631979d2503d1b185a61b8094dbd0d
Updates: bz#1634220
Signed-off-by: Kinglong Mee <mijinlong@open-fs.com>

Comment 12 Worker Ant 2018-10-18 12:21:27 UTC
REVIEW: https://review.gluster.org/21449 (md-cache: fix dict leak of cached xattr) posted (#1) for review on master by Kinglong Mee

Comment 13 Worker Ant 2018-10-22 05:52:16 UTC
COMMIT: https://review.gluster.org/21449 committed in master by "Amar Tumballi" <amarts@redhat.com> with a commit message- md-cache: fix dict leak of cached xattr

Change-Id: I52f8e13e68528ba9679537ffdddf58ec08f9fd0c
Updates: bz#1634220
Signed-off-by: Kinglong Mee <mijinlong@open-fs.com>

Comment 14 Worker Ant 2018-10-22 10:25:39 UTC
COMMIT: https://review.gluster.org/21416 committed in master by "Amar Tumballi" <amarts@redhat.com> with a commit message- posix: fill glusterfs.posix.* acl xattrs at dict

Change-Id: I0730a037f96c4386c72ecf2f61c71ec17ffbc1b0
Updates: bz#1634220
Signed-off-by: Kinglong Mee <mijinlong@open-fs.com>

Comment 15 Worker Ant 2018-10-23 07:17:34 UTC
COMMIT: https://review.gluster.org/21413 committed in master by "Poornima G" <pgurusid@redhat.com> with a commit message- md-cache: request cached xattrs at stat/fstat

Ganesha always operate file by filehandle, and translates to
glusterfs's stat/fstat many time.

Change-Id: Idd0dc33c31131331ac948754c8b7f898777c31d3
Updates: bz#1634220
Signed-off-by: Kinglong Mee <mijinlong@open-fs.com>

Comment 16 Worker Ant 2018-11-02 06:26:09 UTC
REVIEW: https://review.gluster.org/21411 (md-cache: removexattr must be send to glusterfsd) posted (#10) for review on master by Amar Tumballi

Comment 17 Worker Ant 2018-11-06 10:17:47 UTC
REVIEW: https://review.gluster.org/21410 (md-cache: remove xattr setting after new file created) posted (#10) for review on master by Raghavendra G

Comment 18 Worker Ant 2018-11-06 10:18:25 UTC
REVIEW: https://review.gluster.org/21412 (md-cache: extends xa_time when previous attributes equals cached attributes) posted (#10) for review on master by Raghavendra G

Comment 19 Worker Ant 2018-11-06 10:18:49 UTC
REVIEW: https://review.gluster.org/21415 (md-cache: request cached xattrs at getxattr/fgetxattr) posted (#11) for review on master by Raghavendra G

Comment 20 Worker Ant 2018-11-06 10:19:13 UTC
REVIEW: https://review.gluster.org/21418 (md-cache: new option \"cache-glusterfs-acl\" for virtual glusterfs ACLs) posted (#10) for review on master by Raghavendra G

Comment 21 Worker Ant 2018-11-12 04:07:31 UTC
REVIEW: https://review.gluster.org/21414 (md-cache: request ACLs related xattrs when mode change) posted (#10) for review on master by Amar Tumballi

Comment 22 Shyamsundar 2019-03-25 16:31:10 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-6.0, please open a new bug report.

glusterfs-6.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] https://lists.gluster.org/pipermail/announce/2019-March/000120.html
[2] https://www.gluster.org/pipermail/gluster-users/


Note You need to log in before you can comment on or make changes to this bug.