diff options
author | shishir gowda <shishirng@gluster.com> | 2011-05-31 01:30:18 +0000 |
---|---|---|
committer | Anand Avati <avati@gluster.com> | 2011-05-31 09:11:46 -0700 |
commit | 1d4cdc10294871702bfc0e68a54b61352f318c31 (patch) | |
tree | 7ddca8df36e27a8e012b6817edb9c4eb4c054976 /xlators/cluster/dht/src/dht-common.h | |
parent | 9dcb29b5abfc0f221890780901fc855acd73ba48 (diff) |
DHT-rename: Unlink older link files before creating new one.
If older link file exists, unlink it and then create linkfiles.
This will prevent mismatch of gfid
Signed-off-by: shishir gowda <shishirng@gluster.com>
Signed-off-by: Anand Avati <avati@gluster.com>
BUG: 2464 ([7b07d444a77526f27f860210930bf1d4c7fbea9b]: rm -rf gives Invalid argumenrt error)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2464
Diffstat (limited to 'xlators/cluster/dht/src/dht-common.h')
-rw-r--r-- | xlators/cluster/dht/src/dht-common.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/xlators/cluster/dht/src/dht-common.h b/xlators/cluster/dht/src/dht-common.h index f6e5e6d0d07..0a39da97228 100644 --- a/xlators/cluster/dht/src/dht-common.h +++ b/xlators/cluster/dht/src/dht-common.h @@ -303,5 +303,13 @@ 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 */ |