diff --git a/chef/cookbooks/openstack-block-storage/recipes/volume.rb b/chef/cookbooks/openstack-block-storage/recipes/volume.rb index 00d08da..7c1e674 100644 --- a/chef/cookbooks/openstack-block-storage/recipes/volume.rb +++ b/chef/cookbooks/openstack-block-storage/recipes/volume.rb @@ -99,7 +99,7 @@ case node["openstack"]["block-storage"]["volume"]["driver"] when "cinder.volume.drivers.lvm.LVMISCSIDriver" package "bc" do - action :install + action :upgrade end openstack_block_storage_volume node["openstack"]["volume"]["disk"] do @@ -109,24 +109,6 @@ case node["openstack"]["block-storage"]["volume"]["driver"] openstack_block_storage_volume node["openstack"]["volume"]["disk"] do action :mk_cinder_vol end - -# template "/tmp/cinder_volumes.sh" do -# source "cinder_volumes.sh.erb" -# owner "root" -# group "root" -# mode 00755 -# variables( -# :volumesize => node["openstack"]["volume"]["size"] -# ) -# notifies :run, "execute[create_cinder_volumes]", :immediately -# only_if { node["openstack"]["volume"]["mode"] == "loopfile" } -# end - -# execute "create_cinder_volumes" do -# command "sh /tmp/cinder_volumes.sh" -# action :run -# only_if { node["openstack"]["volume"]["mode"] == "loopfile" } -# end end service "cinder-volume" do diff --git a/chef/cookbooks/openstack-block-storage/templates/default/cinder_volumes.sh.erb b/chef/cookbooks/openstack-block-storage/templates/default/cinder_volumes.sh.erb deleted file mode 100644 index 08a93d5..0000000 --- a/chef/cookbooks/openstack-block-storage/templates/default/cinder_volumes.sh.erb +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/bash -# This file is going to create a loop file as volume disk. -# -ERRTRAP() -{ - echo "[FILE: "$PWD/$(basename "$(test -L "$0" && readlink "$0" || echo "$0")")", LINE: $1] Error: Command or function exited with status $?" -} - -trap 'ERRTRAP $LINENO' ERR - -vgdisplay |grep cinder-volumes - -if [ $? -ne 0 ]; then - SPACESIZE=$(df -P |grep -vE "^tmpfs|cdrom|tmp" | sed '1d' | awk '{print $4}' | sort -nr | sed -n -e '1{p;q}') - MOUNTPOINT=$(df -P |grep -vE "^tmpfs|cdrom|tmp" | sed '1d' | awk '{print $6}' | sort -nr | sed -n -e '1{p;q}') - G_SPACESIZE=$(echo "$SPACESIZE/1000/1000/2" | bc -l) - echo $G_SPACESIZE - VOLSIZE=${G_SPACESIZE/.*} - echo $VOLSIZE - if [ $VOLSIZE -ge "1" ]; then - dd if=/dev/zero of=$MOUNTPOINT/cinder-volumes bs=1 count=0 seek="$VOLSIZE"G - losetup /dev/loop0 $MOUNTPOINT/cinder-volumes - pvcreate /dev/loop0 - vgcreate cinder-volumes /dev/loop0 - else - echo "The current spare disk space only $SPACESIZE < 1G, no enough disk space is available for the cinder-volume" - exit 0 - fi -fi - diff --git a/chef/cookbooks/openstack-compute/templates/default/nova.conf.erb b/chef/cookbooks/openstack-compute/templates/default/nova.conf.erb index 4845571..bf3f545 100644 --- a/chef/cookbooks/openstack-compute/templates/default/nova.conf.erb +++ b/chef/cookbooks/openstack-compute/templates/default/nova.conf.erb @@ -17,7 +17,7 @@ lock_path=/var/lock/nova ##### RABBITMQ ##### rabbit_userid=<%= node['openstack']['mq']['user'] %> rabbit_password=<%= node['openstack']['mq']['password'] %> -rabbit_virtual_host=<%= node["openstack"]["compute"]["rabbit"]["vhost"] %> +# rabbit_virtual_host=<%= node["openstack"]["compute"]["rabbit"]["vhost"] %> <% if node["openstack"]["compute"]["rabbit"]["ha"] -%> rabbit_hosts=<%= @rabbit_hosts %> rabbit_ha_queues=True diff --git a/chef/cookbooks/openstack-network/templates/default/plugins/openvswitch/ovs_quantum_plugin.ini.erb b/chef/cookbooks/openstack-network/templates/default/plugins/openvswitch/ovs_quantum_plugin.ini.erb index 6c18a76..948991c 100644 --- a/chef/cookbooks/openstack-network/templates/default/plugins/openvswitch/ovs_quantum_plugin.ini.erb +++ b/chef/cookbooks/openstack-network/templates/default/plugins/openvswitch/ovs_quantum_plugin.ini.erb @@ -18,10 +18,12 @@ reconnect_interval = 2 # Minimum number of SQL connections to keep open in a pool # sql_min_pool_size = 1 # Maximum number of SQL connections to keep open in a pool -sql_max_pool_size = 30 +sql_max_pool_size = 100 # Timeout in seconds before idle sql connections are reaped # sql_idle_timeout = 3600 +sqlalchemy_pool_size = 100 + [OVS] # (StrOpt) Type of network to allocate for tenant networks. The # default value 'local' is useful only for single-box testing and diff --git a/chef/cookbooks/openstack-network/templates/default/quantum.conf.erb b/chef/cookbooks/openstack-network/templates/default/quantum.conf.erb index 09a703c..4a98f68 100644 --- a/chef/cookbooks/openstack-network/templates/default/quantum.conf.erb +++ b/chef/cookbooks/openstack-network/templates/default/quantum.conf.erb @@ -329,6 +329,5 @@ signing_dir = <%= node["openstack"]["network"]["api"]["agent"]["signing_dir"] %> # =========== end of items for agent management extension ===== [database] -sql_max_pool_size=30 - -#sqlalchemy_pool_size = 30 +#sql_max_pool_size=100 +#sqlalchemy_pool_size = 100