summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/dht/src/tier.h
diff options
context:
space:
mode:
authorN Balachandran <nbalacha@redhat.com>2015-11-09 15:49:50 +0530
committerDan Lambright <dlambrig@redhat.com>2015-11-18 07:16:12 -0800
commita1e4be4d277c8150657f7b9fd4b72dcdd639523d (patch)
tree068b9e1924b2138cbc37175b219e94ded90ae4be /xlators/cluster/dht/src/tier.h
parentcb76371a56eb90a6f2ac126c876d7a2dc203e16c (diff)
cluster/tier: Do not delete linkto file on demotion
The current DHT migration code will always delete the src linkto file after migration as dht always moves files to the hashed subvol. This is not the case in tiering. The lack of linkto files causes rename to fail leaving 2 files with the same name but different gfids on the volume. Modified to leave the linkto file behind if the source volume is the hashed subvolume. Change-Id: I2b99f7d34b4b719aee6232dc40c6a8f8ba88225d BUG: 1279376 Signed-off-by: N Balachandran <nbalacha@redhat.com> Reviewed-on: http://review.gluster.org/12551 Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
Diffstat (limited to 'xlators/cluster/dht/src/tier.h')
-rw-r--r--xlators/cluster/dht/src/tier.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/xlators/cluster/dht/src/tier.h b/xlators/cluster/dht/src/tier.h
index 0f8107924ea..2a72ae2caf6 100644
--- a/xlators/cluster/dht/src/tier.h
+++ b/xlators/cluster/dht/src/tier.h
@@ -33,6 +33,8 @@
#define PROMOTION_QFILE "promotequeryfile"
#define DEMOTION_QFILE "demotequeryfile"
+#define TIER_HASHED_SUBVOL conf->subvolumes[1]
+
#define GET_QFILE_PATH(is_promotion)\
(is_promotion) ? promotion_qfile : demotion_qfile