summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKrutika Dhananjay <kdhananj@redhat.com>2016-05-09 16:53:19 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2016-06-03 19:00:21 -0700
commitbac2781a2d3f26d09fd5687fd519b4cb4bdba1f4 (patch)
tree9ce0686cdb410ea82078721712e71dc485faeb7d
parent8d493c22deaf52db82f03c049f99d5ac5857769f (diff)
storage/posix: Print offset,size and gfid too when readv failsv3.7.12rc1
... for better debuggability. Backport of: http://review.gluster.org/14271 Here's a sample log: [2016-05-31 05:18:34.893951] E [MSGID: 113040] [posix.c:3089:posix_readv] 0-dis-posix: read failed on gfid=3744d34b-f798-4ce2-b421-cc632a9903bd, fd=0x7f8b3c015abc, offset=131072 size=131072 [Invalid argument] Change-Id: Ied15223b25dbde9ffc40af5012d96164a32fb7c3 BUG: 1342348 Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com> Reviewed-on: http://review.gluster.org/14625 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.com> Smoke: Gluster Build System <jenkins@build.gluster.com>
-rw-r--r--xlators/storage/posix/src/posix.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/xlators/storage/posix/src/posix.c b/xlators/storage/posix/src/posix.c
index 35d5ac8fb86..582589b5de5 100644
--- a/xlators/storage/posix/src/posix.c
+++ b/xlators/storage/posix/src/posix.c
@@ -3019,7 +3019,9 @@ posix_readv (call_frame_t *frame, xlator_t *this,
if (op_ret == -1) {
op_errno = errno;
gf_msg (this->name, GF_LOG_ERROR, errno, P_MSG_READ_FAILED,
- "read failed on fd=%p", fd);
+ "read failed on gfid=%s, fd=%p, offset=%"PRIu64" "
+ "size=%"GF_PRI_SIZET"", uuid_utoa (fd->inode->gfid), fd,
+ offset, size);
goto out;
}