]> review.fuel-infra Code Review - openstack-build/cinder-build.git/log
openstack-build/cinder-build.git
9 years agoBad link in API version details response
Vilobh Meshram [Wed, 6 May 2015 19:23:40 +0000 (12:23 -0700)]
Bad link in API version details response

Fix the broken link in API version detail response.

Change-Id: I556edadf70896711f6c1fa4e01442f65604d9a53
Closes-Bug: #1445088

9 years agoFix broken add_iscsi_conn log message
ankitagrawal [Wed, 6 May 2015 07:39:56 +0000 (00:39 -0700)]
Fix broken add_iscsi_conn log message

In hnas_backend.py add_iscsi_conn method, info message is
not logged correctly due to broken format string.

Fixed the broken format string to log proper info message.

Closes-Bug: 1452160
Change-Id: Ie277ecc23ca5c10b161849075d448188845f0865

9 years agoMerge "Logging not using oslo.i18n guidelines (scheduler)"
Jenkins [Wed, 6 May 2015 02:47:27 +0000 (02:47 +0000)]
Merge "Logging not using oslo.i18n guidelines (scheduler)"

9 years agoMerge "Fix range check for NFS used ratio"
Jenkins [Tue, 5 May 2015 07:59:35 +0000 (07:59 +0000)]
Merge "Fix range check for NFS used ratio"

9 years agoMerge "Catch additional type conversion errors"
Jenkins [Tue, 5 May 2015 07:57:12 +0000 (07:57 +0000)]
Merge "Catch additional type conversion errors"

9 years agoMerge "Tests: Remove sleep from NFS tests"
Jenkins [Tue, 5 May 2015 04:59:53 +0000 (04:59 +0000)]
Merge "Tests: Remove sleep from NFS tests"

9 years agoCatch additional type conversion errors
Jamie Lennox [Tue, 5 May 2015 01:50:21 +0000 (11:50 +1000)]
Catch additional type conversion errors

When converting strings to integers in quota we catch ValueError which
will handle an input which is not a valid number, eg 'abc'. Extend this
to covert TypeErrors which will handle things like a None value being
passed.

Partial-Bug: #1451637
Change-Id: I7e3e694d539113beeb99001aeb80012ac4c1124d

9 years agoTests: Remove sleep from NFS tests
Eric Harney [Mon, 4 May 2015 21:14:08 +0000 (17:14 -0400)]
Tests: Remove sleep from NFS tests

This will shave a few seconds off of a unit test run.

Change-Id: I785607f5efe9ed45b1555bbbaab38b68c57f5cc3

9 years agoVMware: Enable vCenter certificate verification
Vipin Balachandran [Mon, 4 May 2015 10:43:41 +0000 (16:13 +0530)]
VMware: Enable vCenter certificate verification

Currently vCenter certificate is not verified during connection
establishment. This patch adds a config option to specify a CA
bundle file to verify vCenter server certificate.

DocImpact

Change-Id: Ida730db66b154a4d445f7a91bccb9ca5b5a26f5e
Closes-Bug: #1276207

9 years agoMerge "Fake out sleeps in unit tests"
Jenkins [Sun, 3 May 2015 22:46:49 +0000 (22:46 +0000)]
Merge "Fake out sleeps in unit tests"

9 years agoMerge "Drop use of 'oslo' namespace package."
Jenkins [Sun, 3 May 2015 20:52:06 +0000 (20:52 +0000)]
Merge "Drop use of 'oslo' namespace package."

9 years agoMerge "Add hacking check for str and unicode in exceptions"
Jenkins [Sun, 3 May 2015 17:18:38 +0000 (17:18 +0000)]
Merge "Add hacking check for str and unicode in exceptions"

9 years agoFake out sleeps in unit tests
John Griffith [Fri, 1 May 2015 16:35:30 +0000 (10:35 -0600)]
Fake out sleeps in unit tests

Just a minor cleanup, had a few tests that were doing sleeps
(or looping calls for those that prefer it) that were being
executed to test timeouts in the unit tests.  No value in
actually *waiting* for these, so this patch just mocks them
out so we still test the procedure but don't actually have
to wait.

This shaves about 30 seconds or so off of the unit test run,
not a huge deal, but every little bit helps IMO.

Also noticed a LOG.debug message in the test_extensions file
that wasn't picked up in other cleanup work so I removed that
debug log call as well.

Change-Id: I415ac75816e8a0f4c48c61b23391df1a9a016d62

9 years agoFix range check for NFS used ratio
Tom Barron [Sat, 18 Apr 2015 13:42:10 +0000 (09:42 -0400)]
Fix range check for NFS used ratio

The nfs_used_ratio configuration parameter is supposed to be
greater than zero and less than or equal to one.  However,
current configuration checks actually allow values greater
than one because of a logic error.  Unit tests fail to detect
this issue because they find the exception that they expect
to find, but it is actually being thrown for another reason.

This commit fixes the logic error in the nfs driver code.

It also reworks all the unit tests for the do_setup method since
they suffer from the same issue that led to failure to detect
this error in the first place - they fail to do proper mocks of
submethods, and when these run the expected exception gets triggered
for the wrong reason.  We have moved these tests into their own test
class, where mock is used rather than mox.  Over time it is likely
that new tests will be implemented, or old tests reworked, with mock
instead of mox.  These can go in the new test class, which can be
renamed if that is appropriate.

Change-Id: I19ab396057fb6f60ad8e7d10944384db7e95ece6
Fixes-bug: 1445786

9 years agoMerge "Dell SC driver calls out the wrong REST API version"
Jenkins [Fri, 1 May 2015 06:08:24 +0000 (06:08 +0000)]
Merge "Dell SC driver calls out the wrong REST API version"

9 years agoMerge "Move logging sample to use oslo_log"
Jenkins [Fri, 1 May 2015 00:45:15 +0000 (00:45 +0000)]
Merge "Move logging sample to use oslo_log"

9 years agoMerge "Add retry to lvm delete"
Jenkins [Thu, 30 Apr 2015 18:48:48 +0000 (18:48 +0000)]
Merge "Add retry to lvm delete"

9 years agoMove logging sample to use oslo_log
Tom Hancock [Thu, 30 Apr 2015 14:42:15 +0000 (14:42 +0000)]
Move logging sample to use oslo_log

etc/cinder/logging_sample.conf needs an update to refer to
oslo_log, not cinder.openstack.common.log for its ContextFormatter.

Change-Id: I8bc2618124dfffc54d15fc5615bb1884d74988f4
Closes-Bug: #1450500

9 years agoRevert state if attachment already exists
Shyama Venugopal [Thu, 30 Apr 2015 10:22:27 +0000 (12:22 +0200)]
Revert state if attachment already exists

When attach is called twice for the same volume and instance the
attach_volume checks if the attachment already exists and returns.
This leaves the volume in 'Attaching' state. The volume status should
be reset to 'in-use' if we see the attachment already exists.

Change-Id: I2a2d28de59af234300082ab4655b0bc10699d54c
Closes-Bug: #1449980

9 years agoAdd retry to lvm delete
John Griffith [Wed, 29 Apr 2015 23:25:12 +0000 (17:25 -0600)]
Add retry to lvm delete

Seems we have another issue related to lvm and
snapshots, but this time it's on the delete side.

We used a simple retry mechanism for snapshot create
here:
  https://review.openstack.org/#/c/149360/8

I'm hesitant to just add another retry without looking
at dm issues, but this should address the problem
temporarily and give us a chance to collect some
data on the issue.

Change-Id: I37607a09e2f9af6f2f32ddfaa8567400541e533a
Closes-Bug: #1450110

9 years agoMerge "Leverage timeutils, drop strtime() usage"
Jenkins [Wed, 29 Apr 2015 16:05:28 +0000 (16:05 +0000)]
Merge "Leverage timeutils, drop strtime() usage"

9 years agoMerge "Admin extends tenant's volume but change admin's quota"
Jenkins [Wed, 29 Apr 2015 15:44:48 +0000 (15:44 +0000)]
Merge "Admin extends tenant's volume but change admin's quota"

9 years agoMerge "Fix fetch_to_volume_format if vhd is requested"
Jenkins [Wed, 29 Apr 2015 02:10:24 +0000 (02:10 +0000)]
Merge "Fix fetch_to_volume_format if vhd is requested"

9 years agoAdmin extends tenant's volume but change admin's quota
wuyuting [Fri, 13 Feb 2015 02:16:24 +0000 (10:16 +0800)]
Admin extends tenant's volume but change admin's quota

When admin extends a tenant's volume, the tenant's
quota-usage doesn't change. However, admin's quota-usage
has changed. The right practice is: extend whose volume,
whose quota-usage should be changed.

Change-Id: Ia1bed7f212cbee715e29698ebbfe3c67486a55f5
Closes-Bug: #1421492

9 years agoDrop use of 'oslo' namespace package.
Doug Hellmann [Tue, 28 Apr 2015 16:46:59 +0000 (16:46 +0000)]
Drop use of 'oslo' namespace package.

The Oslo libraries have moved all of their code out of the 'oslo'
namespace package into per-library packages. The namespace package was
retained during kilo for backwards compatibility, but will be removed by
the liberty-2 milestone. This change removes the use of the namespace
package, replacing it with the new package names.

The patches in the libraries will be put on hold until application
patches have landed, or L2, whichever comes first. At that point, new
versions of the libraries without namespace packages will be released as
a major version update.

Please merge this patch, or an equivalent, before L2 to avoid problems
with those library releases.

Blueprint: remove-namespace-packages
https://blueprints.launchpad.net/oslo-incubator/+spec/remove-namespace-packages

Change-Id: I950f1afb1b4600dfc1f38d1a7d9322f240f444a6

9 years agoMerge "Remove redundant code from VNX Cinder Driver"
Jenkins [Tue, 28 Apr 2015 06:22:35 +0000 (06:22 +0000)]
Merge "Remove redundant code from VNX Cinder Driver"

9 years agoMerge "Fixed issue with mismatched config in VMAX driver"
Jenkins [Tue, 28 Apr 2015 06:22:04 +0000 (06:22 +0000)]
Merge "Fixed issue with mismatched config in VMAX driver"

9 years agoMerge "Updated from global requirements"
Jenkins [Tue, 28 Apr 2015 06:21:53 +0000 (06:21 +0000)]
Merge "Updated from global requirements"

9 years agoMerge "Enable use of filter_function in PureISCIDriver"
Jenkins [Tue, 28 Apr 2015 06:07:19 +0000 (06:07 +0000)]
Merge "Enable use of filter_function in PureISCIDriver"

9 years agoMerge "Port rbd driver to use new driver model"
Jenkins [Tue, 28 Apr 2015 06:05:59 +0000 (06:05 +0000)]
Merge "Port rbd driver to use new driver model"

9 years agoAdd hacking check for str and unicode in exceptions
Jay S. Bryant [Mon, 20 Apr 2015 23:05:47 +0000 (18:05 -0500)]
Add hacking check for str and unicode in exceptions

One of the comments we are frequently having to make
on reviews is with regards to the use of str() or
unicode() on exceptions.  This hacking check pulled
from Nova will catch this problem earlier and avoid
conflicting comments being made in reviews.

Change-Id: I09eaf7b066f3e29733e6cbe16b2997edb6bc5e23

9 years agoMerge "Windows: Improve vhdutils error messages"
Jenkins [Sat, 25 Apr 2015 05:25:46 +0000 (05:25 +0000)]
Merge "Windows: Improve vhdutils error messages"

9 years agoMerge "Don't truncate osapi_volume_link prefixes"
Jenkins [Sat, 25 Apr 2015 05:18:03 +0000 (05:18 +0000)]
Merge "Don't truncate osapi_volume_link prefixes"

9 years agoMerge "Remove deprecated methods in VNX driver"
Jenkins [Sat, 25 Apr 2015 05:12:00 +0000 (05:12 +0000)]
Merge "Remove deprecated methods in VNX driver"

9 years agoMerge "Sync oslo service module"
Jenkins [Sat, 25 Apr 2015 04:59:40 +0000 (04:59 +0000)]
Merge "Sync oslo service module"

9 years agoAdd test case for volume_encryption_metadata_get
Joel Coffman [Thu, 26 Mar 2015 22:14:01 +0000 (18:14 -0400)]
Add test case for volume_encryption_metadata_get

This change adds unit tests for the volume_encryption_metadata_get
function. The unit tests provide protection against regressions when
refactoring this code as part of follow-up patches.

Writing the unit tests also exposed a minor issue with the existing
implementation of the volume_encryption_metadata_get function. If the
volume type is not encrypted, then the existing implementation would
raise an exception due to volume_type_encryption_get returning None.
In practice, this issue would not be encountered due to separate
checks to ensure that the volume type is encrypted, but a small
refactoring obviates the need for these checks and allows the
volume_encryption_metadata_get function to be invoked for both
encrypted and "normal" volumes.

A separate patch will clean up the unnecessary checks to ensure that
the volume type was encrypted prior to calling this function.

Related to blueprint volume-encryption-metadata

Change-Id: I6ba62a58ac62a3b7bfb2b9d4d18b37ef458b616c

9 years agoUpdated from global requirements
OpenStack Proposal Bot [Fri, 24 Apr 2015 12:56:59 +0000 (12:56 +0000)]
Updated from global requirements

Change-Id: I289c236da7680e22539dad22b5f98c298e69a633

9 years agoPort rbd driver to use new driver model
Marc Koderer [Wed, 3 Dec 2014 07:43:10 +0000 (08:43 +0100)]
Port rbd driver to use new driver model

Use new ABCmeta driver model for rbd driver.

Implements: blueprint abc-driver-update

Change-Id: Ifaa06477e388e4b2807c65a2357b49451db5d670

9 years agoDon't truncate osapi_volume_link prefixes
Deliang Fan [Fri, 24 Apr 2015 03:16:46 +0000 (11:16 +0800)]
Don't truncate osapi_volume_link prefixes

When osapi_volume_link_prefix is defined and used to update the
links return in API responses, do not drop the path component of
the overriding link prefix.

Change-Id: Ic84e16cdfa989d4af7f076a4c244808be2ca4dce
Closes-Bug: #1304099

9 years agoMerge "NetApp E-Series: Fix instance live-migration with attached volumes"
Jenkins [Fri, 24 Apr 2015 03:09:46 +0000 (03:09 +0000)]
Merge "NetApp E-Series: Fix instance live-migration with attached volumes"

9 years agoMerge "3PAR don't log version numbers every stats update"
Jenkins [Fri, 24 Apr 2015 03:09:36 +0000 (03:09 +0000)]
Merge "3PAR don't log version numbers every stats update"

9 years agoFixed issue with mismatched config in VMAX driver
Xing Yang [Wed, 15 Apr 2015 19:33:59 +0000 (15:33 -0400)]
Fixed issue with mismatched config in VMAX driver

When the source and target volumes have different meta device
configurations, clone volume will fail. This patch fixed the
problem.

Closes-Bug: #1442376
Change-Id: If2f2c085596b0045d7af6762bddeb4cd59158a57

9 years agoMerge "Move RBD calls to a separate threads"
Jenkins [Fri, 24 Apr 2015 02:59:22 +0000 (02:59 +0000)]
Merge "Move RBD calls to a separate threads"

9 years agoMerge "Use iscsi_helper instead of target_helper on logs"
Jenkins [Fri, 24 Apr 2015 02:55:21 +0000 (02:55 +0000)]
Merge "Use iscsi_helper instead of target_helper on logs"

9 years agoRemove deprecated methods in VNX driver
Tina [Fri, 24 Apr 2015 01:41:12 +0000 (21:41 -0400)]
Remove deprecated methods in VNX driver

This change amis to do a cleanup in VNX driver to remove those
deprecated methods.

Change-Id: I9d3c5bd6ade259a4d731d3d1020e4c37c75ef889
Close-Bug: 1447908

9 years agoMerge "Add external genconfig calls"
Jenkins [Fri, 24 Apr 2015 00:56:21 +0000 (00:56 +0000)]
Merge "Add external genconfig calls"

9 years ago3PAR don't log version numbers every stats update
Walter A. Boring IV [Thu, 23 Apr 2015 16:34:35 +0000 (09:34 -0700)]
3PAR don't log version numbers every stats update

After the 3PAR drivers were refactored to remove the local
file locks, the login mechanism was logging the common and
client version numbers on every driver entry point.

This patch removes that logging except at driver startup.

Change-Id: Ib7732817a45cbdfdf975df13dbaf9bc0462a1dc0
Closes-Bug: #1447697

9 years agoSync oslo service module
John Griffith [Thu, 23 Apr 2015 15:05:57 +0000 (09:05 -0600)]
Sync oslo service module

This does a full sync of the oslo.service module.  Note
that we've cherry picked some critical bug-fix changes
to this module already, this commit just syncs the full
module properly and gets us up to date where we should be.

Current HEAD in OSLO:
-----------------------
commit:  d5edda00b4eca65d57f94bd0ac1b790e6d1f732e
Date:    Wed Apr 22 19:49:00 2015 +0000
Merge "service child process normal SIGTERM exit"

Changes merged with this patch:
---------------------------------
d5edda00 - Merge "service child process normal SIGTERM exit"
702bc569 - service child process normal SIGTERM exit
64b5819e - Revert "Revert "Revert "Optimization of waiting subprocesses
           in ProcessLauncher
f5646edc - Revert "Revert "Optimization of waiting subprocesses
           in ProcessLauncher
d23b6589 - Revert "Optimization of waiting subprocesses in ProcessLauncher"
593005b7 - ProcessLauncher: reload config file in parent process on SIGHUP
f29e865d - Store ProcessLauncher signal handlers on class level
bf92010c - Optimization of waiting subprocesses in ProcessLauncher

NOTE: Commit 702bc569 was actually pulled in with commit d73ac96d .
      We shouldn't have merged that individual commit.  I include the
      commit here to document Oslo level that the service module is at
      cumulatively between that commit and patch.

Change-Id: I613ba5ba442cf533c0f68d06281d117fbac20bd6

9 years agoAdd external genconfig calls
John Griffith [Thu, 23 Apr 2015 18:07:12 +0000 (12:07 -0600)]
Add external genconfig calls

After moving to oslo.config we still were using
incubator config generator.  This was ok, but the
problem is we haven't been pulling config options
from the oslo libs.

This is a hack that just appends external lib calls
and appends those options to the sample file being built.

Change-Id: I2634b20ef4abd3bf7990f845d59ad3d208db234f
Closes-Bug: #1447380

9 years agoMerge "Add resource tag to logging in volume.manager.py"
Jenkins [Thu, 23 Apr 2015 17:57:57 +0000 (17:57 +0000)]
Merge "Add resource tag to logging in volume.manager.py"

9 years agoEnable use of filter_function in PureISCIDriver
Daniel Wilson [Wed, 22 Apr 2015 21:07:02 +0000 (14:07 -0700)]
Enable use of filter_function in PureISCIDriver

Adding filter_function to capabilities of PureISCIDriver.  Return
total_volumes as well for use with filter_function.

This will open a way for admins to prevent Cinder from scheduling
volumes on a Pure backend once it has reached the array’s limits. The
primary use case for this is volume limits. An example of a
filter_function that will prevent this issue would be:

filter_function="capabilities.total_volumes < 500”

This will prevent any issues with Purity versions that are limited to
500 volumes.

Without that filter_function the scheduler will continue to try and
schedule volume creation if space is available instead of selecting
another backend. The end result would be volume creation fails and the
volume is in an error state even though there are backends available
that could have handled it.

DocImpact: This means the PureISCSIDriver will now respect the
filter_function config option. Special Pure specific fields to filter
off of need to be added to the driver config manual.

Change-Id: I1368b74f79eb8c8560cf86df27f9af9541963a87
Closes-Bug: 1437082

9 years agoNetApp E-Series: Fix instance live-migration with attached volumes
Alex Meade [Tue, 24 Feb 2015 21:22:58 +0000 (16:22 -0500)]
NetApp E-Series: Fix instance live-migration with attached volumes

Currently, live migrations of instances with attached volumes that live
on a NetApp E-Series backend will fail and break connectivity to the
guest. This patch adds the 'netapp_enable_multiattach' configuration
option that enables multiattach operations with the E-Series driver.
It defaults to allowing these operations but needs to be configurable
since allowing for multiple attachments imposes a limit of 256 volumes
on the backend due to how multiple attachments must be managed by
E-Series.

Multiattach operations are enabled by mapping volumes to an E-Series
host group on the backend called 'cinder-host-group'. Host groups can
only have 256 mappings at a time and so we must limit the number of
volumes in order to guarantee any volume created could then be attached.

Closes-bug: 1433825
Change-Id: Icb73f5b65b12decbd7b7f21c2fcec6fe700eaf59

9 years agoAdd resource tag to logging in volume.manager.py
John Griffith [Sat, 18 Apr 2015 00:19:37 +0000 (00:19 +0000)]
Add resource tag to logging in volume.manager.py

We now have resource tag support in oslo logging,
and our logging is pretty inconsistent and down right
ugly in places.  Let's clean things up based on the
standard logging guidelines and use the fancy new
resource tag.

To use set the following in cinder.conf:
logging_context_format_string = \
%(asctime)s.%(msecs)03d %(levelname)s %(name)s [%(request_id)s \
%(project_name)s] %(resource)s%(message)s

This change hits the majority of the code in manager and
should be used as an example/guide.  There are some exceptions
around migration and replication where things are kinda ugly,
those should be fixed up as follow up work.

Change-Id: I1315cc16116601fea8c023b47f99b2eaad01d6fb

9 years agoLeverage timeutils, drop strtime() usage
Julien Danjou [Thu, 19 Mar 2015 12:24:00 +0000 (13:24 +0100)]
Leverage timeutils, drop strtime() usage

This patch remove some code that tried to parse time in different way by
leveraging timeutils instead. It also drops strtime() usage as it's
going to be deprecated in oslo_utils (see
I8b5119e64369ccac3423dccc04421f99912df733).

Change-Id: Icb2906ccd4b381f80064e0f1348fc64e389031dd

9 years agoMerge "Remove force check from copy_volume_to_image"
Jenkins [Thu, 23 Apr 2015 05:35:53 +0000 (05:35 +0000)]
Merge "Remove force check from copy_volume_to_image"

9 years agoRemove redundant code from VNX Cinder Driver
Jeegn Chen [Tue, 14 Apr 2015 06:19:12 +0000 (14:19 +0800)]
Remove redundant code from VNX Cinder Driver

The logic on read-only volume in cinder/volume/drivers/emc/emc_vnx_cli.py
is duplicate to the logic in cinder/volume/manager.py. This patch is to
remove it.

Change-Id: Ib1a740a6065dbc8f3412d9dcf2e0d9025ab32d87
Closes-Bug: #1439531

9 years agoRemove force check from copy_volume_to_image
John Griffith [Wed, 22 Apr 2015 04:28:34 +0000 (04:28 +0000)]
Remove force check from copy_volume_to_image

The upload_volume_to_image method allows a force parameter that will
upload a volume even though the volume is attached/in-use. A user can
get away with this with the LVM driver because the LVM backing is
local to the Cinder worker node that's pushing the bits to Glance.

The problem is, this only works for local storage, it won't work
with any iSCSI devices because they can't do multi-attach. Also,
the reason we required that a volume NOT be in-use for this
operation is because we have no way of keeping the guest Instance
from writing to the volume while we're uploading, and corrupting the data.

This has been exposed like this for several releases, so removing it
now likely would not be a good user experience.  Instead, this
patch add a config option to enable/disable it (default is to
disable), and deployers can choose whether they would like to
allow the use of --force True or not.

DocImpact Disables the --force option to copy-volume-to-image and
          introduces "allow_force_upload" boolean option to re-enable

Change-Id: I1210186689dea204601356f8d08805c6cb6f017c
Closes-Bug: 1446954

9 years agoLogging not using oslo.i18n guidelines (scheduler)
Sean McGinnis [Tue, 14 Apr 2015 15:02:22 +0000 (10:02 -0500)]
Logging not using oslo.i18n guidelines (scheduler)

Multi-patch set for easier chunks. This one addresses
the scheduler cinder directory.

There have been quite a few instances found where the
i18n guidelines are not being followed. I believe this
has helped lead to some of the confusion around how to
correctly do this. Other developers see this code and
assume it is an example of the correct usage.

This patch attempts to clean up most of those violations
in the existing codebase to hopefully help avoid some of
that confusion in reviews.

Some issues address:
* Correct log translation markers for different log levels
* Passing format values as arguments to call, not preformatting
* Not forcing translation via six.text_type and others

Guidelines can be found here:
http://docs.openstack.org/developer/oslo.i18n/guidelines.html

Hacking checks will not be able to identify all violations of
the guidelines, but it could be useful for catching obvious
one such as LOG.info("No markers!").

Change-Id: I0473ac402bc7b4a644c9b700df0fa2b88d82d705
Partial-bug: 1433216

9 years agoservice child process normal SIGTERM exit
Brant Knudson [Wed, 22 Apr 2015 19:57:53 +0000 (14:57 -0500)]
service child process normal SIGTERM exit

service.py had some code where the child process would catch the
SIGTERM from the parent just so it could exit with 1 status rather
than with an indication that it exited due to SIGTERM. When
shutting down the parent doesn't care in what way the child ended,
only that they're all gone, so this code is unnecessary.

Also, for some reason this caused the child to never exit while
there was an open connection from a client. Probably something
with eventlet and signal handling.

This is a cherry-pick of oslo-incubator commit
702bc569987854b602ef189655c201c348de84cb .

Change-Id: I87f3ca4da64fb8070e4d6c3876a2f1ce1a3ca71d
Closes-Bug: #1446583

9 years agoMove unit tests into dedicated directory
John Griffith [Mon, 20 Apr 2015 21:38:22 +0000 (15:38 -0600)]
Move unit tests into dedicated directory

This patch moves all of the existing cinder/tests into
cinder unit tests.  This is being done to make way for
the addition of cinder/tests/functional.

Yes, this is going to cause significant pain with
any changes that haven't merged behind it in terms
of rebase, but there's no real alternative.  We have
to rip the band-aid off at some point, and early in L
seems like a great time to do it.

Change-Id: I63b0f89474b3c139bdb89589abd85319d2aa61ec

9 years agoDell SC driver calls out the wrong REST API version
Tom Swanson [Tue, 21 Apr 2015 21:34:55 +0000 (16:34 -0500)]
Dell SC driver calls out the wrong REST API version

On initialization of the session with the Dell REST
API the dell api version was incorrectly specified.
It should be 2.0 rather than 1.5.

Change-Id: I47ef63c24305b23125802012aa3c9dfde76813fd
Closes-Bug: #1446868

9 years agoMove RBD calls to a separate threads
Ivan Kolodyazhny [Mon, 20 Apr 2015 19:53:14 +0000 (22:53 +0300)]
Move RBD calls to a separate threads

RBD is a python binding for librados which isn't patched by eventlet.

Making long-running tasks like removing big (~100GB, ~1TB) volumes
blocks eventlet loop and all cinder-volume service hangs
until it finished when rados_connect_timeout is disabled. It makes
cinder-volume services unavailable for a while.

This patch moves all rados calls to a separate python thread which
doesn't block eventlet loop.

Change-Id: Ibaf43858d60e1320c339f2523b5c09c7f7c7f91e
Closes-Bug: #1401335

9 years agoMerge "Storwize driver should only report active wwpn port"
Jenkins [Tue, 21 Apr 2015 17:36:42 +0000 (17:36 +0000)]
Merge "Storwize driver should only report active wwpn port"

9 years agoMerge "Standardize logging in volume.api.py"
Jenkins [Tue, 21 Apr 2015 07:26:14 +0000 (07:26 +0000)]
Merge "Standardize logging in volume.api.py"

9 years agoMerge "Reserve 5 migrations for Kilo backports"
Jenkins [Tue, 21 Apr 2015 07:26:00 +0000 (07:26 +0000)]
Merge "Reserve 5 migrations for Kilo backports"

9 years agoReserve 5 migrations for Kilo backports
John Griffith [Mon, 20 Apr 2015 17:04:46 +0000 (11:04 -0600)]
Reserve 5 migrations for Kilo backports

Reserve 5 migrations so that we can backport any fixes
that require a db migration to stable kilo.

Change-Id: I951f945e58698907a464e19d340222e41c0f31d1

9 years agoRBD: Add missing Ceph customized cluster name support
Zhiteng Huang [Mon, 20 Apr 2015 16:25:11 +0000 (00:25 +0800)]
RBD: Add missing Ceph customized cluster name support

It turns out '--cluster' is also needed when RBD driver talks to
ceph cluster using 'ceph' command (not via librados).  This change
appends RBDDriver._ceph_args with '--cluster' when 'rbd_cluster_name'
config option is not None.

Change-Id: Ie957a3658a630947a140f4172f775e42b7611c6e
Closes-bug: #1444855

9 years agoStandardize logging in volume.api.py
John Griffith [Fri, 17 Apr 2015 20:51:06 +0000 (20:51 +0000)]
Standardize logging in volume.api.py

We now have resource tag support in oslo logging,
and our logging is pretty inconsistent and down right
ugly in places.  Let's clean things up based on the
standard logging guidelines and use the fancy new
resource tag.

This patch starts with the volume.api file as that's
'easy', so we can enforce things going forward and start
working out other files in future patches.

To use set the following in cinder.conf:
logging_context_format_string = \
%(asctime)s.%(msecs)03d %(levelname)s %(name)s [%(request_id)s \
%(project_name)s] %(resource)s%(message)s

Change-Id: I78708ba8bc372c2ca051aa7d84386dc7125a9b5e

9 years agoMerge "Fix QoSSpecManageApiTest to work in parallel"
Jenkins [Sun, 19 Apr 2015 15:48:41 +0000 (15:48 +0000)]
Merge "Fix QoSSpecManageApiTest to work in parallel"

9 years agoMerge "Complete the doc/README.rst instructions to build docs"
Jenkins [Sun, 19 Apr 2015 15:43:08 +0000 (15:43 +0000)]
Merge "Complete the doc/README.rst instructions to build docs"

9 years agoMerge "VMware: Improve invalid container error message"
Jenkins [Sun, 19 Apr 2015 06:11:13 +0000 (06:11 +0000)]
Merge "VMware: Improve invalid container error message"

9 years agoMerge "VolMgr: reschedule only when filter_properties has retry"
Jenkins [Sun, 19 Apr 2015 06:09:02 +0000 (06:09 +0000)]
Merge "VolMgr: reschedule only when filter_properties has retry"

9 years agoFix fetch_to_volume_format if vhd is requested
Lucian Petrut [Mon, 16 Feb 2015 17:43:17 +0000 (19:43 +0200)]
Fix fetch_to_volume_format if vhd is requested

qemu-img still uses the legacy 'vpc' format name. If the caller
requests a vhd image, the format check would raise an exception.

This patch adds an extra check to prevent this issue.

Change-Id: Ie72c0a79c08e8b7eefbd1534e45bc46f91ace96e
Partially-implements: blueprint bp/image-caching-support

9 years agoWindows: Improve vhdutils error messages
Lucian Petrut [Thu, 16 Apr 2015 21:37:18 +0000 (00:37 +0300)]
Windows: Improve vhdutils error messages

The Windows Cinder volume drivers use Win32 API functions for VHD/X
related operations. In case of failure, those return non-zero error
codes.

We can use the FormatMessage function in order to retrieve more
accurate error descriptions based on the error codes.

Change-Id: Ic0d68fe57847c6b1875567873a60315ba7c6d436

9 years agoMerge "Fix LUN misalignment issue with NetApp iSCSI drivers"
Jenkins [Fri, 17 Apr 2015 17:36:40 +0000 (17:36 +0000)]
Merge "Fix LUN misalignment issue with NetApp iSCSI drivers"

9 years agoVolMgr: reschedule only when filter_properties has retry
Zhiteng Huang [Fri, 17 Apr 2015 16:34:59 +0000 (00:34 +0800)]
VolMgr: reschedule only when filter_properties has retry

In the task flow for volume manager, create_volume tasks, volume gets
reschedule even when scheduler doesn't indicate so.  The problem is
the flow should not only check 'allow_reschedule' and 'request_specs',
but also (more importantly) filter_properties['retry'], which is
populated by scheduler if schedule_max_attempts is set to > 1.  This
checks was there before taskflow was introduced, but somehow the
migration missed the check for filter_properties['retry'].

This change adds back the check, so scheduler_max_attempts won't be
treated like scheduler_max_attempts = infinite.

Change-Id: Ia873617b22a2d86662ea8ea2fec5aae7f54a2058
Closes-bug: #1445561

9 years agoStorwize driver should only report active wwpn port
TaoBai [Fri, 17 Apr 2015 09:29:53 +0000 (02:29 -0700)]
Storwize driver should only report active wwpn port

Current code will report both active and inactive wwpn port which
will cause connection failure.We should only report active port.

Closes-bug: #1445409

Change-Id: Ide74df778294bfec50fbedd2ac3cd9207201b187

9 years agoMerge "Mask passwords with iscsiadm commands"
Jenkins [Thu, 16 Apr 2015 22:30:28 +0000 (22:30 +0000)]
Merge "Mask passwords with iscsiadm commands"

9 years agoMerge "Fix always false condition in glance wrapper"
Jenkins [Thu, 16 Apr 2015 19:18:55 +0000 (19:18 +0000)]
Merge "Fix always false condition in glance wrapper"

9 years agoMerge "SMBFS: Lock on a per-volume basis"
Jenkins [Thu, 16 Apr 2015 18:52:11 +0000 (18:52 +0000)]
Merge "SMBFS: Lock on a per-volume basis"

9 years agoMerge "Add volume:update rule to policy.json"
Jenkins [Thu, 16 Apr 2015 18:15:43 +0000 (18:15 +0000)]
Merge "Add volume:update rule to policy.json"

9 years agoMerge "Add support for customized cluster name"
Jenkins [Thu, 16 Apr 2015 18:15:34 +0000 (18:15 +0000)]
Merge "Add support for customized cluster name"

9 years agoMask passwords with iscsiadm commands
Walter A. Boring IV [Thu, 16 Apr 2015 17:44:10 +0000 (10:44 -0700)]
Mask passwords with iscsiadm commands

This patch adds the fix that exists in the nova
libvirt volume code to use oslo_utils strutils
to mask passwords that might show up in debug log
messages.

Change-Id: I5c321d6b2627f186ff3dfe64ee7ad71f27a95cf0
Closes-Bug: 1445137

9 years agoAdd support for customized cluster name
Zhiteng Huang [Thu, 16 Apr 2015 14:47:31 +0000 (22:47 +0800)]
Add support for customized cluster name

Current RBD driver assumes ceph cluster name to be 'ceph', for
cluster has a different name, the driver won't be able to connect
to the cluster.  This change add a new config option
'rbd_cluster_name' to address this issue.

DocImpact

Change-Id: I02ae1a255fd613fce291cc7ddf90cfd9175255a8
Closes-bug: #1444855

9 years agoSMBFS: Lock on a per-volume basis
Alessandro Pilotti [Wed, 1 Apr 2015 17:57:14 +0000 (20:57 +0300)]
SMBFS: Lock on a per-volume basis

This allows operations that do not conflict with each
other (i.e. are on different volumes) to run concurrently.
The prior locking scheme was too coarse and essentially
made the driver single-threaded.

This patch moves the implementation of the GlusterFS driver locking
scheme to the RemoteFS base driver so that other similar volume
drivers can use it.

Closes-Bug: #1439352
Change-Id: I37be14e7525406e0ad568f6228c1303998c5235f

9 years agoWindows SMBFS: fix volume extend
Lucian Petrut [Fri, 27 Mar 2015 12:15:25 +0000 (14:15 +0200)]
Windows SMBFS: fix volume extend

The Windows SMBFS driver inherits the Linux SMBFS driver,
overriding Windows specific methods.

This commit Ic89cffc93940b7b119cfcde3362f304c9f2875df added the
volume name as an extra argument to the _do_extend_volume in order
to check if differencing images are pointing to backing files other
than the according volume disks.

Although this is not required on Windows, this method should accept
this extra argument in order to have the same signature as the
method it overrides. At the moment, this raises the following
exception:

TypeError: _do_extend_volume() takes exactly 3 arguments (4 given)

Change-Id: I868d7de4a2c68f3fc520ba476a5660a84f440bb1
Closes-Bug: #1437290

9 years agoComplete the doc/README.rst instructions to build docs
Fabien Boucher [Tue, 17 Mar 2015 15:17:02 +0000 (15:17 +0000)]
Complete the doc/README.rst instructions to build docs

Give instructions about how to build the docs using tox
and virtualenv.

Change-Id: I3d7cdbd848158307706d94ee8a35b3b35911900d

9 years agoMerge "Add CA cert option to backups swift driver"
Jenkins [Thu, 16 Apr 2015 06:07:48 +0000 (06:07 +0000)]
Merge "Add CA cert option to backups swift driver"

9 years agoMerge "Fix a wrong argument of create method"
Jenkins [Thu, 16 Apr 2015 05:54:03 +0000 (05:54 +0000)]
Merge "Fix a wrong argument of create method"

9 years agoMerge "Reworked Dell SC iSCSI target portal return"
Jenkins [Thu, 16 Apr 2015 02:03:09 +0000 (02:03 +0000)]
Merge "Reworked Dell SC iSCSI target portal return"

9 years agoAdd CA cert option to backups swift driver
Francis Moorehead [Fri, 23 Jan 2015 13:13:38 +0000 (13:13 +0000)]
Add CA cert option to backups swift driver

Add the option in volume backups swift driver
to specify a CA certificate file

DocImpact: Add the option in volume backups swift driver to
specify a CA certificate file

Closes-Bug: 1413945

Change-Id: Ibcfe220d35cbb5369679a1ff51fffd41f16c9909

9 years agoMerge "Add locking to PureISCSIDriver around creating Purity Host objects."
Jenkins [Wed, 15 Apr 2015 06:01:04 +0000 (06:01 +0000)]
Merge "Add locking to PureISCSIDriver around creating Purity Host objects."

9 years agoMerge "Get volume from db again before updating it's status"
Jenkins [Wed, 15 Apr 2015 05:21:30 +0000 (05:21 +0000)]
Merge "Get volume from db again before updating it's status"

9 years agoMerge "Remove the export creation during volume creation for migration"
Jenkins [Wed, 15 Apr 2015 05:21:10 +0000 (05:21 +0000)]
Merge "Remove the export creation during volume creation for migration"

9 years agoFix a wrong argument of create method
Daisuke Fujita [Wed, 15 Apr 2015 05:03:31 +0000 (14:03 +0900)]
Fix a wrong argument of create method

Change the argument 'QoSSpecs.create' to 'qos_specs.create'.

Change-Id: Iabebc5f1681be75fb06d836ea72b93de0a9d688e
Closes-Bug: #1443331

9 years agoMerge "Fix assertEqual in test_volume.py in correct order of params"
Jenkins [Wed, 15 Apr 2015 03:39:41 +0000 (03:39 +0000)]
Merge "Fix assertEqual in test_volume.py in correct order of params"

9 years agoAdd locking to PureISCSIDriver around creating Purity Host objects.
Patrick East [Wed, 15 Apr 2015 01:42:19 +0000 (18:42 -0700)]
Add locking to PureISCSIDriver around creating Purity Host objects.

This will prevent us from getting conflicting credentials for
connection methods which will result in iSCSI attach operations to fail.

Change-Id: Ia206e7b5ff330c8fccb49ed23a31b120a5c04eb3
Closes-Bug: 1444224

9 years agoMerge "Fixes snapshot creation failure in CloudByte driver."
Jenkins [Tue, 14 Apr 2015 11:20:15 +0000 (11:20 +0000)]
Merge "Fixes snapshot creation failure in CloudByte driver."

9 years agoMerge "Logging not using oslo.i18n guidelines (brick)"
Jenkins [Tue, 14 Apr 2015 09:20:07 +0000 (09:20 +0000)]
Merge "Logging not using oslo.i18n guidelines (brick)"

9 years agoMerge "Verify all quotas before updating the database"
Jenkins [Tue, 14 Apr 2015 08:51:20 +0000 (08:51 +0000)]
Merge "Verify all quotas before updating the database"