[Sheepdog] [PATCH 1/4] collie: add more detailed error messages

MORITA Kazutaka morita.kazutaka at lab.ntt.co.jp
Thu Feb 11 18:17:07 CET 2010


Signed-off-by: MORITA Kazutaka <morita.kazutaka at lab.ntt.co.jp>
---
 collie/store.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/collie/store.c b/collie/store.c
index d242e8d..842271c 100644
--- a/collie/store.c
+++ b/collie/store.c
@@ -330,6 +330,7 @@ static int ob_open(uint32_t epoch, uint64_t oid, int aflags, int *ret)
 
 	fd = open(path, flags, def_fmode);
 	if (fd < 0) {
+		eprintf("failed to open %s, %s\n", path, strerror(errno));
 		if (errno == ENOENT)
 			*ret = SD_RES_NO_OBJ;
 		else
@@ -576,8 +577,8 @@ void store_queue_request(struct work *work, int idx)
 	ret = store_queue_request_local(cluster, req, buf, epoch);
 out:
 	if (ret != SD_RES_SUCCESS) {
-		dprintf("failed, %d, %x, %" PRIx64" , %u, %u\n",
-			idx, opcode, oid, epoch, req_epoch);
+		dprintf("failed, %d, %x, %" PRIx64" , %u, %u, %x\n",
+			idx, opcode, oid, epoch, req_epoch, ret);
 		rsp->result = ret;
 	}
 }
-- 
1.5.6.5




More information about the sheepdog mailing list