04c1abfeef253fb0dfb5236aebe974aaf5fc5893
[mirror/dsa-puppet.git] / 3rdparty / modules / cinder / README.md
1 cinder
2 =======
3
4 5.1.0 - 2014.2 - Juno
5
6 #### Table of Contents
7
8 1. [Overview - What is the cinder module?](#overview)
9 2. [Module Description - What does the module do?](#module-description)
10 3. [Setup - The basics of getting started with cinder](#setup)
11 4. [Implementation - An under-the-hood peek at what the module is doing](#implementation)
12 5. [Limitations - OS compatibility, etc.](#limitations)
13 6. [Development - Guide for contributing to the module](#development)
14 7. [Contributors - Those with commits](#contributors)
15 8. [Release Notes - Notes on the most recent updates to the module](#release-notes)
16
17 Overview
18 --------
19
20 The cinder module is a part of [Stackforge](https://github.com/stackfoge), an effort by the Openstack infrastructure team to provide continuous integration testing and code review for Openstack and Openstack community projects not part of the core software.  The module its self is used to flexibly configure and manage the block storage service for Openstack.
21
22 Module Description
23 ------------------
24
25 The cinder module is a thorough attempt to make Puppet capable of managing the entirety of cinder.  This includes manifests to provision such things as keystone endpoints, RPC configurations specific to cinder, and database connections.  Types are shipped as part of the cinder module to assist in manipulation of configuration files.
26
27 This module is tested in combination with other modules needed to build and leverage an entire Openstack software stack.  These modules can be found, all pulled together in the [openstack module](https://github.com/stackfoge/puppet-openstack).
28
29 Setup
30 -----
31
32 **What the cinder module affects**
33
34 * cinder, the block storage service for Openstack.
35
36 ### Installing cinder
37
38     puppet module install puppetlabs/cinder
39
40 ### Beginning with cinder
41
42 To utilize the cinder module's functionality you will need to declare multiple resources.  The following is a modified excerpt from the [openstack module](https://github.com/stackfoge/puppet-openstack).  This is not an exhaustive list of all the components needed, we recommend you consult and understand the [openstack module](https://github.com/stackforge/puppet-openstack) and the [core openstack](http://docs.openstack.org) documentation.
43
44 **Define a cinder control node**
45
46 ```puppet
47 class { 'cinder':
48   database_connection     => 'mysql://cinder:secret_block_password@openstack-controller.example.com/cinder',
49   rabbit_password         => 'secret_rpc_password_for_blocks',
50   rabbit_host             => 'openstack-controller.example.com',
51   verbose                 => true,
52 }
53
54 class { 'cinder::api':
55   keystone_password       => $keystone_password,
56   keystone_enabled        => $keystone_enabled,
57   keystone_user           => $keystone_user,
58   keystone_auth_host      => $keystone_auth_host,
59   keystone_auth_port      => $keystone_auth_port,
60   keystone_auth_protocol  => $keystone_auth_protocol,
61   service_port            => $keystone_service_port,
62   package_ensure          => $cinder_api_package_ensure,
63   bind_host               => $cinder_bind_host,
64   enabled                 => $cinder_api_enabled,
65 }
66
67 class { 'cinder::scheduler':
68   scheduler_driver => 'cinder.scheduler.simple.SimpleScheduler',
69 }
70 ```
71
72 **Define a cinder storage node**
73
74 ```puppet
75 class { 'cinder':
76   database_connection     => 'mysql://cinder:secret_block_password@openstack-controller.example.com/cinder',
77   rabbit_password         => 'secret_rpc_password_for_blocks',
78   rabbit_host             => 'openstack-controller.example.com',
79   verbose                 => true,
80 }
81
82 class { 'cinder::volume': }
83
84 class { 'cinder::volume::iscsi':
85   iscsi_ip_address => '10.0.0.2',
86 }
87 ```
88
89 **Define a cinder storage node with multiple backends **
90
91 ```puppet
92 class { 'cinder':
93   database_connection     => 'mysql://cinder:secret_block_password@openstack-controller.example.com/cinder',
94   rabbit_password         => 'secret_rpc_password_for_blocks',
95   rabbit_host             => 'openstack-controller.example.com',
96   verbose                 => true,
97 }
98
99 class { 'cinder::volume': }
100
101 cinder::backend::iscsi {'iscsi1':
102   iscsi_ip_address => '10.0.0.2',
103 }
104
105 cinder::backend::iscsi {'iscsi2':
106   iscsi_ip_address => '10.0.0.3',
107 }
108
109 cinder::backend::iscsi {'iscsi3':
110   iscsi_ip_address    => '10.0.0.4',
111   volume_backend_name => 'iscsi',
112 }
113
114 cinder::backend::iscsi {'iscsi4':
115   iscsi_ip_address    => '10.0.0.5',
116   volume_backend_name => 'iscsi',
117 }
118
119 cinder::backend::rbd {'rbd-images':
120   rbd_pool => 'images',
121   rbd_user => 'images',
122 }
123
124 # Cinder::Type requires keystone credentials
125 Cinder::Type {
126   os_password     => 'admin',
127   os_tenant_name  => 'admin',
128   os_username     => 'admin',
129   os_auth_url     => 'http://127.0.0.1:5000/v2.0/',
130 }
131
132 cinder::type {'iscsi':
133   set_key   => 'volume_backend_name',
134   set_value => ['iscsi1', 'iscsi2', 'iscsi']
135 }
136
137 cinder::type {'rbd':
138   set_key   => 'volume_backend_name',
139   set_value => 'rbd-images',
140 }
141
142 class { 'cinder::backends':
143   enabled_backends => ['iscsi1', 'iscsi2', 'rbd-images']
144 }
145 ```
146
147 Note: that the name passed to any backend resource must be unique accross all backends otherwise a duplicate resource will be defined.
148
149 ** Using type and type_set **
150
151 Cinder allows for the usage of type to set extended information that can be used for various reasons. We have resource provider for ``type`` and ``type_set`` Since types are rarely defined with out also setting attributes with it, the resource for ``type`` can also call ``type_set`` if you pass ``set_key`` and ``set_value``
152
153
154 Implementation
155 --------------
156
157 ### cinder
158
159 cinder is a combination of Puppet manifest and ruby code to delivery configuration and extra functionality through types and providers.
160
161 Limitations
162 ------------
163
164 * Setup of storage nodes is limited to Linux and LVM, i.e. Puppet won't configure a Nexenta appliance but nova can be configured to use the Nexenta driver with Class['cinder::volume::nexenta'].
165
166 Development
167 -----------
168
169 Developer documentation for the entire puppet-openstack project.
170
171 * https://wiki.openstack.org/wiki/Puppet-openstack#Developer_documentation
172
173 Contributors
174 ------------
175
176 * https://github.com/stackforge/puppet-cinder/graphs/contributors
177
178 Release Notes
179 -------------
180
181 **5.1.0**
182
183 * Service Validation for Cinder-API
184 * Automates generation of NFS config file
185 * spec: pin rspec-puppet to 1.0.1
186 * Switch to using the new SolidFire driver name
187 * Makes kombu_ssl_* parameters optional when rabbit_use_ssl => true
188 * Switch to TLSv1
189 * Create type-key only if it doesn't exist
190 * use lioadm on Fedora
191 * Pin puppetlabs-concat to 1.2.1 in fixtures
192 * Add nfs_mount_options variable when backend is NetApp
193 * Change default MySQL collate to utf8_general_ci
194 * Add configuration helpers for Quobyte
195 * Implement HP 3par iscsi backend module
196 * Update .gitreview file for project rename
197
198 **5.0.0**
199
200 * Stable Juno release
201 * Added class to manage policy.json
202 * Changed the default value of the san_thin_provision parameter for eqlx
203 * Added database tuning parameters
204 * Made keystone user creation optional when creating a service
205 * Added ability to hide secrets from logs
206 * Added parameters for netapp and and cinder-api workers
207 * Corrected the package name for cinder backup
208 * Added support for the EMC VNX direct driver
209 * Migrated the mysql backend to use openstacklib::db::mysql
210 * Added support for availability zones
211
212 **4.2.0**
213
214 * Added parameters to set cinder volume driver
215 * Added class for extended logging options
216 * Added option to specify endpoint protocol
217 * Fixed cinder type path issues
218 * Added option to specify cinder volume path
219 * Fixed targetcli package dependency on target service
220 * Fixed os version fact comparison for RedHat-based operating systems
221   for specifying service provider
222 * Added option to configure os_region_name in the cinder config
223
224 **4.1.0**
225
226 * Added Cinder v2 endpoint support.
227 * Added SSL support for Cinder API.
228 * Added RabbitMQ SSL support.
229 * Moved default_volume_type to cinder::api
230 * Removed warnings for existing Cinder volumes.
231 * Pinned major gems.
232
233 **4.0.0**
234
235 * Stable Icehouse release.
236 * Updated NetApp unified driver config options.
237 * Updated support for latest RabbitMQ module.
238 * Added Glance support.
239 * Added GlusterFS driver support.
240 * Added region support.
241 * Added support for MySQL module (>= 2.2).
242 * Added support for Swift and Ceph backup backend.
243 * Added cinder::config to handle additional custom options.
244 * Refactored duplicate code for single and multiple backends.
245 * Removed control exchange flag.
246 * Removed deprecated cinder::base class.
247
248 **3.1.1**
249
250 * Fixed resource duplication bug.
251
252 **3.1.0**
253
254 * Added default_volume_type as a Cinder API parameter.
255 * Added parameter for endpoint procols.
256 * Deprecated glance_api_version.
257 * Added support for VMDK.
258 * Added support for Cinder multi backend.
259 * Added support for https authentication endpoints.
260 * Replaced pip with native package manager (VMDK).
261
262 **3.0.0**
263
264 * Major release for OpenStack Havana.
265 * Added support for SolidFire.
266 * Added support for ceilometer.
267 * Fixed bug for cinder-volume requirement.
268
269 **2.2.0**
270
271 * Added support for rate limiting via api-paste.ini
272 * Added support to configure control_exchange.
273 * Added parameter check to enable or disable db_sync.
274 * Added syslog support.
275 * Added default auth_uri setting for auth token.
276 * Set package defaults to present.
277 * Fixed a bug to create empty init script when necessary.
278 * Various lint fixes.
279
280 **2.1.0**
281
282 * Added configuration of Cinder quotas.
283 * Added support for NetApp direct driver backend.
284 * Added support for ceph backend.
285 * Added support for SQL idle timeout.
286 * Added support for RabbitMQ clustering with single IP.
287 * Fixed allowed_hosts/database connection bug.
288 * Fixed lvm2 setup failure for Ubuntu.
289 * Removed unnecessary mysql::server dependency.
290 * Pinned RabbitMQ and database module versions.
291 * Various lint and bug fixes.
292
293 **2.0.0**
294
295 * Upstream is now part of stackfoge.
296 * Nexenta, NFS, and SAN support added as cinder volume drivers.
297 * Postgres support added.
298 * The Apache Qpid and the RabbitMQ message brokers available as RPC backends.
299 * Configurability of scheduler_driver.
300 * Various cleanups and bug fixes.