aboutsummaryrefslogtreecommitdiffstats
path: root/deploy
diff options
context:
space:
mode:
authorYifei Xue <xueyifei@huawei.com>2017-04-24 11:22:40 +0800
committerYifei Xue <xueyifei@huawei.com>2017-04-24 21:37:19 +0800
commit23f50d5aeda3ff3ab96f17e04df4df7646589c58 (patch)
tree8f4c99f09edf5e8587e40026665ddd73f6ff4556 /deploy
parent494ac5825c5b435d512cc13332e302efd30e2a6c (diff)
tempest test case failed in Functest smoke
JIRA: COMPASS-545 1. LVMISCSIDriver has been removed but LVMVolumeDriver is what actually exists. Updating the LVM driver name in cinder.conf will solve this. 2. Add tgt to cinder-volume's service list 3. Add section of ceph in cinder.conf for cinder backend 4. Add enable_backends in cinder.conf Change-Id: I477d2b17ce9e10871a7b96c1a98a49506b36a6ef Signed-off-by: Yifei Xue <xueyifei@huawei.com>
Diffstat (limited to 'deploy')
-rwxr-xr-xdeploy/adapters/ansible/roles/ceph-openstack/tasks/ceph_openstack_conf.yml42
-rw-r--r--deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf1
-rw-r--r--deploy/adapters/ansible/roles/cinder-volume/templates/cinder.conf5
-rw-r--r--deploy/adapters/ansible/roles/cinder-volume/vars/Debian.yml1
-rw-r--r--deploy/adapters/ansible/roles/cinder-volume/vars/RedHat.yml1
5 files changed, 29 insertions, 21 deletions
diff --git a/deploy/adapters/ansible/roles/ceph-openstack/tasks/ceph_openstack_conf.yml b/deploy/adapters/ansible/roles/ceph-openstack/tasks/ceph_openstack_conf.yml
index 84515267..5d9138bb 100755
--- a/deploy/adapters/ansible/roles/ceph-openstack/tasks/ceph_openstack_conf.yml
+++ b/deploy/adapters/ansible/roles/ceph-openstack/tasks/ceph_openstack_conf.yml
@@ -56,24 +56,30 @@
/etc/cinder/cinder.conf;
sed -i 's/^\(rbd_secret_uuid\).*/\1 = {{ ceph_uuid }}/g' \
/etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a rbd_pool = volumes' \
- /etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a rbd_ceph_conf = /etc/ceph/ceph.conf' \
- /etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a rbd_flatten_volume_from_snapshot = false' \
- /etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a rbd_max_clone_depth = 5' \
- /etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a rbd_store_chunk_size = 4' \
- /etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a rados_connect_timeout = -1' \
- /etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a glance_api_version = 2' \
- /etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a rbd_user = cinder' \
- /etc/cinder/cinder.conf;
- sed -i '/^\[DEFAULT/a rbd_secret_uuid = {{ ceph_uuid }}' \
- /etc/cinder/cinder.conf;
+ crudini --set /etc/cinder/cinder.conf DEFAULT enabled_backends \
+ ceph;
+ crudini --del /etc/cinder/cinder.conf lvm
+ crudini --set /etc/cinder/cinder.conf ceph volume_driver \
+ cinder.volume.drivers.rbd.RBDDriver;
+ crudini --set /etc/cinder/cinder.conf ceph volume_backend_name \
+ ceph;
+ crudini --set /etc/cinder/cinder.conf ceph rbd_pool volumes;
+ crudini --set /etc/cinder/cinder.conf ceph rbd_ceph_conf \
+ /etc/ceph/ceph.conf;
+ crudini --set /etc/cinder/cinder.conf ceph rbd_flatten_volume_from_snapshot \
+ false;
+ crudini --set /etc/cinder/cinder.conf ceph rbd_max_clone_depth \
+ 5;
+ crudini --set /etc/cinder/cinder.conf ceph rbd_store_chunk_size \
+ 4;
+ crudini --set /etc/cinder/cinder.conf ceph rados_connect_timeout \
+ -1;
+ crudini --set /etc/cinder/cinder.conf ceph glance_api_version \
+ 2;
+ crudini --set /etc/cinder/cinder.conf ceph rbd_user \
+ cinder;
+ crudini --set /etc/cinder/cinder.conf ceph rbd_secret_uuid \
+ {{ ceph_uuid }};
when: inventory_hostname in groups['compute']
tags:
- ceph_conf_cinder
diff --git a/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf b/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf
index 4ad2da2e..25d3cdd9 100644
--- a/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf
+++ b/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf
@@ -51,7 +51,6 @@ iscsi_port = 3260
iscsi_helper = tgtadm
volumes_dir = /var/lib/cinder/volumes
-volume_driver = cinder.volume.drivers.lvm.LVMISCSIDriver
[database]
connection = mysql://cinder:{{ CINDER_DBPASS }}@{{ db_host }}/cinder
diff --git a/deploy/adapters/ansible/roles/cinder-volume/templates/cinder.conf b/deploy/adapters/ansible/roles/cinder-volume/templates/cinder.conf
index e7946b5c..9a5ca005 100644
--- a/deploy/adapters/ansible/roles/cinder-volume/templates/cinder.conf
+++ b/deploy/adapters/ansible/roles/cinder-volume/templates/cinder.conf
@@ -17,6 +17,8 @@ control_exchange = cinder
rpc_backend = rabbit
my_ip = {{ storage_controller_host }}
+enabled_backends = lvm
+
glance_host = {{ internal_vip.ip }}
glance_port = 9292
glance_api_servers = http://{{ internal_vip.ip }}:9292
@@ -44,7 +46,6 @@ iscsi_port=3260
iscsi_helper=tgtadm
volumes_dir=/var/lib/cinder/volumes
-volume_driver=cinder.volume.drivers.lvm.LVMISCSIDriver
[database]
connection = mysql://cinder:{{ CINDER_DBPASS }}@{{ db_host }}/cinder
@@ -67,7 +68,7 @@ admin_password = {{ CINDER_PASS }}
[lvm]
volume_driver = cinder.volume.drivers.lvm.LVMVolumeDriver
-volume_group = cinder-volumes
+volume_group = storage-volumes
iscsi_protocol = iscsi
iscsi_helper = tgtadm
diff --git a/deploy/adapters/ansible/roles/cinder-volume/vars/Debian.yml b/deploy/adapters/ansible/roles/cinder-volume/vars/Debian.yml
index d95b779c..8c3cb728 100644
--- a/deploy/adapters/ansible/roles/cinder-volume/vars/Debian.yml
+++ b/deploy/adapters/ansible/roles/cinder-volume/vars/Debian.yml
@@ -12,3 +12,4 @@ packages:
services:
- cinder-volume
+ - tgt
diff --git a/deploy/adapters/ansible/roles/cinder-volume/vars/RedHat.yml b/deploy/adapters/ansible/roles/cinder-volume/vars/RedHat.yml
index 6d596f4b..892c66d8 100644
--- a/deploy/adapters/ansible/roles/cinder-volume/vars/RedHat.yml
+++ b/deploy/adapters/ansible/roles/cinder-volume/vars/RedHat.yml
@@ -17,3 +17,4 @@ packages:
services:
- openstack-cinder-volume
- lvm2-lvmetad
+ - target