|
|
3604df |
From af0269a4bd909e80a735543401c748aba17f3fb1 Mon Sep 17 00:00:00 2001
|
|
|
3604df |
From: Pranith Kumar K <pkarampu@redhat.com>
|
|
|
3604df |
Date: Tue, 3 Jan 2017 12:50:54 +0530
|
|
|
3604df |
Subject: [PATCH 264/267] cluster/dht: Do rename cleanup as root
|
|
|
3604df |
|
|
|
3604df |
Problem:
|
|
|
3604df |
Rename linkfile cleanup is done as non-root which may not have priviliges to do
|
|
|
3604df |
the rename so it fails with EACCESS. MKDIR on that name in future will start to
|
|
|
3604df |
hole on this subvolume. It is not easy to hit on fuse mounts because vfs takes
|
|
|
3604df |
care of the permission checks even before rename fop is wound. But with
|
|
|
3604df |
nfs-ganesha mounts it happens.
|
|
|
3604df |
|
|
|
3604df |
Fix:
|
|
|
3604df |
Do rename cleanup as root
|
|
|
3604df |
|
|
|
3604df |
>BUG: 1409727
|
|
|
3604df |
>Change-Id: I414c1eb6dce76b4516a6c940557b249e6c3f22f4
|
|
|
3604df |
>Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
|
|
|
3604df |
>Reviewed-on: http://review.gluster.org/16317
|
|
|
3604df |
>Smoke: Gluster Build System <jenkins@build.gluster.org>
|
|
|
3604df |
>CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
|
|
|
3604df |
>Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
|
|
|
3604df |
>Reviewed-by: N Balachandran <nbalacha@redhat.com>
|
|
|
3604df |
>NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
|
|
|
3604df |
|
|
|
3604df |
BUG: 1408413
|
|
|
3604df |
Change-Id: I062b5a02437bcfbc25fdf6830566655a4c74a3fd
|
|
|
3604df |
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
|
|
|
3604df |
Reviewed-on: https://code.engineering.redhat.com/gerrit/94321
|
|
|
3604df |
---
|
|
|
3604df |
xlators/cluster/dht/src/dht-rename.c | 1 +
|
|
|
3604df |
1 file changed, 1 insertion(+)
|
|
|
3604df |
|
|
|
3604df |
diff --git a/xlators/cluster/dht/src/dht-rename.c b/xlators/cluster/dht/src/dht-rename.c
|
|
|
3604df |
index a9ffd1d..d955ee4 100644
|
|
|
3604df |
--- a/xlators/cluster/dht/src/dht-rename.c
|
|
|
3604df |
+++ b/xlators/cluster/dht/src/dht-rename.c
|
|
|
3604df |
@@ -724,6 +724,7 @@ dht_rename_cleanup (call_frame_t *frame)
|
|
|
3604df |
|
|
|
3604df |
DHT_MARKER_DONT_ACCOUNT(xattr_new);
|
|
|
3604df |
|
|
|
3604df |
+ FRAME_SU_DO (frame, dht_local_t);
|
|
|
3604df |
STACK_WIND (frame, dht_rename_unlink_cbk,
|
|
|
3604df |
dst_hashed, dst_hashed->fops->unlink,
|
|
|
3604df |
&local->loc, 0, xattr_new);
|
|
|
3604df |
--
|
|
|
3604df |
2.9.3
|
|
|
3604df |
|