From e44e10d6e00ec13114d325f7b4018e7231ea3582 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Mon, 5 Feb 2018 13:06:04 -0600 Subject: [PATCH] qa/tasks/ceph.py: --no-mon-config during ceph-osd mkfs Signed-off-by: Sage Weil --- qa/tasks/ceph.py | 50 +++++++++++++++++++++++++++++++++--------------- 1 file changed, 35 insertions(+), 15 deletions(-) diff --git a/qa/tasks/ceph.py b/qa/tasks/ceph.py index f31f1c57bc15..bcd394871155 100644 --- a/qa/tasks/ceph.py +++ b/qa/tasks/ceph.py @@ -778,22 +778,42 @@ def cluster(ctx, config): for role in teuthology.cluster_roles_of_type(roles_for_host, 'osd', cluster_name): _, _, id_ = teuthology.split_role(role) - remote.run( - args=[ - 'sudo', - 'MALLOC_CHECK_=3', - 'adjust-ulimits', - 'ceph-coverage', - coverage_dir, - 'ceph-osd', - '--cluster', - cluster_name, - '--mkfs', - '--mkkey', - '-i', id_, + try: + remote.run( + args=[ + 'sudo', + 'MALLOC_CHECK_=3', + 'adjust-ulimits', + 'ceph-coverage', + coverage_dir, + 'ceph-osd', + '--no-mon-config', + '--cluster', + cluster_name, + '--mkfs', + '--mkkey', + '-i', id_, '--monmap', monmap_path, - ], - ) + ], + ) + except run.CommandFailedError: + # try without --no-mon-config.. this may be an upgrade test + remote.run( + args=[ + 'sudo', + 'MALLOC_CHECK_=3', + 'adjust-ulimits', + 'ceph-coverage', + coverage_dir, + 'ceph-osd', + '--cluster', + cluster_name, + '--mkfs', + '--mkkey', + '-i', id_, + '--monmap', monmap_path, + ], + ) mnt_point = DATA_PATH.format( type_='osd', cluster=cluster_name, id_=id_) remote.run(args=[ -- 2.47.3