From 753f17aca63057e4c4a70c1f3cbf7729f890cb69 Mon Sep 17 00:00:00 2001 From: shishir gowda Date: Fri, 27 May 2011 00:41:55 +0000 Subject: dht-rename: Unlink older link files before creating new one If a older link file exists, unlink it and then create the linkfile. This will prevent mis-match of gfid's. Signed-off-by: shishir gowda Signed-off-by: Anand Avati BUG: 2464 ([7b07d444a77526f27f860210930bf1d4c7fbea9b]: rm -rf gives Invalid argumenrt error) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2464 --- xlators/cluster/dht/src/dht-common.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'xlators/cluster/dht/src/dht-common.h') diff --git a/xlators/cluster/dht/src/dht-common.h b/xlators/cluster/dht/src/dht-common.h index bc84098b7..99b626c16 100644 --- a/xlators/cluster/dht/src/dht-common.h +++ b/xlators/cluster/dht/src/dht-common.h @@ -309,4 +309,12 @@ int dht_build_child_loc (xlator_t *this, loc_t *child, loc_t *parent, char *name int dht_filter_loc_subvol_key (xlator_t *this, loc_t *loc, loc_t *new_loc, xlator_t **subvol); +int dht_rename_cleanup (call_frame_t *frame); +int dht_rename_links_cbk (call_frame_t *frame, void *cookie, xlator_t *this, + int32_t op_ret, int32_t op_errno, + inode_t *inode, struct iatt *stbuf, + struct iatt *preparent, struct iatt *postparent); + +int dht_linkfile_recreate(call_frame_t *frame, fop_mknod_cbk_t linkfile_cbk, + xlator_t *tovol, xlator_t *fromvol, loc_t *loc); #endif /* _DHT_H */ -- cgit