From 0c9129bf4377b1fa32a98cf1074a405407f2cb79 Mon Sep 17 00:00:00 2001 From: Alfredo Deza Date: Mon, 6 Jan 2014 13:50:35 -0500 Subject: [PATCH] error after 15 minutes of waiting for gatherkeys Signed-off-by: Alfredo Deza (cherry picked from commit ad18717505c407f2c8bb995af8fd516b61957661) --- teuthology/task/ceph-deploy.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/teuthology/task/ceph-deploy.py b/teuthology/task/ceph-deploy.py index c07aa57ee9..8f37e4dac0 100644 --- a/teuthology/task/ceph-deploy.py +++ b/teuthology/task/ceph-deploy.py @@ -225,10 +225,15 @@ def build_ceph_cluster(ctx, config): raise RuntimeError("ceph-deploy: Failed to create monitors") estatus_gather = execute_ceph_deploy(ctx, config, gather_keys) + max_gather_tries = 90 + gather_tries = 0 while (estatus_gather != 0): - #mon_create_nodes = './ceph-deploy mon create'+" "+mon_node[0] - #execute_ceph_deploy(ctx, config, mon_create_nodes) + gather_tries += 1 + if gather_tries >= max_gather_tries: + msg = 'ceph-deploy was not able to gatherkeys after 15 minutes' + raise RuntimeError(msg) estatus_gather = execute_ceph_deploy(ctx, config, gather_keys) + time.sleep(10) if mds_nodes: estatus_mds = execute_ceph_deploy(ctx, config, deploy_mds) -- 2.39.5