aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRyan Hefner <ryan.hefner@netapp.com>2015-05-12 13:52:43 -0400
committerRyan Hefner <ryan.hefner@netapp.com>2015-06-05 10:03:10 -0400
commitcac21c27aa11dd2c5c6b178ab8d16eadf5483760 (patch)
tree61088981c75026397ac3aa5418ea7be220f865a0
parent49639ec8a1335fc6bc45ff9ceb88e4ad5753802d (diff)
Enable NetApp Backends in Cinder
Enables support for configuring Cinder with a NetApp backend. This change adds all relevant parameters for: - Clustered Data ONTAP (NFS, iSCSI, FC) - Data ONTAP 7-Mode (NFS, iSCSI, FC) - E-Series (iSCSI) Change-Id: If6c6e511ef2d26c4794e3b37c61e5318485ff4db
-rw-r--r--environments/cinder-netapp-config.yaml30
-rw-r--r--extraconfig/controller/cinder-netapp.yaml38
-rw-r--r--extraconfig/controller/noop.yaml3
-rw-r--r--overcloud-resource-registry-puppet.yaml3
-rw-r--r--puppet/controller-puppet.yaml7
-rw-r--r--puppet/manifests/overcloud_controller.pp18
-rw-r--r--puppet/manifests/overcloud_controller_pacemaker.pp18
7 files changed, 115 insertions, 2 deletions
diff --git a/environments/cinder-netapp-config.yaml b/environments/cinder-netapp-config.yaml
new file mode 100644
index 00000000..4dd9eed7
--- /dev/null
+++ b/environments/cinder-netapp-config.yaml
@@ -0,0 +1,30 @@
+# A Heat environment file which can be used to enable a
+# a Cinder NetApp backend.
+resource_registry:
+ OS::TripleO::Controller::CinderBackend: extraconfig/controller/cinder-netapp.yaml
+
+parameter_defaults:
+ CinderBackendConfig:
+ CinderEnableNetappBackend: false
+ CinderNetappBackendName: 'tripleo_netapp'
+ CinderNetappLogin: ''
+ CinderNetappPassword: ''
+ CinderNetappServerHostname: ''
+ CinderNetappServerPort: '80'
+ CinderNetappSizeMultiplier: '1.2'
+ CinderNetappStorageFamily: 'ontap_cluster'
+ CinderNetappStorageProtocol: 'nfs'
+ CinderNetappTransportType: 'http'
+ CinderNetappVfiler: ''
+ CinderNetappVolumeList: ''
+ CinderNetappVserver: ''
+ CinderNetappPartnerBackendName: ''
+ CinderNetappNfsShares: ''
+ CinderNetappNfsSharesConfig: '/etc/cinder/shares.conf'
+ CinderNetappNfsMountOptions: ''
+ CinderNetappCopyOffloadToolPath: ''
+ CinderNetappControllerIps: ''
+ CinderNetappSaPassword: ''
+ CinderNetappStoragePools: ''
+ CinderNetappEseriesHostType: 'linux_dm_mp'
+ CinderNetappWebservicePath: '/devmgr/v2'
diff --git a/extraconfig/controller/cinder-netapp.yaml b/extraconfig/controller/cinder-netapp.yaml
new file mode 100644
index 00000000..223ceacd
--- /dev/null
+++ b/extraconfig/controller/cinder-netapp.yaml
@@ -0,0 +1,38 @@
+heat_template_version: 2015-04-30
+
+description: >
+ Configure hieradata for Cinder Netapp configuration
+
+resources:
+ CinderNetappConfig:
+ type: OS::Heat::StructuredConfig
+ properties:
+ group: os-apply-config
+ config:
+ hiera:
+ datafiles:
+ cinder_netapp_data:
+ mapped_data:
+ cinder_enable_netapp_backend: {get_param: CinderEnableNetappBackend}
+ cinder::backend::netapp::title: {get_param: CinderNetappBackendName}
+ cinder::backend::netapp::netapp_login: {get_param: CinderNetappLogin}
+ cinder::backend::netapp::netapp_password: {get_param: CinderNetappPassword}
+ cinder::backend::netapp::netapp_hostname: {get_param: CinderNetappServerHostname}
+ cinder::backend::netapp::netapp_server_port: {get_param: CinderNetappServerPort}
+ cinder::backend::netapp::netapp_size_multiplier: {get_param: CinderNetappSizeMultiplier}
+ cinder::backend::netapp::netapp_storage_family: {get_param: CinderNetappStorageFamily}
+ cinder::backend::netapp::netapp_storage_protocol: {get_param: CinderNetappStorageProtocol}
+ cinder::backend::netapp::netapp_transport_type: {get_param: CinderNetappTransportType}
+ cinder::backend::netapp::netapp_vfiler: {get_param: CinderNetappVfiler}
+ cinder::backend::netapp::netapp_volume_list: {get_param: CinderNetappVolumeList}
+ cinder::backend::netapp::netapp_vserver: {get_param: CinderNetappVserver}
+ cinder::backend::netapp::netapp_partner_backend_name: {get_param: CinderNetappPartnerBackendName}
+ cinder::backend::netapp::nfs_shares: {get_param: CinderNetappNfsShares}
+ cinder::backend::netapp::nfs_shares_config: {get_param: CinderNetappNfsSharesConfig}
+ cinder::backend::netapp::nfs_mount_options: {get_param: CinderNetappNfsMountOptions}
+ cinder::backend::netapp::netapp_copyoffload_tool_path: {get_param: CinderNetappCopyOffloadToolPath}
+ cinder::backend::netapp::netapp_controller_ips: {get_param: CinderNetappControllerIps}
+ cinder::backend::netapp::netapp_sa_password: {get_param: CinderNetappSaPassword}
+ cinder::backend::netapp::netapp_storage_pools: {get_param: CinderNetappStoragePools}
+ cinder::backend::netapp::netapp_eseries_host_type: {get_param: CinderNetappEseriesHostType}
+ cinder::backend::netapp::netapp_webservice_path: {get_param: CinderNetappWebservicePath}
diff --git a/extraconfig/controller/noop.yaml b/extraconfig/controller/noop.yaml
new file mode 100644
index 00000000..2eb35763
--- /dev/null
+++ b/extraconfig/controller/noop.yaml
@@ -0,0 +1,3 @@
+heat_template_version: 2015-04-30
+
+description: A stack which doesn't configure anything.
diff --git a/overcloud-resource-registry-puppet.yaml b/overcloud-resource-registry-puppet.yaml
index b7e0c1f8..81a46cfd 100644
--- a/overcloud-resource-registry-puppet.yaml
+++ b/overcloud-resource-registry-puppet.yaml
@@ -64,5 +64,8 @@ resource_registry:
OS::TripleO::BlockStorage::Ports::StoragePort: network/ports/noop.yaml
OS::TripleO::BlockStorage::Ports::StorageMgmtPort: network/ports/noop.yaml
+ # Cinder backend config for the controller role
+ OS::TripleO::Controller::CinderBackend: extraconfig/controller/noop.yaml
+
parameter_defaults:
EnablePackageInstall: false
diff --git a/puppet/controller-puppet.yaml b/puppet/controller-puppet.yaml
index a3fbe780..2ed437fa 100644
--- a/puppet/controller-puppet.yaml
+++ b/puppet/controller-puppet.yaml
@@ -49,6 +49,11 @@ parameters:
description: The password for the cinder service and db account, used by cinder-api.
type: string
hidden: true
+ CinderBackendConfig:
+ default: {}
+ description: Contains parameters to configure Cinder backends. Typically
+ set via parameter_defaults in the resource registry.
+ type: json
CloudName:
default: ''
description: The DNS name of this cloud. E.g. ci-overcloud.tripleo.org
@@ -564,6 +569,7 @@ resources:
cinder_password: {get_param: CinderPassword}
cinder_enable_iscsi_backend: {get_param: CinderEnableIscsiBackend}
cinder_iscsi_helper: {get_param: CinderISCSIHelper}
+ cinder_backend_config: {get_param: CinderBackendConfig}
cinder_dsn:
list_join:
- ''
@@ -811,6 +817,7 @@ resources:
cinder::debug: {get_input: debug}
cinder_enable_iscsi_backend: {get_input: cinder_enable_iscsi_backend}
cinder::glance::glance_api_servers: {get_input: glance_api_servers}
+ cinder_backend_config: {get_input: CinderBackendConfig}
# Glance
glance::api::bind_port: {get_input: glance_port}
diff --git a/puppet/manifests/overcloud_controller.pp b/puppet/manifests/overcloud_controller.pp
index 7070e05c..eed0319e 100644
--- a/puppet/manifests/overcloud_controller.pp
+++ b/puppet/manifests/overcloud_controller.pp
@@ -335,7 +335,23 @@ if hiera('step') >= 3 {
}
}
- $cinder_enabled_backends = delete_undef_values([$cinder_iscsi_backend, $cinder_rbd_backend])
+ if hiera('cinder_enable_netapp_backend', false) {
+ $cinder_netapp_backend = hiera('cinder::backend::netapp::title')
+
+ cinder_config {
+ "${cinder_netapp_backend}/host": value => 'hostgroup';
+ }
+
+ if hiera('cinder_netapp_nfs_shares', undef) {
+ $cinder_netapp_nfs_shares = split(hiera('cinder_netapp_nfs_shares', undef), ',')
+ }
+
+ cinder::backend::netapp { $cinder_netapp_backend :
+ nfs_shares => $cinder_netapp_nfs_shares,
+ }
+ }
+
+ $cinder_enabled_backends = delete_undef_values([$cinder_iscsi_backend, $cinder_rbd_backend, $cinder_netapp_backend])
class { '::cinder::backends' :
enabled_backends => $cinder_enabled_backends,
}
diff --git a/puppet/manifests/overcloud_controller_pacemaker.pp b/puppet/manifests/overcloud_controller_pacemaker.pp
index ac05c367..bdd6574d 100644
--- a/puppet/manifests/overcloud_controller_pacemaker.pp
+++ b/puppet/manifests/overcloud_controller_pacemaker.pp
@@ -574,7 +574,23 @@ if hiera('step') >= 3 {
}
}
- $cinder_enabled_backends = delete_undef_values([$cinder_iscsi_backend, $cinder_rbd_backend])
+ if hiera('cinder_enable_netapp_backend', false) {
+ $cinder_netapp_backend = hiera('cinder::backend::netapp::title')
+
+ cinder_config {
+ "${cinder_netapp_backend}/host": value => 'hostgroup';
+ }
+
+ if hiera('cinder_netapp_nfs_shares', undef) {
+ $cinder_netapp_nfs_shares = split(hiera('cinder_netapp_nfs_shares', undef), ',')
+ }
+
+ cinder::backend::netapp { $cinder_netapp_backend :
+ nfs_shares => $cinder_netapp_nfs_shares,
+ }
+ }
+
+ $cinder_enabled_backends = delete_undef_values([$cinder_iscsi_backend, $cinder_rbd_backend, $cinder_netapp_backend])
class { '::cinder::backends' :
enabled_backends => $cinder_enabled_backends,
}