Bug 884597
Summary: | dht linkfile are created with different owner:group than that source(data) file in few cases | |||
---|---|---|---|---|
Product: | [Community] GlusterFS | Reporter: | Amar Tumballi <amarts> | |
Component: | distribute | Assignee: | Nagaprasad Sathyanarayana <nsathyan> | |
Status: | CLOSED CURRENTRELEASE | QA Contact: | ||
Severity: | medium | Docs Contact: | ||
Priority: | medium | |||
Version: | mainline | CC: | aavati, gluster-bugs, jdarcy, nock, olim, rwheeler, shmohan, smohan | |
Target Milestone: | --- | |||
Target Release: | --- | |||
Hardware: | Unspecified | |||
OS: | Unspecified | |||
Whiteboard: | ||||
Fixed In Version: | glusterfs-3.3.2 | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | ||
Clone Of: | ||||
: | 902200 1168392 (view as bug list) | Environment: | ||
Last Closed: | 2014-04-17 19:21:33 UTC | Type: | Bug | |
Regression: | --- | Mount Type: | --- | |
Documentation: | --- | CRM: | ||
Verified Versions: | Category: | --- | ||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
Cloudforms Team: | --- | Target Upstream Version: | ||
Embargoed: | ||||
Bug Depends On: | ||||
Bug Blocks: | 895528, 902200, 1168392, 1205785 |
Description
Amar Tumballi
2012-12-06 11:15:25 UTC
http://review.gluster.org/4194 would fix the issue, but one of the review comment was against using xdata for solving this problem. Hence we would need more of 'copy_frame()' for creating the dht linkfile. http://review.gluster.org/#change,4304 patch is under review. CHANGE: http://review.gluster.org/4269 (synctask: implement setuid-like SYNCTASK_SETID()) merged in master by Anand Avati (avati) CHANGE: http://review.gluster.org/#change,4304,patchset=11 has been merged in master CHANGE: http://review.gluster.org/4513 (cluster/distribute: Reopen fds in migration internally as root:root) merged in master by Anand Avati (avati) We had kept the bug open, as a setattr would take the linkfile/src file out of sync w.r.t their permissions (setattr currently happens only on the src (cached file). After investigating, we decided, the fix is not required as 1. A rebalance will fix the uid/gid during migration 2. A migration in progress check in setattr handle linkfile(hashed file) to get the right permissions. 3. All internal fd open (migration related) is done as root:root. Moving the state to MODIFIED, as all required fixes are merged upstream CHANGE: http://review.gluster.org/4607 (cluster/dht: Create linkfile with file uid/gid) merged in release-3.4 by Vijay Bellur (vbellur) CHANGE: http://review.gluster.org/4611 (synctask: implement setuid-like SYNCTASK_SETID()) merged in release-3.4 by Vijay Bellur (vbellur) CHANGE: http://review.gluster.org/4612 (cluster/distribute: Reopen fds in migration internally as root:root) merged in release-3.4 by Vijay Bellur (vbellur) I think this unaddressed 3.3.0 bug may be related: https://bugzilla.redhat.com/show_bug.cgi?id=913699 A backport may be valuable for the community. *** Bug 821139 has been marked as a duplicate of this bug. *** Hi Shawn, The fix has been back-ported to release-3.4, which is in the alpha stage. Currenlty release-3.4.0alpha2 has the fix (http://bits.gluster.org/pub/gluster/glusterfs/3.4.0alpha2/) REVIEW: http://review.gluster.org/4682 (cluster/dht: Linkfiles creation with correct uid/gid) posted (#3) for review on master by Shishir Gowda (sgowda) Moving the status back to POST, fix sent for review (comment 13) REVIEW: http://review.gluster.org/5024 (cluster/dht: Create linkfile with file uid/gid) posted (#1) for review on release-3.3 by Shishir Gowda (sgowda) REVIEW: http://review.gluster.org/5025 (cluster/dht: Linkfiles creation with correct uid/gid) posted (#1) for review on release-3.3 by Shishir Gowda (sgowda) COMMIT: http://review.gluster.org/5024 committed in release-3.3 by Vijay Bellur (vbellur) ------ commit ddc0b45c4d4826e86500740f672892eeb28ab325 Author: shishir gowda <sgowda> Date: Thu May 16 19:25:25 2013 +0530 cluster/dht: Create linkfile with file uid/gid Currently, linkfile creation happens as root. use uid/gid returned from _cbk (link/rename) to set the correct ownership of the link files. Change-Id: I5345cff193d5095442ca446fbe5ea05f2c2d86a3 Signed-off-by: shishir gowda <sgowda> BUG: 884597 Reviewed-on: http://review.gluster.org/5024 Reviewed-by: Vijay Bellur <vbellur> Tested-by: Gluster Build System <jenkins.com> COMMIT: http://review.gluster.org/5025 committed in release-3.3 by Vijay Bellur (vbellur) ------ commit 1a7e6053d3842761f946fbbdd693c72aa3945a97 Author: shishir gowda <sgowda> Date: Thu May 16 19:32:49 2013 +0530 cluster/dht: Linkfiles creation with correct uid/gid If renames are done with different uid/gid (non-owners), then we would end up with incorrect uid/gid. The fix is to create linkfiles, and heal the uid/gid as root:root. This preserves our notion of creation as root:root and heal the uid/gid as root:root in all paths. Additionally, we need to consider uid/gid from only src_cached subvol, and not from linkfiles. rename is also done as root:root if done on linkfile, as setattr of ownership on linkfile is done after the rename BUG: 884597 Change-Id: Ifaacd8dba0f39cb909761ffc8fe7e06cd44ec8de Signed-off-by: shishir gowda <sgowda> Reviewed-on: http://review.gluster.org/5025 Tested-by: Gluster Build System <jenkins.com> Reviewed-by: Vijay Bellur <vbellur> REVIEW: http://review.gluster.org/4682 (cluster/dht: Linkfiles creation with correct uid/gid) posted (#4) for review on master by Shishir Gowda (sgowda) REVIEW: http://review.gluster.org/4682 (cluster/dht: Linkfiles creation with correct uid/gid) posted (#5) for review on master by Shishir Gowda (sgowda) REVIEW: http://review.gluster.org/4682 (cluster/dht: Linkfiles creation with correct uid/gid) posted (#6) for review on master by Shishir Gowda (sgowda) COMMIT: http://review.gluster.org/4682 committed in master by Vijay Bellur (vbellur) ------ commit 003713139c8a7830a90a40dfead72f8299c17e31 Author: shishir gowda <sgowda> Date: Mon Mar 18 14:44:20 2013 +0530 cluster/dht: Linkfiles creation with correct uid/gid If renames are done with different uid/gid (non-owners), then we would end up with incorrect uid/gid. The fix is to create linkfiles, and heal the uid/gid as root:root. This preserves our notion of creation as root:root and heal the uid/gid as root:root in all paths. Additionally, we need to consider uid/gid from only src_cached subvol, and not from linkfiles. rename is also done as root:root if done on linkfile, as setattr of ownership on linkfile is done after the rename Change-Id: Icb5d431dc42da9c02dfae81980e3fe769a47a274 BUG: 884597 Signed-off-by: shishir gowda <sgowda> Reviewed-on: http://review.gluster.org/4682 Tested-by: Gluster Build System <jenkins.com> Reviewed-by: Jeff Darcy <jdarcy> 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-3.3.2, please reopen this bug report. The fix for this bug likely to be included in all future GlusterFS releases i.e. release > 3.3.2. In the same line the recent release i.e. glusterfs-3.4.3 [1] and glusterfs-3.5.0 [2] likely to have the fix. You can verify this by reading the comments in this bug report and checking for comments mentioning "committed in release-3.4" and/or "committed in release-3.5". [1] http://thread.gmane.org/gmane.comp.file-systems.gluster.devel/5978 [2] http://thread.gmane.org/gmane.comp.file-systems.gluster.devel/6137 |