From e5d3ebef36c73a8bcbad3d0236bdb663809033ea Mon Sep 17 00:00:00 2001 From: liyuenan Date: Fri, 20 Jan 2017 13:15:00 +0800 Subject: FIX access database failed JIRA: COMPASS-521 Number of separate API worker processes for service. The default is calculated by the number of CPUs available for best performance. But some pods have many CPUs, so that some service API worker processes is too many to access database. For example, huawei-pod2 has 47 CPUs, nova-api has 98 processes, cinder-api has 50 processes and heat-api has 33 processes, when aodh want to initialize the database, mysql can not deal with this processes. Change-Id: I00513883ff55cc28cd676c3085615aaac36eb744 Signed-off-by: liyuenan --- deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf | 3 +++ 1 file changed, 3 insertions(+) (limited to 'deploy/adapters/ansible/roles/cinder-controller/templates') diff --git a/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf b/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf index d428a078..05a1c8fd 100644 --- a/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf +++ b/deploy/adapters/ansible/roles/cinder-controller/templates/cinder.conf @@ -35,6 +35,9 @@ quota_driver = cinder.quota.DbQuotaDriver osapi_volume_listen = {{ storage_controller_host }} osapi_volume_listen_port = 8776 +{% if ansible_processor_vcpus > 30 %} +osapi_volume_workers = 30 +{% endif %} db_backend = sqlalchemy volume_name_template = volume-%s -- cgit 1.2.3-korg