[sheepdog] [PATCH] tests: retry collie node list when sheep is not ready

MORITA Kazutaka morita.kazutaka at lab.ntt.co.jp
Tue Oct 9 04:57:43 CEST 2012


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

diff --git a/tests/common.rc b/tests/common.rc
index 9c455d0..7ee1b71 100644
--- a/tests/common.rc
+++ b/tests/common.rc
@@ -149,10 +149,11 @@ _wait_for_sheep()
             _die "there are not enough sheep processes"
         fi
 
-        node_list="$($COLLIE node list)"
+        node_list="$($COLLIE node list 2> /dev/null)"
 
         if [ $? != 0 ]; then
-            _die "failed to get node list"
+            # sheep is not ready yet
+            continue
         fi
 
         nr_sheep="$(echo "$node_list" | wc -l)"
-- 
1.7.2.5




More information about the sheepdog mailing list