From ac2cd684c2d8fa4a66800a6cc98f6c5c562b4b7f Mon Sep 17 00:00:00 2001 From: shishir gowda Date: Tue, 30 Jul 2013 17:22:58 +0530 Subject: cluster/dht: Fix non-regular file ownership during rebalance Currently non-regular files were created as root:root, and their ownership never healed during rebalance process. Also, in dht_linkfile_attr_heal, we have to heal the linkfiles as default, as currently linkfiles are created as root:root. That check existed, as earlier linkfiles were created as frame->root->uid/gid Change-Id: I6cd88361b81bdd500e15bc47b623f5db8eec88e9 BUG: 990154 Signed-off-by: shishir gowda Reviewed-on: http://review.gluster.org/5434 Tested-by: Gluster Build System Reviewed-by: Amar Tumballi Reviewed-by: Anand Avati --- xlators/cluster/dht/src/dht-linkfile.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'xlators/cluster/dht/src/dht-linkfile.c') diff --git a/xlators/cluster/dht/src/dht-linkfile.c b/xlators/cluster/dht/src/dht-linkfile.c index ae5bd49d988..dbc9d0b3c7b 100644 --- a/xlators/cluster/dht/src/dht-linkfile.c +++ b/xlators/cluster/dht/src/dht-linkfile.c @@ -297,9 +297,7 @@ dht_linkfile_attr_heal (call_frame_t *frame, xlator_t *this) GF_VALIDATE_OR_GOTO ("dht", local, out); GF_VALIDATE_OR_GOTO ("dht", local->link_subvol, out); - if ((local->stbuf.ia_type == IA_INVAL) || - (is_equal (frame->root->uid, local->stbuf.ia_uid) && - is_equal (frame->root->gid, local->stbuf.ia_gid))) + if (local->stbuf.ia_type == IA_INVAL) return 0; uuid_copy (local->loc.gfid, local->stbuf.ia_gfid); -- cgit