qa/tasks/ceph: explicitly add osds to crush map for upgrades

Before kraken, ceph-osd didn't add itself to crush... ceph-osd-prestart.sh
did it.  And ceph.py doesn't use that.

Signed-off-by: Sage Weil <sage@redhat.com>
This commit is contained in:
Sage Weil 2017-06-27 12:52:35 -04:00
parent 2c8904506a
commit e7006d06fb
8 changed files with 21 additions and 0 deletions

View File

@ -7,4 +7,5 @@ tasks:
- print: "**** done install jewel"
- ceph:
skip_mgr_daemons: true
add_osds_to_crush: true
- print: "**** done ceph"

View File

@ -6,6 +6,7 @@ tasks:
- ceph:
fs: xfs
skip_mgr_daemons: true
add_osds_to_crush: true
- install.upgrade:
exclude_packages: ['ceph-mgr','libcephfs2','libcephfs-devel','libcephfs-dev']
osd.0:

View File

@ -10,6 +10,7 @@ tasks:
- ceph:
fs: xfs
skip_mgr_daemons: true
add_osds_to_crush: true
- install.upgrade:
exclude_packages:
- ceph-mgr

View File

@ -10,3 +10,4 @@ tasks:
- ceph:
fs: xfs
skip_mgr_daemons: true
add_osds_to_crush: true

View File

@ -10,6 +10,7 @@ tasks:
- print: "**** done installing jewel"
- ceph:
skip_mgr_daemons: true
add_osds_to_crush: true
- print: "**** done ceph"
- install.upgrade:
mon.a:

View File

@ -49,6 +49,7 @@ tasks:
- ceph:
fs: xfs
skip_mgr_daemons: true
add_osds_to_crush: true
- print: "**** done ceph xfs"
- sequential:
- workload

View File

@ -7,4 +7,5 @@ tasks:
- print: "**** done install jewel"
- ceph:
skip_mgr_daemons: true
add_osds_to_crush: true
- print: "**** done ceph"

View File

@ -1130,6 +1130,20 @@ def run_daemon(ctx, config, type_):
id_,
]
)
if config.get('add_osds_to_crush'):
remote.run(
args=[
'sudo',
'ceph',
'osd',
'crush',
'create-or-move',
'osd.' + id_,
'1.0',
'host=localhost',
'root=default',
]
)
run_cmd = [
'sudo',