From 208b6d7b1a4d98e62d4bfa3b342bb78ade078799 Mon Sep 17 00:00:00 2001 From: Raghavendra Bhat Date: Tue, 31 Mar 2020 11:25:51 -0400 Subject: storage/posix: log the ENOENT errors in posix_pstat Change-Id: I93f11dae6e4939ab79b0481ead2a4f7bb3085b70 Fixes: #1142 Signed-off-by: Raghavendra Bhat --- xlators/storage/posix/src/posix-helpers.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'xlators/storage') diff --git a/xlators/storage/posix/src/posix-helpers.c b/xlators/storage/posix/src/posix-helpers.c index d18db1098fc..372df89807c 100644 --- a/xlators/storage/posix/src/posix-helpers.c +++ b/xlators/storage/posix/src/posix-helpers.c @@ -824,6 +824,11 @@ posix_pstat(xlator_t *this, inode_t *inode, uuid_t gfid, const char *path, gf_msg(this->name, GF_LOG_WARNING, errno, P_MSG_LSTAT_FAILED, "lstat failed on %s", path); errno = op_errno; /*gf_msg could have changed errno*/ + } else { + op_errno = errno; + gf_msg_debug(this->name, 0, "lstat failed on %s (%s)", path, + strerror(errno)); + errno = op_errno; /*gf_msg could have changed errno*/ } goto out; } -- cgit