From 89cdfb40264c12105a1b4990fa9b45290aa6cef0 Mon Sep 17 00:00:00 2001 From: Vinayakswami Hariharmath Date: Fri, 8 Oct 2021 09:40:41 +0530 Subject: [PATCH 609/610] feature/shard: wrong dname results in dentry not found error Due to wrong dname passed to inode_unlink in shard_evicted_inode_fsync_cbk() resulting in dentry not found error. This patch addresses the issue. > upstream patch: https://github.com/gluster/glusterfs/pull/2475 > Fixes: #2470 > Change-Id: I6c479980ae3fa7ba558327055a9e5e5c2d2a850f > Signed-off-by: Vinayakswami Hariharmath vharihar@redhat.com BUG: 1911665 Change-Id: I96aa5f57303b69a08990de039ddeecad7e7ae6af Signed-off-by: Vinayakswami Hariharmath Reviewed-on: https://code.engineering.redhat.com/gerrit/c/rhs-glusterfs/+/280202 Tested-by: RHGS Build Bot Reviewed-by: Sunil Kumar Heggodu Gopala Acharya --- xlators/features/shard/src/shard.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xlators/features/shard/src/shard.c b/xlators/features/shard/src/shard.c index b828ff9..882373f 100644 --- a/xlators/features/shard/src/shard.c +++ b/xlators/features/shard/src/shard.c @@ -950,7 +950,7 @@ shard_evicted_inode_fsync_cbk(call_frame_t *frame, void *cookie, xlator_t *this, { __shard_inode_ctx_get(shard_inode, this, &ctx); if ((list_empty(&ctx->to_fsync_list)) && (list_empty(&ctx->ilist))) { - shard_make_block_bname(ctx->block_num, shard_inode->gfid, + shard_make_block_bname(ctx->block_num, ctx->base_gfid, block_bname, sizeof(block_bname)); inode_unlink(shard_inode, priv->dot_shard_inode, block_bname); /* The following unref corresponds to the ref held by -- 1.8.3.1