[sheepdog] [PATCH 2/2] sheep: run object recovery even if sheep was stopped cleanly

morita.kazutaka at gmail.com morita.kazutaka at gmail.com
Wed Jul 10 10:50:20 CEST 2013


From: MORITA Kazutaka <morita.kazutaka at lab.ntt.co.jp>

Currently, if the administrator run 'collie cluster shutdown' or power
failure (all the nodes stop with the same epoch information) happens
while object recovery is ongoing, sheepdog cannot restart the recovery
after all the sheeps come back.  We should kick recovery even if we
don't need to increment epoch.

Signed-off-by: MORITA Kazutaka <morita.kazutaka at lab.ntt.co.jp>
---
 sheep/group.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/sheep/group.c b/sheep/group.c
index 2f52d0d..8363624 100644
--- a/sheep/group.c
+++ b/sheep/group.c
@@ -766,7 +766,10 @@ static void update_cluster_info(const struct join_message *msg,
 
 			start_recovery(main_thread_get(current_vnode_info),
 				       old_vnode_info, true);
-		}
+		} else
+			start_recovery(main_thread_get(current_vnode_info),
+				       main_thread_get(current_vnode_info),
+				       false);
 
 		if (have_enough_zones())
 			sys->status = SD_STATUS_OK;
-- 
1.7.9.5




More information about the sheepdog mailing list