Kurt Martin [Tue, 6 Aug 2013 20:25:36 +0000 (13:25 -0700)]
3PAR volumes created from snaps failed to attach
An error would occur if you attempted to attach a volume that
was created from a snapshot. The 3PAR backends does not have a
'userCPG' entry in the volume data on the backend, it instead
has a 'snapCPG' field. This patch will now look for the 'snapCPG'
entry and use that CPG when attaching the volume created from a
snapshot.
John Griffith [Tue, 6 Aug 2013 20:58:02 +0000 (14:58 -0600)]
Move volume_clear and clear_size opts up to driver
The block_device driver pulled in the clear and clear_size
options for it's own use and broke the inheritance model needed
for multiple backend configs.
This change moves the two configs up higher in the heirarchy to
driver.py so that it can be shared/used by all drivers if they desire.
This means that they are now set properly in volume_opts. At some
point we shoudl restructure this a bit to allow multi-backends to
specify independent settings for these configs.
Kurt Martin [Mon, 5 Aug 2013 21:23:52 +0000 (14:23 -0700)]
Set the concurrent connections on the 3PAR array
Currently, the 3PAR backend has a limit to the number of concurrent
connections that can be made to the WS API Server. This patch is
setting this limit to 15 connections, the highest possible.
Joel Coffman [Tue, 30 Jul 2013 14:06:28 +0000 (10:06 -0400)]
Create key manager interface
This interface provides a thin wrapper around an underlying key
management implementation such as Barbican or a KMIP server. The key
manager interface is used by the volume encryption code to retrieve
keys for volumes.
This change is a copy-paste of the key manager interface accepted by
Nova. The major modifications are to the module imports (i.e.,
nova -> cinder).
The RBD driver supports two methods of image cloning;
thin copy i.e. copy-on-write (requires v2 Glance API)
and full copy (default if v2 Glance API is not available).
clone_image() was failing in the Glance V1 API case because
it was not returning a tuple, as expected by the volume
manager. Glance V2 support works fine.
Bill Owen [Mon, 5 Aug 2013 18:32:27 +0000 (11:32 -0700)]
GPFS Verify min release level for mmclone command
The gpfs driver makes heavy use of mmclone command. This command
was added fairly recently. Verify that the GPFS cluster is operating
at a level that supports mmclone at startup during prerequisite
checking in check_for_setup_error.
Need to verify:
1. That gpfs cluster is at required level
2. That filesystem(s) are also operating at required level.
Luis A. Garcia [Tue, 23 Jul 2013 18:53:38 +0000 (18:53 +0000)]
Sync gettextutils from oslo
The oslo changes necessary for delayed translation were refactored in
oslo. This patch set brings in the refactored changes, implemented
under the same change-id mentioned below.
Kurt Martin [Wed, 31 Jul 2013 20:56:29 +0000 (13:56 -0700)]
Remove unnecessary metadata from the 3PAR drivers
Currently, both the HP 3PAR iSCSI and FC drivers are populating
the volume and snapshot metadata field with unnecessary data that
should actually be stored on the backend. This data should not be
accessible by the user which it is today and could be updated as well.
This patch will remove all custom 3PAR data from the metadata fields.
Kurt Martin [Fri, 2 Aug 2013 22:06:31 +0000 (15:06 -0700)]
Add new persona value in the 3PAR driver
A new persona type, '12 - OpenVMS' was added to the list of valid
personas in the 3PAR drivers. This persona was introduced in the
3.1.2 MU2 firmware update on the 3PAR storage array.
This patch includes bumping the driver versions for both
Fibre Channel and iSCSI to 1.1. Included a history change
that describes the changes since 1.0.
This patch also changes the way we do clone volume. We no
longer have to check the status of the volume clone on the 3par
as it's instantly done now since 3.1.2 MU2 firmware.
Roman Podolyaka [Wed, 24 Jul 2013 14:13:07 +0000 (17:13 +0300)]
Call get_session() only when necessary
A Session instance should be retrieved only when it's
really needed, e. g. to make a few DB queries inside a
single transaction or to pass the session to a private
DB API method, etc. At the same time, many queries are
simple and can be expressed by the means of auxiliary
model_query() function.
Roman Podolyaka [Wed, 24 Jul 2013 13:37:48 +0000 (16:37 +0300)]
Fix volume_create()/snapshot_create() DB methods
volume_create() and snapshot_create() DB API methods create
entities and return information about them by calling
_volume_get() and snapshot_get() methods. There is no need
to create a new transaction to call the corresponding 'getter'.
Unfortunately, fixing this breaks two existing tests, which rely
on the current behaviour of these DB API methods: both volume_create()
and snapshot_create() raise exceptions, nevertheless new entities are
created.
Roman Podolyaka [Mon, 22 Jul 2013 15:27:51 +0000 (18:27 +0300)]
Execute DB API methods in a single transaction
Many DB API methods do a few queries to a DB (e. g. SELECT
and then UPDATE, or SELECT and then DELETE, etc). By default,
a Session instance is used with autocommit=True, which means,
that each query to a DB is done in a separate transaction. This
is error-prone (as it may lead to race conditions or returning
of unexpected results) and makes rollbacks harder (if one of
transactions fail, the previous ones can not be rolled back).
This patch ensures that all DB API methods, which do a few
queries (or call private DB API methods), are executed inside
a single transaction.
Pop out 'offset' and 'limit' before use for filter
In previous code of _items() from api/v{1,2}/snapshots.py,
and also the _items)_ from api/v1/volume.py.we didn't pop
out the 'offset' and 'limit' fields from HTTP get params
before we use such params for filter.This is the root cause
for bug #1205956
For non-admin user, since 'offset' and 'limit' is not in the
allowed_search_options, so the volumes.remove_invalid_options
will help to filter them out. As a result, it walks around this
bug.
But for admin user,the volumes.remove_invalid_options will not
try to filter the search_options.So for admin user, the 'limit'
will appear in search_options, then obviously get no result.
Roman Podolyaka [Fri, 26 Jul 2013 15:44:19 +0000 (18:44 +0300)]
Fix running of migrations tests by Jenkins gate
DB schema migrations tests are always skipped for MySQL
and PostgreSQL backends, when running gate jobs. This is
due to the bug in the function, which checks, if given DB
backend is available.
Update Cinder rootwrap to the latest from oslo-incubator. This allows
to import the latest filters and bugfixes, in preparation for the
havana release.
All the changes are coming directly from the Oslo "rootwrap" module
sync.
Make unicode-to-utf8 conversion universal in ceph backup driver.
librbd does not like unicode strings. A patch was
recently applied (c98cf2d8) to make all config
values utf8 but there are other areas of the ceph
backup driver where this also applies. This patch
adds a new method which converts strings to utf8
and replaces all relevant uses of str() with this
new conversion.
John Griffith [Mon, 29 Jul 2013 15:11:35 +0000 (09:11 -0600)]
Add more info to delete error message.
Our cases for what we allow delete on are limited, this is
fine, however we should log the status of a volume that we
are unable to delete so there's some feed-back as to exactly
why the delete call failed.
Tom Fifield [Sun, 28 Jul 2013 19:07:49 +0000 (12:07 -0700)]
Update references with new Mailing List location
Yesterday, openstack@lists.launchpad.org was migrated with
all users to openstack@list.openstack.org.
This patch updates references to the old mailing list with the
new, to ensure that people encountering them don't accidentally
try and join the old list!
Currently the brick code raises exceptions if it cannot determine the
initiator name or FC HBA information. This patch makes this information
optional, as Nova does.