Nilesh Bhosale [Fri, 27 Dec 2013 03:32:56 +0000 (09:02 +0530)]
Driver for IBM SONAS and Storwize V7000 Unified
The IBM NAS Driver currently implemented to work over NFS protocol,
and implements required set of features for OpenStack Icehouse release,
using the features of these storage products. It allows IBM® SONAS®
and Storwize® V7000 Unified filers to host storage for OpenStack
environment by integrating with Openstack Cinder service.
Creating FC connections was not working due to several issues:
1. The lsfabric command in the Storwize/SVC omitted the delimeter and so
the output was not correctly parsed by the driver.
2. In some cases comparisons of WWPNs were not case insensitive - ensure
we compare lower-case WWPNs.
3. If the host supplied extra information in the connector (e.g. iSCSI
initiator name in case of an FC setup, or FC WWNNs/WWPNs in an iSCSI
setup), the driver would try to make those host mappings on the storage
too. This could lead into unwanted behaviour and confusing error
messages (for example, in an FC setup reaching the maximum number of
iSCSI mappings).
In addition, unit tests weren't properly testing FC - instead they were
always testing iSCSI due to an error in parsing extra_specs. This patch
fixes that error and the unit tests as well.
These changes must all be made together for unit tests to pass.
Avishay Traeger [Thu, 20 Feb 2014 11:22:37 +0000 (13:22 +0200)]
Ensure return for db api functions
Functions in db/api.py should return whatever the implementation of
those functions return. This is important for qos_specs_update which
returns something for the sqlalchemy implementation, but for others as
well for future implementations.
Added 'return' for functions that were missing it.
Jim Branen [Sat, 15 Feb 2014 00:02:55 +0000 (16:02 -0800)]
HP LeftHand Backend assisted volume migrate
This patch implements volume migrate using native LeftHand APIs.
Limitations:
1. Same LeftHand backend
2. Volume cannot be attached
3. Volumes with snapshots cannot be migrated
4. Source and Destination clusters must be in the same management group
5. Volume re-type not supported
Kurt Martin [Wed, 12 Feb 2014 01:38:13 +0000 (17:38 -0800)]
Add support for qos_specs feature to 3PAR drivers
This patch includes the ability to set the qos-specs for the
existing 3PAR qos settings (maxIOP and maxBWS) in addition to
the new settingis listed below. We would prefer that the
new qos-specs associated to a volume type be used, but this
patch also supports setting these values the old way in extra-specs
for backwards compatibility.
This patch also adds two additional personas to the list of
valid personas that are now support by the 3PAR backends.
DocImpact: Implements new qos settings
minIOPS - The minimum IOPs per second
minBWS - The minimum bandwidth per second
latency - The QOS I/O target latency
priority - The QOS scheduling priority (high, normal, low)
The priority defaults to normal
Two new personas added include HPUX and WindowsServer
This patch updates both the HP 3PAR Fibre Channel
and HP 3PAR iSCSI block storage drivers so that they
can pass the driver certification tests. We also updated
the unit tests to use mock instead of mox.
These versions of the drivers require the new 3.0.0 hp3parclient,
which can be downloaded from the pypi repository:
https://pypi.python.org/pypi/hp3parclient
The new hp3parclient requires the 3.1.3 firmware on the HP 3PAR.
The driver certification results:
Related-Bug: #1278575
Related-Bug: #1278577
Andrew Kerr [Tue, 18 Feb 2014 22:38:12 +0000 (17:38 -0500)]
Ensures NetApp iSCSI driver correctly compares int values for size
The NetApp iSCSI driver needs to verify that the new size requested
during an extend operation does not exceed the max_resize of the
lun. However, the driver was doing a >= compare against str values
of the sizes rather than the int values. This caused the incorrect
code path to be used in certain situations.
Chris Buccella [Sat, 15 Feb 2014 02:29:43 +0000 (02:29 +0000)]
Sync request_id, request_utils for cinder
This is in preparation for work being done on request ID tracing across
OpenStack services.
Per discussion in blueprint cross-service-request-id , the standard header
name for the request ID across OpenStack projects should be
x-openstack-request-id. The request_id middleware was created for just this
purpose, as oslo change Ic7967cd62e7b743343d70f751b9238339171e013 . Using the
same middleware allows for consistency across projects.
There is an additional oslo module, request_utils, introduced as
change Id085c4444fee2bb68b80738bfe77ccb0ba1908ec to allow uniform logging of
request IDs. Bring that in as well so we have it when necessary.
This commit adds a new versioned api to the backup driver base
class which all backup driver implementations should use in order
to support backing up volume metadata as well as data. The general
rule here is that we backup all metadata from a set of db tables
and can then be selective about what we restore.
As part of this commit, Ceph backup driver implements the new api
to backup volume metadata (including glance metadata) thus
supporting restoring volumes as bootable.
It is expected that the other backup driver implementations will
follow suit and adopt this approach.
Xing Yang [Tue, 11 Feb 2014 05:00:53 +0000 (00:00 -0500)]
Add EMC SMI-S FC Driver in Cinder
Add an EMC SMI-S FC Driver in Cinder. It supports all required
driver features.
Also made enhancements to the existing SMI-S iSCSI Driver
(performance enhancement, multiple pool support and thick/thin
provisioning, extend volume).
emc_smis_common.py is the common code used by both iSCSI driver
(emc_smis_iscsi.py) and FC driver (emc_smis_fc.py).
john-griffith [Mon, 10 Feb 2014 21:42:43 +0000 (14:42 -0700)]
Check type argument on create from source and snap
Currently the create from snap and create from source
options will set the volume-type when specified in the
create call.
This is actually wrong, because clone and create from snap
MUST be performed on the same backend as the parent volume. The
result is that if the specified type doesn't match the specs for
it's parent, and actually needs to be on a different backend
the new volume will "appear" to have the correct type, but it's
actually invalid.
The --volume-type argument should be rejected when --source-volid
or --snapshot-id are used, and the parent type-id just picked up
and used. Then the user can retype if desired.
Auto failing this strictly causes backward compatability issues though
so we'll just check for a mismatch and raise an exception in that case.
This way if the user knows what they're doing and they're explicit
in the command we still allow it and things are fine.
ling-yun [Wed, 12 Feb 2014 02:02:54 +0000 (10:02 +0800)]
Removed unused context in _extend_snapshot method
Input parameter 'context' of _extend_snapshot method in
cinder/api/extended_snapshot_attributes.py is not being used, so remove
this 'context' parameter.
Avishay Traeger [Tue, 11 Feb 2014 20:34:24 +0000 (22:34 +0200)]
Storwize/SVC: Check wwpn not None
If the storage doesn't have WWPN information for a host but gets it in
the connector, initialize_connection can fail because it does
wwpn.lower(), and wwpn can be None. Make sure it isn't before calling
lower().
Glenn M. Gobeli [Tue, 11 Feb 2014 18:03:13 +0000 (13:03 -0500)]
Changes to cast variable as integer as XML API fails.
Code change to ensure that the type of the size variable is correct
when cinder is invoked through XML API. The extend volume code path
differs from volume create where the flow portion verifies that the
size variable is an integer; for extend the earliest place to cast
the size variable is in volume_actions.py.
Ann Kamyshnikova [Tue, 27 Aug 2013 12:17:25 +0000 (16:17 +0400)]
Move create_, remove_ and ensure_export from drivers
create_export, remove_export, ensure_export are almost the same in
LVM and BlockDevice drivers. So they should be moved to
a common cinder.volume.iscsi module.
Jim Branen [Tue, 7 Jan 2014 00:14:35 +0000 (16:14 -0800)]
New HP LeftHand array iSCSI driver
This driver is intended to replace the current OpenStack Block
Storage HP LeftHand (LH) StoreVirtual iSCSI Driver,
(cinder.volume.drivers.san.HpSanISCSIDriver), by moving the
existing SSH interface into the new driver to maintain backwards
compatibility, and add the new LH REST interface for new driver
features.
We have the driver broken into 3 files:
hp_lefthand_iscis.py (common interface)
hp_lefthand_cliq_proxy.py (old SSH interface)
hp_lefthand_rest_proxy.py (new REST interface)
The reason we are doing this is because the SSH interface on LH
array has connections and performance limitations. These problems
will be resolved by moving to the new LH OS REST interface. Also,
new LeftHand array capabilities will only be supported in the
REST(hplefthandclient) interface.
To support new driver capabilities (create cloned volume), the
python REST client (hplefthandclient) is required and can be
downloaded from the pypi repository:
http://pypi.python.org/pypi/hplefthandclient.
This REST client requires LeftHand firmware version 11.5 or
greater.
Florent Flament [Fri, 17 Jan 2014 10:54:27 +0000 (10:54 +0000)]
Allow operators to customize max header size
HTTP messages max header line size has been increased from 8K to 16K
by default to allow using tokens including up to 14-15 catalog
entries. The same issue
(https://bugs.launchpad.net/swift/+bug/1190149) may occur again in
the future, if keystone's catalog grows further.
Allowing operators to customize the max header size, will allow them
to have Cinder working whatever the size of the catalog (if the option
is properly set).
It appears that there are certain cases where a detach
and a delete call can overlap causing a race in the
remove_iscsi_target method. The result is that when
the slower method gets around to the final removal of
the persistence file it's no longer there, so we
hit an unhandled exception.
This patch does two things:
1. It adds the volume lock to the detach_volume
method in the manager (already in place for delete).
This should mitigate the race and allow us to avoid it.
2. In the iscsi_remove_target method check if the
persist file has already been removed when we get
to the last check. The fact is that if it was somehow
removed before we got here we don't really care, we're
just going to delete it anyway.
Jeremy Stanley [Mon, 10 Feb 2014 02:57:24 +0000 (02:57 +0000)]
Remove tox locale overrides
* tox.ini: The LANG, LANGUAGE and LC_ALL environment overrides were
introduced originally during the testr migration in an attempt to be
conservative about the possibility that locale settings in the
calling environment could cause consistency problems for test runs.
In actuality, this should be unnecessary and any place where it does
cause issues ought to be considered an actual bug. Also, having
these in the configuration actively causes older pip to have
problems with non-ASCII content in some package metadata files under
Python 3, so drop it now.
Avishay Traeger [Sat, 8 Feb 2014 20:59:58 +0000 (22:59 +0200)]
Storwize/SVC: Fix races in host-related functions
In the Storwize/SVC driver, initialize_connection checks if a host
object exists on the storage, and if not, creates one. Similarly,
terminate_connection checks if there are any more mappings for this
host, and deletes the host object if there are none. Consequently, there
exist races between two initialize_connection calls, two
terminate_connection calls, or one and one.
The easy solution here is to use locks. Because locks are files on the
local machine, this implies that all cinder-volume processes managing a
given Storwize/SVC contoller run on the same machine.
john-griffith [Sat, 8 Feb 2014 04:55:22 +0000 (21:55 -0700)]
Dont set error_extending status on API extend call
Recent change (Ifd523ac5e9039861cf87711dc5c4842b5cb524c2)
moved the quota check on extend_volume to the API layer
in order to provide feedback to caller if the quota check
failed.
The problem is that change still sets the volume status to
error_extending if the quota check fails. There's no reason
to do this if we're now giving immediate feedback that the call
failed.
I'm also unclear on what the purpose of adding the reservations
to the rpc call are, but I'll double check on that before changing.
This patch leaves most of the previous change in place but
removes the setting of error_extending to the volumes status
on the quota fail.
Jeff Applewhite [Thu, 30 Jan 2014 19:11:08 +0000 (14:11 -0500)]
Fixes cinder failed to create/restore a backup with NFS driver
The action cinder backup-create fails when trying to backup a newly
created volume when using cinder.volume.drivers.nfs.NfsDriver. This
patch removes not implemented stubs for backup_volume and
restore_volume. The inherited methods in cinder/volume/driver.py
succeed in creating a backup and in restoring it. After manual
testing of this change backups/restores succeed without the not
implemented stubs. This change also adds the not implemented
stubs to the glusterfs driver until a fix is submitted.