[sheepdog] [PATCH] sheep: exit when version of QEMU is old
Hitoshi Mitake
mitake.hitoshi at lab.ntt.co.jp
Thu Feb 28 11:59:07 CET 2013
I encountered a problem which might be caused by a combination of old
QEMU and latest sheepdog. Suddenly qemu reported I/O errors and
objects of sheeps seemed to be broken. In the log message, I could
find the message "Some VDI faild to release the object cache. Probably
you are running old QEMU." So I updated my QEMU and the problem seemed
to be solved.
I'm not sure the real source of the problem was the version
mismatch. But from a perspective of administration, I believe that
sheep should exit in such a case.
This patch make sheep exits in such a case. Ideally, sheep should
refuse connections from old QEMUs. This is an urgent solution.
Signed-off-by: Hitoshi Mitake <mitake.hitoshi at lab.ntt.co.jp>
---
sheep/ops.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/sheep/ops.c b/sheep/ops.c
index ef74871..19048a3 100644
--- a/sheep/ops.c
+++ b/sheep/ops.c
@@ -364,9 +364,9 @@ static int local_release_vdi(struct request *req)
uint32_t vid = req->rq.vdi.base_vdi_id;
if (!vid) {
- sd_iprintf("Some VDI failed to release the object cache. "
+ sd_eprintf("Some VDI failed to release the object cache. "
"Probably you are running old QEMU.");
- return SD_RES_SUCCESS;
+ exit(1);
}
object_cache_flush_vdi(vid);
--
1.7.2.5
More information about the sheepdog
mailing list