Skip to content

Commit

Permalink
Fix cinder
Browse files Browse the repository at this point in the history
  • Loading branch information
dmi-try committed Apr 3, 2013
1 parent 2a794b3 commit 678e159
Show file tree
Hide file tree
Showing 9 changed files with 33 additions and 23 deletions.
4 changes: 2 additions & 2 deletions deployment/puppet/openstack/examples/site.pp
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
$network_manager = 'nova.network.manager.FlatDHCPManager'

# Setup network interface, which Cinder used for export iSCSI targets.
$cinder_iscsi_bind_iface = $internal_interface
$cinder_iscsi_bind_addr = $internal_address

# Here you can add physical volumes to cinder. Please replace values with the actual names of devices.
$nv_physical_volume = ['/dev/sdz', '/dev/sdy', '/dev/sdx']
Expand Down Expand Up @@ -198,7 +198,7 @@
tenant_network_type => $tenant_network_type,
segment_range => $segment_range,
cinder => $cinder,
cinder_iscsi_bind_iface => $cinder_iscsi_bind_iface,
cinder_iscsi_bind_addr => $cinder_iscsi_bind_addr,
galera_nodes => $controller_hostnames,
manage_volumes => $manage_volumes,
nv_physical_volume => $nv_physical_volume,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
$network_manager = 'nova.network.manager.FlatDHCPManager'

# Setup network interface, which Cinder used for export iSCSI targets.
$cinder_iscsi_bind_iface = $internal_interface
$cinder_iscsi_bind_addr = $internal_address

# Here you can add physical volumes to cinder. Please replace values with the actual names of devices.
$nv_physical_volume = ['/dev/sdz', '/dev/sdy', '/dev/sdx']
Expand Down Expand Up @@ -206,7 +206,7 @@
tenant_network_type => $tenant_network_type,
segment_range => $segment_range,
cinder => $cinder,
cinder_iscsi_bind_iface => $cinder_iscsi_bind_iface,
cinder_iscsi_bind_addr => $cinder_iscsi_bind_addr,
manage_volumes => $manage_volumes,
galera_nodes => $controller_hostnames,
nv_physical_volume => $nv_physical_volume,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
$network_manager = 'nova.network.manager.FlatDHCPManager'

# Setup network interface, which Cinder used for export iSCSI targets.
$cinder_iscsi_bind_iface = $internal_interface
$cinder_iscsi_bind_addr = $internal_address

# Here you can add physical volumes to cinder. Please replace values with the actual names of devices.
$nv_physical_volume = ['/dev/sdz', '/dev/sdy', '/dev/sdx']
Expand Down Expand Up @@ -209,7 +209,7 @@
tenant_network_type => $tenant_network_type,
segment_range => $segment_range,
cinder => $cinder,
cinder_iscsi_bind_iface => $cinder_iscsi_bind_iface,
cinder_iscsi_bind_addr => $cinder_iscsi_bind_addr,
manage_volumes => $manage_volumes,
galera_nodes => $controller_hostnames,
nv_physical_volume => $nv_physical_volume,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
$network_manager = 'nova.network.manager.FlatDHCPManager'

# Setup network interface, which Cinder used for export iSCSI targets.
$cinder_iscsi_bind_iface = $internal_interface
$cinder_iscsi_bind_addr = $internal_address

# Here you can add physical volumes to cinder. Please replace values with the actual names of devices.
$nv_physical_volume = ['/dev/sdz', '/dev/sdy', '/dev/sdx']
Expand Down Expand Up @@ -207,7 +207,7 @@
tenant_network_type => $tenant_network_type,
segment_range => $segment_range,
cinder => $cinder,
cinder_iscsi_bind_iface => $cinder_iscsi_bind_iface,
cinder_iscsi_bind_addr => $cinder_iscsi_bind_addr,
manage_volumes => $manage_volumes,
galera_nodes => $controller_hostnames,
nv_physical_volume => $nv_physical_volume,
Expand Down
4 changes: 2 additions & 2 deletions deployment/puppet/openstack/examples/site_simple.pp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
$network_manager = 'nova.network.manager.FlatDHCPManager'

# Setup network interface, which Cinder used for export iSCSI targets.
$cinder_iscsi_bind_iface = $internal_interface
$cinder_iscsi_bind_addr = $internal_address

# Here you can add physical volumes to cinder. Please replace values with the actual names of devices.
$nv_physical_volume = ['/dev/sdz', '/dev/sdy', '/dev/sdx']
Expand Down Expand Up @@ -158,7 +158,7 @@
quantum_db_dbname => $quantum_db_dbname,
tenant_network_type => $tenant_network_type,
cinder => $cinder,
cinder_iscsi_bind_iface => $cinder_iscsi_bind_iface,
cinder_iscsi_bind_addr => $cinder_iscsi_bind_addr,
manage_volumes => $manage_volumes,
nv_physical_volume => $nv_physical_volume,
use_syslog => $use_syslog,
Expand Down
3 changes: 2 additions & 1 deletion deployment/puppet/openstack/manifests/cinder.pp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@

class { 'cinder::volume::iscsi':
iscsi_ip_address => $iscsi_bind_host,
physical_volume => $nv_physical_volume,
physical_volume => $physical_volume,
volume_group => $volume_group,
}
}
}
Expand Down
5 changes: 4 additions & 1 deletion deployment/puppet/openstack/manifests/compute.pp
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@
$verbose = false,
$manage_volumes = false,
$nv_physical_volume = undef,
$cinder_volume_group = 'cinder-volumes',
$cinder_iscsi_bind_addr = false,
$cache_server_ip = ['127.0.0.1'],
$cache_server_port = '11211',
$nova_volume = 'nova-volumes',
Expand Down Expand Up @@ -179,13 +181,14 @@
rabbit_password => $rabbit_password,
rabbit_host => false,
rabbit_nodes => $rabbit_nodes,
volume_group => 'cinder-volumes',
volume_group => $cinder_volume_group,
physical_volume => $nv_physical_volume,
manage_volumes => $manage_volumes,
enabled => true,
auth_host => $service_endpoint,
bind_host => false,
cinder_user_password => $cinder_user_password,
iscsi_bind_host => $cinder_iscsi_bind_addr,
use_syslog => $use_syslog,
cinder_rate_limits => $cinder_rate_limits
}
Expand Down
15 changes: 8 additions & 7 deletions deployment/puppet/openstack/manifests/controller.pp
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,8 @@
$cinder_db_password = 'cinder_db_pass',
$cinder_db_user = 'cinder',
$cinder_db_dbname = 'cinder',
$cinder_iscsi_bind_iface = false,
$cinder_iscsi_bind_addr = false,
$cinder_volume_group = 'cinder-volumes',
#
$quantum = false,
$quantum_user_password = 'quantum_pass',
Expand Down Expand Up @@ -325,23 +326,23 @@

######### Cinder Controller Services ########
if ($cinder) {
if ($cinder_iscsi_bind_iface) {
$cinder_iscsi_bind_addr = getvar("::ipaddress_${cinder_iscsi_bind_iface}")
if ($cinder_iscsi_bind_addr) {
$iscsi_bind_host = $cinder_iscsi_bind_addr
} else {
$cinder_iscsi_bind_addr = $api_bind_address
$iscsi_bind_host = $api_bind_address
}
class {'openstack::cinder':
sql_connection => "mysql://${cinder_db_user}:${cinder_db_password}@${db_host}/${cinder_db_dbname}?charset=utf8",
rabbit_password => $rabbit_password,
rabbit_host => false,
rabbit_nodes => $rabbit_nodes,
volume_group => 'cinder-volumes',
physical_volume => $physical_volume,
physical_volume => $nv_physical_volume,
manage_volumes => $manage_volumes,
enabled => true,
auth_host => $service_endpoint,
bind_host => $api_bind_address,
iscsi_bind_host => $cinder_iscsi_bind_addr,
iscsi_bind_host => $iscsi_bind_host,
volume_group => $cinder_volume_group,
cinder_user_password => $cinder_user_password,
use_syslog => $use_syslog,
cinder_rate_limits => $cinder_rate_limits
Expand Down
13 changes: 9 additions & 4 deletions deployment/puppet/openstack/manifests/controller_ha.pp
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,11 @@
$nova_db_password, $nova_user_password, $rabbit_password, $rabbit_user,
$rabbit_nodes, $memcached_servers, $export_resources, $glance_backend='file', $swift_proxies=undef,
$quantum = false, $quantum_user_password, $quantum_db_password, $quantum_db_user = 'quantum',
$quantum_db_dbname = 'quantum', $cinder = false, $cinder_iscsi_bind_iface = false, $tenant_network_type = 'gre', $segment_range = '1:4094',
$nv_physical_volume = undef, $manage_volumes = false,$galera_nodes, $mysql_skip_name_resolve = false, $use_syslog = false,
$cinder_rate_limits = undef, $nova_rate_limits = undef
$quantum_db_dbname = 'quantum', $cinder = false, $cinder_iscsi_bind_addr = false, $tenant_network_type = 'gre', $segment_range = '1:4094',
$nv_physical_volume = undef, $manage_volumes = false, $cinder_volume_group = 'cinder-volumes', $galera_nodes, $mysql_skip_name_resolve = false,
$use_syslog = false, $cinder_rate_limits = undef, $nova_rate_limits = undef,
$cinder_user_password = 'cinder_user_pass',
$cinder_db_password = 'cinder_db_pass',
) {

$which = $::hostname ? { $master_hostname => 0, default => 1 }
Expand Down Expand Up @@ -290,9 +292,12 @@
segment_range => $segment_range,
tenant_network_type => $tenant_network_type,
cinder => $cinder,
cinder_iscsi_bind_iface => $cinder_iscsi_bind_iface,
cinder_user_password => $cinder_user_password,
cinder_db_password => $cinder_db_password,
cinder_iscsi_bind_addr => $cinder_iscsi_bind_addr,
manage_volumes => $manage_volumes,
nv_physical_volume => $nv_physical_volume,
cinder_volume_group => $cinder_volume_group,
# turn on SWIFT_ENABLED option for Horizon dashboard
swift => $glance_backend ? { 'swift' => true, default => false },
use_syslog => $use_syslog,
Expand Down

0 comments on commit 678e159

Please sign in to comment.