From bc8da1a89dc43ee46cea17ffe2d61f772b8ac9ab Mon Sep 17 00:00:00 2001 From: Larry Rensing Date: Fri, 14 Jul 2017 21:35:59 +0000 Subject: [PATCH] Fix ceph single node gate health Ceph's health when running in the single node gate currently is 'HEALTH_WARN'. This PS adds an extra config option such that the ceph cluster will not attempt to perform replication when deployed on a single node, as well as introduces a mvp yaml file for ceph deployments in the gate. Change-Id: Ib2ec3345140f541c94da044ff9d77723ea3ee2bd --- ceph/templates/etc/_ceph.conf.tpl | 1 + ceph/values.yaml | 1 + tools/gate/basic_launch.sh | 19 ++++++++++++++----- tools/overrides/mvp/ceph.yaml | 21 +++++++++++++++++++++ 4 files changed, 37 insertions(+), 5 deletions(-) create mode 100644 tools/overrides/mvp/ceph.yaml diff --git a/ceph/templates/etc/_ceph.conf.tpl b/ceph/templates/etc/_ceph.conf.tpl index 7a9dd76f28..cd76ae5824 100644 --- a/ceph/templates/etc/_ceph.conf.tpl +++ b/ceph/templates/etc/_ceph.conf.tpl @@ -48,6 +48,7 @@ osd_max_object_name_len = {{ .Values.conf.ceph.config.osd.osd_max_object_name_le # crush osd_pool_default_crush_rule = {{ .Values.conf.ceph.config.osd.osd_pool_default_crush_rule | default "0" | quote }} osd_crush_update_on_start = {{ .Values.conf.ceph.config.osd.osd_crush_update_on_start | default "true" | quote }} +osd_crush_chooseleaf_type = {{ .Values.conf.ceph.config.osd.osd_crush_chooseleaf_type | default "1" | quote }} # backend osd_objectstore = {{ .Values.conf.ceph.config.osd.osd_objectstore | default "filestore" | quote }} diff --git a/ceph/values.yaml b/ceph/values.yaml index eac45b5512..117770f330 100644 --- a/ceph/values.yaml +++ b/ceph/values.yaml @@ -160,6 +160,7 @@ conf: #crush osd_pool_default_crush_rule: 0 osd_crush_update_on_start: true + osd_crush_chooseleaf_type: 1 #backend osd_objectstore: filestore #performance tuning diff --git a/tools/gate/basic_launch.sh b/tools/gate/basic_launch.sh index 6c3613eeac..a387d078eb 100755 --- a/tools/gate/basic_launch.sh +++ b/tools/gate/basic_launch.sh @@ -49,11 +49,20 @@ EOF" export osd_cluster_network=${SUBNET_RANGE} export osd_public_network=${SUBNET_RANGE} - helm install --namespace=ceph ${WORK_DIR}/ceph --name=ceph \ - --set manifests_enabled.client_secrets=false \ - --set network.public=$osd_public_network \ - --set network.cluster=$osd_cluster_network \ - --set bootstrap.enabled=true + if [ "x$INTEGRATION" == "xaio" ]; then + helm install --namespace=ceph ${WORK_DIR}/ceph --name=ceph \ + --set manifests_enabled.client_secrets=false \ + --set network.public=$osd_public_network \ + --set network.cluster=$osd_cluster_network \ + --set bootstrap.enabled=true \ + --values=${WORK_DIR}/tools/overrides/mvp/ceph.yaml + else + helm install --namespace=ceph ${WORK_DIR}/ceph --name=ceph \ + --set manifests_enabled.client_secrets=false \ + --set network.public=$osd_public_network \ + --set network.cluster=$osd_cluster_network \ + --set bootstrap.enabled=true + fi kube_wait_for_pods ceph 600 diff --git a/tools/overrides/mvp/ceph.yaml b/tools/overrides/mvp/ceph.yaml new file mode 100644 index 0000000000..4b467de519 --- /dev/null +++ b/tools/overrides/mvp/ceph.yaml @@ -0,0 +1,21 @@ +# Copyright 2017 The Openstack-Helm Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +conf: + ceph: + config: + global: + osd_pool_default_size: 1 + osd: + osd_crush_chooseleaf_type: 0