summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/dht/src/dht-rebalance.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/cluster/dht/src/dht-rebalance.c')
-rw-r--r--xlators/cluster/dht/src/dht-rebalance.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/xlators/cluster/dht/src/dht-rebalance.c b/xlators/cluster/dht/src/dht-rebalance.c
index 97bd6bea6b7..6fdc5b04073 100644
--- a/xlators/cluster/dht/src/dht-rebalance.c
+++ b/xlators/cluster/dht/src/dht-rebalance.c
@@ -1645,10 +1645,14 @@ dht_migrate_file (xlator_t *this, loc_t *loc, xlator_t *from, xlator_t *to,
}
syncop_close (dst_fd);
+ dst_fd = NULL;
old_target = to;
to = new_target;
+ clean_dst = _gf_false;
+
+
/* if the file migration is successful to this new target, then
* update the xattr on the old destination to point the new
* destination. We need to do update this only post migration
@@ -1663,6 +1667,7 @@ dht_migrate_file (xlator_t *this, loc_t *loc, xlator_t *from, xlator_t *to,
} else {
gf_msg (this->name, GF_LOG_INFO, 0, 0, "destination for file "
"- %s is changed to - %s", loc->path, to->name);
+ clean_dst = _gf_true;
}
}