From f2b72455209ae79f4d1aa2e0a464fd4f1062b126 Mon Sep 17 00:00:00 2001 From: Alfredo Moralejo Date: Fri, 5 Apr 2019 15:26:49 +0200 Subject: [PATCH] Replace Ceph Mimic by Nautilus in CentOS Ceph Nautilus has now a stable release 14.2.0 and it's being packaged in CentOS Storage SIG. Mimic release was not LTS so let's replace it by Nautilus where possible. Since nautilus, the supported store backend is LVM which can use a block device directly (not loopback) or a LVM logical volume for OSDs. This patch is creating a LVM structure to create the OSD used to validate Ceph and switching scenario004 to use nautilus instead of mimic, so we will keep testing both Luminous and Nautilus, LTS releases. Depends-On: https://review.opendev.org/#/c/650263/ Change-Id: I81441237a8b7cf651fa6926b2eb3c4ed0d42bb58 --- configure_facts.sh | 2 +- manifests/ceph.pp | 19 ++++++++++++++++++- zuul.d/integration.yaml | 8 ++++++-- zuul.d/layout.yaml | 12 ++++++------ 4 files changed, 31 insertions(+), 10 deletions(-) diff --git a/configure_facts.sh b/configure_facts.sh index 2c50c6daa..e1a28eeeb 100644 --- a/configure_facts.sh +++ b/configure_facts.sh @@ -17,7 +17,7 @@ export WRITE_FACTS=${WRITE_FACTS:-true} export DLRN_BASE=${DLRN_BASE:-centos7-master/puppet-passed-ci} export DLRN_DEPS_BASE=${DLRN_DEPS_BASE:-centos7-master/deps/latest/} -export CEPH_VERSION=${CEPH_VERSION:-mimic} +export CEPH_VERSION=${CEPH_VERSION:-nautilus} export SCRIPT_DIR=$(cd `dirname $0` && pwd -P) source $SCRIPT_DIR/functions diff --git a/manifests/ceph.pp b/manifests/ceph.pp index f285c0e2a..b8808c806 100644 --- a/manifests/ceph.pp +++ b/manifests/ceph.pp @@ -34,6 +34,23 @@ class openstack_integration::ceph ( }) } + exec { 'lvm_create': + command => "/bin/true # comment to satisfy puppet syntax requirements +truncate --size=10G /diskimage.img +losetup /dev/loop0 /diskimage.img +pvcreate /dev/loop0 +vgcreate ceph_vg /dev/loop0 +lvcreate -n lv_data -a y -l 100%FREE ceph_vg +", + unless => "/bin/true # comment to satisfy puppet syntax requirements +set -ex +test -b /dev/ceph_vg/lv_data +", + logoutput => true, + } + + Exec['lvm_create'] -> Class['Ceph::Osds'] + class { '::ceph::profile::params': fsid => '7200aea0-2ddd-4a32-aa2a-d49f66ab554c', manage_repo => false, # repo already managed in openstack_integration::repo @@ -68,7 +85,7 @@ class openstack_integration::ceph ( }, }, osds => { - '/var/lib/ceph/data' => {}, + 'ceph_vg/lv_data' => {}, }, # Configure Ceph RadosGW # These could be always set in the above call to ceph::profile::params diff --git a/zuul.d/integration.yaml b/zuul.d/integration.yaml index e06b56825..7dca816ed 100644 --- a/zuul.d/integration.yaml +++ b/zuul.d/integration.yaml @@ -194,9 +194,11 @@ ceph: mimic - job: - name: puppet-openstack-integration-5-scenario004-tempest-centos-7-mimic + name: puppet-openstack-integration-5-scenario004-tempest-centos-7-nautilus parent: puppet-openstack-integration-5-scenario004 nodeset: centos-7 + vars: + ceph: nautilus - job: name: puppet-openstack-integration-5-scenario004-tempest-debian-stable-luminous @@ -311,9 +313,11 @@ ceph: mimic - job: - name: puppet-openstack-integration-6-scenario004-tempest-centos-7-mimic + name: puppet-openstack-integration-6-scenario004-tempest-centos-7-nautilus parent: puppet-openstack-integration-6-scenario004 nodeset: centos-7 + vars: + ceph: nautilus - job: name: puppet-openstack-integration-6-scenario004-tempest-debian-stable-luminous diff --git a/zuul.d/layout.yaml b/zuul.d/layout.yaml index e7abad8bb..bd1a6120d 100644 --- a/zuul.d/layout.yaml +++ b/zuul.d/layout.yaml @@ -57,7 +57,7 @@ - puppet-openstack-integration-5-scenario001-tempest-centos-7-luminous - puppet-openstack-integration-5-scenario002-tempest-centos-7 - puppet-openstack-integration-5-scenario003-tempest-centos-7 - - puppet-openstack-integration-5-scenario004-tempest-centos-7-mimic + - puppet-openstack-integration-5-scenario004-tempest-centos-7-nautilus - puppet-openstack-integration-5-scenario001-tempest-ubuntu-bionic-mimic - puppet-openstack-integration-5-scenario002-tempest-ubuntu-bionic - puppet-openstack-integration-5-scenario003-tempest-ubuntu-bionic @@ -67,7 +67,7 @@ - puppet-openstack-integration-5-scenario001-tempest-centos-7-luminous - puppet-openstack-integration-5-scenario002-tempest-centos-7 - puppet-openstack-integration-5-scenario003-tempest-centos-7 - - puppet-openstack-integration-5-scenario004-tempest-centos-7-mimic + - puppet-openstack-integration-5-scenario004-tempest-centos-7-nautilus experimental: jobs: - puppet-openstack-integration-4-scenario001-tempest-debian-stable-luminous: @@ -89,7 +89,7 @@ - puppet-openstack-integration-6-scenario001-tempest-centos-7-luminous - puppet-openstack-integration-6-scenario002-tempest-centos-7 - puppet-openstack-integration-6-scenario003-tempest-centos-7 - - puppet-openstack-integration-6-scenario004-tempest-centos-7-mimic + - puppet-openstack-integration-6-scenario004-tempest-centos-7-nautilus - puppet-openstack-integration-6-scenario001-tempest-ubuntu-bionic-mimic - puppet-openstack-integration-6-scenario002-tempest-ubuntu-bionic - puppet-openstack-integration-6-scenario003-tempest-ubuntu-bionic @@ -156,10 +156,10 @@ check: jobs: - puppet-openstack-integration-5-scenario004-tempest-ubuntu-bionic-mimic - - puppet-openstack-integration-5-scenario004-tempest-centos-7-mimic + - puppet-openstack-integration-5-scenario004-tempest-centos-7-nautilus gate: jobs: - - puppet-openstack-integration-5-scenario004-tempest-centos-7-mimic + - puppet-openstack-integration-5-scenario004-tempest-centos-7-nautilus experimental: jobs: - puppet-openstack-integration-4-scenario004-tempest-debian-stable-luminous: @@ -167,4 +167,4 @@ - puppet-openstack-integration-5-scenario004-tempest-debian-stable-luminous - puppet-openstack-integration-6-scenario004-tempest-debian-stable-luminous - puppet-openstack-integration-6-scenario004-tempest-ubuntu-bionic-mimic - - puppet-openstack-integration-6-scenario004-tempest-centos-7-mimic + - puppet-openstack-integration-6-scenario004-tempest-centos-7-nautilus