diff options
author | Mohammed Rafi KC <rkavunga@redhat.com> | 2015-12-23 23:37:54 +0530 |
---|---|---|
committer | Dan Lambright <dlambrig@redhat.com> | 2016-02-22 06:51:34 -0800 |
commit | 830f6ebe7462aef6b190c63d7c49288501283ab3 (patch) | |
tree | a60590ed7abf2134add7cbe0ed2cc8de823c3d69 /xlators/storage | |
parent | 6a565219fb1631e9b14c676458c8c04251886494 (diff) |
tier/unlink: symlink failed to unlink
during unlink of a file, we will get stat just after
deleting the file, to see if the file is under migration or not
but this stat call will fail for symlink if the actual file
was deleted.
So it is better not to send stat request from client if it is
a symlink as we are not migrating symlink
back port of>
>Change-Id: Idc033b24fa3522b5261e579889d2195b43419682
>BUG: 1293963
>Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com>
>Reviewed-on: http://review.gluster.org/13074
>Tested-by: Gluster Build System <jenkins@build.gluster.com>
>Tested-by: NetBSD Build System <jenkins@build.gluster.org>
>Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
>Reviewed-by: Dan Lambright <dlambrig@redhat.com>
>Tested-by: Dan Lambright <dlambrig@redhat.com>
Change-Id: Ic53a9ad29722927f44004d2e7289c807c7485df0
BUG: 1295347
Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com>
Reviewed-on: http://review.gluster.org/13159
Smoke: Gluster Build System <jenkins@build.gluster.com>
CentOS-regression: Gluster Build System <jenkins@build.gluster.com>
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
Reviewed-by: Dan Lambright <dlambrig@redhat.com>
Diffstat (limited to 'xlators/storage')
-rw-r--r-- | xlators/storage/posix/src/posix.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/xlators/storage/posix/src/posix.c b/xlators/storage/posix/src/posix.c index 473d73994e0..27885b8f8c5 100644 --- a/xlators/storage/posix/src/posix.c +++ b/xlators/storage/posix/src/posix.c @@ -1759,7 +1759,8 @@ posix_unlink (call_frame_t *frame, xlator_t *this, goto out; } - if (xdata && dict_get (xdata, DHT_IATT_IN_XDATA_KEY)) { + if (IA_ISREG (loc->inode->ia_type) && + xdata && dict_get (xdata, DHT_IATT_IN_XDATA_KEY)) { fdstat_requested = 1; } |