Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

qa/tests: Wip ceph deploy upgrade #17651

Merged
merged 3 commits into from
Dec 13, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
meta:
- desc: |
Setup 4 node ceph cluster using ceph-deploy, use latest
stable jewel as initial release, upgrade to luminous and
also setup mgr nodes along after upgrade, check for
cluster to reach healthy state, After upgrade run kernel tar/untar
task and systemd task. This test will detect any
ceph upgrade issue and systemd issues.
stable jewel as initial release, upgrade to stable luminous and
also setup mgr nodes along after upgrade, check for cluter to
reach healthy state and run kernel tar/untar task. Finally upgrade
to master dev branch and wait for healthy state, Run systemd and
mixed-load gen task. This test will detect any ceph upgrade issue
and systemd issues.
overrides:
ceph-deploy:
fs: xfs
Expand Down Expand Up @@ -43,7 +44,7 @@ tasks:
skip-mgr: True
- ceph-deploy.upgrade:
branch:
dev: luminous
stable: luminous
setup-mgr-node: True
check-for-healthy: True
roles:
Expand All @@ -54,6 +55,13 @@ tasks:
clients:
all:
- kernel_untar_build.sh
- ceph-deploy.upgrade:
setup-mgr-node: False
check-for-healthy: True
roles:
- mon.a
- mon.b
- mon.c
- systemd:
- workunit:
clients:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
meta:
- desc: |
Setup 4 node ceph cluster using ceph-deploy, use latest
stable kraken as initial release, upgrade to luminous and
also setup mgr nodes along after upgrade, check for
cluster to reach healthy state, After upgrade run kernel tar/untar
task and systemd task. This test will detect any
ceph upgrade issue and systemd issues.
stable jewel as initial release, upgrade to stable luminous and
also setup mgr nodes along after upgrade, check for cluter to
reach healthy state and run kernel tar/untar task. Finally upgrade
to current master branch and wait for healthy state, Run systemd and
mixed-load gen task. This test will detect any ceph upgrade issue
and systemd issues.
overrides:
ceph-deploy:
fs: xfs
Expand Down Expand Up @@ -43,7 +44,7 @@ tasks:
skip-mgr: True
- ceph-deploy.upgrade:
branch:
dev: luminous
stable: luminous
setup-mgr-node: True
check-for-healthy: True
roles:
Expand All @@ -54,6 +55,13 @@ tasks:
clients:
all:
- kernel_untar_build.sh
- ceph-deploy.upgrade:
setup-mgr-node: False
check-for-healthy: True
roles:
- mon.a
- mon.b
- mon.c
- systemd:
- workunit:
clients:
Expand Down
15 changes: 11 additions & 4 deletions qa/tasks/ceph_deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,13 @@ def get_nodes_using_role(ctx, target_role):
modified_remotes[_remote].append(svc_id)

ctx.cluster.remotes = modified_remotes
ctx.cluster.mapped_role = ceph_deploy_mapped

# since the function is called multiple times for target roles
# append new mapped roles
if not hasattr(ctx.cluster, 'mapped_role'):
ctx.cluster.mapped_role = ceph_deploy_mapped
else:
ctx.cluster.mapped_role.update(ceph_deploy_mapped)
log.info("New mapped_role={mr}".format(mr=ctx.cluster.mapped_role))
return nodes_of_interest


Expand Down Expand Up @@ -781,13 +786,15 @@ def upgrade(ctx, config):
# get the roles that are mapped as per ceph-deploy
# roles are mapped for mon/mds eg: mon.a => mon.host_short_name
mapped_role = ctx.cluster.mapped_role
log.info("roles={r}, mapped_roles={mr}".format(r=roles, mr=mapped_role))
if config.get('branch'):
branch = config.get('branch')
(var, val) = branch.items()[0]
ceph_branch = '--{var}={val}'.format(var=var, val=val)
else:
# default to master
ceph_branch = '--dev=master'
# default to wip-branch under test
dev_branch = ctx.config['branch']
ceph_branch = '--dev={branch}'.format(branch=dev_branch)
# get the node used for initial deployment which is mon.a
mon_a = mapped_role.get('mon.a')
(ceph_admin,) = ctx.cluster.only(mon_a).remotes.iterkeys()
Expand Down