]> xenbits.xensource.com Git - osstest/openstack-nova.git/log
osstest/openstack-nova.git
8 years agoGuestfs handle no passwd or group in image
Andrea Frittoli [Mon, 5 Dec 2016 15:34:11 +0000 (15:34 +0000)]
Guestfs handle no passwd or group in image

When setting ownership of a file or directory, the guestfs driver
looks for the /etc/passwd and/or /etc/group files. In case they
are not found, the current driver lets the auges RuntimeError
through, which does not produce a very helpful error message.
Fixing that by handling the original exception and rasing a
Nova exception with more details in it.

Related-bug: #1646002

Change-Id: I2d15865c8be13b938e10e67c1b1b160f2a80f0c0

8 years agoMerge "conf: Deprecate 'torrent_' options"
Jenkins [Fri, 2 Dec 2016 13:57:19 +0000 (13:57 +0000)]
Merge "conf: Deprecate 'torrent_' options"

8 years agoMerge "conf: Deprecate 'remap_vbd_dev' option"
Jenkins [Fri, 2 Dec 2016 13:47:09 +0000 (13:47 +0000)]
Merge "conf: Deprecate 'remap_vbd_dev' option"

8 years agoMerge "conf: remove deprecated cert_topic option"
Jenkins [Fri, 2 Dec 2016 13:46:21 +0000 (13:46 +0000)]
Merge "conf: remove deprecated cert_topic option"

8 years agoMerge "Improve consistency in serial_console"
Jenkins [Fri, 2 Dec 2016 13:45:02 +0000 (13:45 +0000)]
Merge "Improve consistency in serial_console"

8 years agoMerge "config options: improve libvirt imagebackend"
Jenkins [Fri, 2 Dec 2016 13:44:07 +0000 (13:44 +0000)]
Merge "config options: improve libvirt imagebackend"

8 years agoMerge "conf: Remove deprecated 'compute_stats_class' opt"
Jenkins [Fri, 2 Dec 2016 13:42:57 +0000 (13:42 +0000)]
Merge "conf: Remove deprecated 'compute_stats_class' opt"

8 years agoMerge "conf: Improve help text for ldap_dns_opts"
Jenkins [Fri, 2 Dec 2016 13:42:02 +0000 (13:42 +0000)]
Merge "conf: Improve help text for ldap_dns_opts"

8 years agoMerge "conf: Move consoleauth options to a group"
Jenkins [Fri, 2 Dec 2016 13:41:00 +0000 (13:41 +0000)]
Merge "conf: Move consoleauth options to a group"

8 years agoMerge "Add a releasenote for bug#1633518"
Jenkins [Fri, 2 Dec 2016 13:24:57 +0000 (13:24 +0000)]
Merge "Add a releasenote for bug#1633518"

8 years agoMerge "Remove redundant req setting"
Jenkins [Fri, 2 Dec 2016 13:24:08 +0000 (13:24 +0000)]
Merge "Remove redundant req setting"

8 years agoMerge "Remove _set_up_controller() from attach tests"
Jenkins [Fri, 2 Dec 2016 13:23:18 +0000 (13:23 +0000)]
Merge "Remove _set_up_controller() from attach tests"

8 years agoMerge "Add block_device_mapping_v2.uuid to api-ref"
Jenkins [Fri, 2 Dec 2016 13:22:25 +0000 (13:22 +0000)]
Merge "Add block_device_mapping_v2.uuid to api-ref"

8 years agoMerge "guestfs: Don't report exception if there's read access to kernel"
Jenkins [Fri, 2 Dec 2016 12:34:03 +0000 (12:34 +0000)]
Merge "guestfs: Don't report exception if there's read access to kernel"

8 years agoMerge "Fix pci_alias that include white spaces"
Jenkins [Fri, 2 Dec 2016 06:00:38 +0000 (06:00 +0000)]
Merge "Fix pci_alias that include white spaces"

8 years agoMerge "libvirt: Don't re-resize disks in finish_migration()"
Jenkins [Fri, 2 Dec 2016 04:04:59 +0000 (04:04 +0000)]
Merge "libvirt: Don't re-resize disks in finish_migration()"

8 years agoMerge "libvirt: Never copy a swap disk during cold migration"
Jenkins [Fri, 2 Dec 2016 04:00:18 +0000 (04:00 +0000)]
Merge "libvirt: Never copy a swap disk during cold migration"

8 years agoAdd block_device_mapping_v2.uuid to api-ref
Ken'ichi Ohmichi [Fri, 2 Dec 2016 02:26:12 +0000 (18:26 -0800)]
Add block_device_mapping_v2.uuid to api-ref

The sample of block_device_mapping_v2 contains uuid as a parameter
but there is not any explanation of the parameter.
This patch adds it to api-ref.

The following is for explaining the parameter from the code.

  As the following code, source_type is "image" and api_dict["image_id"]
  can be glance image-id on the sample case.

  https://github.com/openstack/nova/blob/master/nova/block_device.py#L197
    api_dict[source_type + '_id'] = device_uuid

  The "image_id" is used for getting image metadata from Glance:

  https://github.com/openstack/nova/blob/master/nova/compute/api.py#L1072
    image_id = bdm['image_id']
    image_meta = self.image_api.get(context, image_id)

Change-Id: I83badab07446c2b1e55cc3b29a3ba9476efc179d

8 years agoFix pci_alias that include white spaces
zhaolihui [Tue, 1 Nov 2016 08:09:04 +0000 (16:09 +0800)]
Fix pci_alias that include white spaces

When the PCI alias was getting translated to a PCI request,
all the white spaces were getting removed. So the pci_passthrough:alias
specified in the flavor never matched the device in pci_alias.
This patch fixes the bug by only stripping the white spaces
at the beginning or the end of the elements

Change-Id: I2888b03faf6c25bcb6011db40100d925972c2231
Closes-Bug: #1638200

8 years agoMerge "libvirt: Rename Backend snapshot and image"
Jenkins [Fri, 2 Dec 2016 00:48:57 +0000 (00:48 +0000)]
Merge "libvirt: Rename Backend snapshot and image"

8 years agoMerge "libvirt: Cleanup test_create_configdrive"
Jenkins [Fri, 2 Dec 2016 00:48:16 +0000 (00:48 +0000)]
Merge "libvirt: Cleanup test_create_configdrive"

8 years agoMerge "libvirt: Test disk creation in test_hard_reboot"
Jenkins [Fri, 2 Dec 2016 00:47:31 +0000 (00:47 +0000)]
Merge "libvirt: Test disk creation in test_hard_reboot"

8 years agoMerge "libvirt: Rewrite _test_finish_migration"
Jenkins [Fri, 2 Dec 2016 00:46:49 +0000 (00:46 +0000)]
Merge "libvirt: Rewrite _test_finish_migration"

8 years agoMerge "conf: fix formatting in wsgi"
Jenkins [Fri, 2 Dec 2016 00:44:51 +0000 (00:44 +0000)]
Merge "conf: fix formatting in wsgi"

8 years agoMerge "conf: fix formatting in availability_zone"
Jenkins [Fri, 2 Dec 2016 00:44:07 +0000 (00:44 +0000)]
Merge "conf: fix formatting in availability_zone"

8 years agoMerge "conf: Removed TODO note and updated desc"
Jenkins [Fri, 2 Dec 2016 00:31:04 +0000 (00:31 +0000)]
Merge "conf: Removed TODO note and updated desc"

8 years agoMerge "Fix qemu-img convert image incompatability in alpine linux"
Jenkins [Thu, 1 Dec 2016 23:26:24 +0000 (23:26 +0000)]
Merge "Fix qemu-img convert image incompatability in alpine linux"

8 years agoMerge "Support detach interface with same MAC from instance"
Jenkins [Thu, 1 Dec 2016 21:03:31 +0000 (21:03 +0000)]
Merge "Support detach interface with same MAC from instance"

8 years agoMerge "Remove more tests from tests-py3.txt"
Jenkins [Thu, 1 Dec 2016 19:41:22 +0000 (19:41 +0000)]
Merge "Remove more tests from tests-py3.txt"

8 years agoMerge "[scheduler][tests]: Fix incorrect aggr mock values"
Jenkins [Thu, 1 Dec 2016 17:53:39 +0000 (17:53 +0000)]
Merge "[scheduler][tests]: Fix incorrect aggr mock values"

8 years agolibvirt: Don't re-resize disks in finish_migration()
Matthew Booth [Fri, 17 Jun 2016 12:05:24 +0000 (13:05 +0100)]
libvirt: Don't re-resize disks in finish_migration()

finish_migration is called by finish_resize() in compute manager,
which has updated the instance size and flavor before calling us. This
means that _create_image has already resized disks and (where
possible) their contained filesystems by calling cache() with the
correct size. That makes the additional resize in finish_migration a
no-op.

Implements: bp/libvirt-imagebackend-refactor
Change-Id: I58a286ebfdbfd22c1360880dda8e7a4ec9df8625

8 years agolibvirt: Never copy a swap disk during cold migration
Matthew Booth [Fri, 17 Jun 2016 09:29:49 +0000 (10:29 +0100)]
libvirt: Never copy a swap disk during cold migration

We previously didn't copy a swap disk if we were resizing it, and
instead recreated it on the remote end. With this change we never
copy a swap disk, even if we aren't resizing it. This is more
efficient and less surprising.

Implements: bp/libvirt-imagebackend-refactor
Change-Id: I2376c2f708e929426205e5ad59b12f8829dbd12b

8 years agolibvirt: Rename Backend snapshot and image
Matthew Booth [Wed, 22 Jun 2016 13:41:09 +0000 (14:41 +0100)]
libvirt: Rename Backend snapshot and image

snapshot and image didn't accurately describe what the methods did.
snapshot in particular suggested that the returned object was in some
way specific to a snapshot, whereas snapshot was simply the only user.

We also take the opportunity to rename all variables we touch in
driver to refer to disks rather than images.

Implements: bp/libvirt-imagebackend-refactor
Change-Id: I6ab8eb3b2c8a6af4c7ad6fba1f7d13716e9e0c12

8 years agolibvirt: Cleanup test_create_configdrive
Matthew Booth [Thu, 7 Jul 2016 14:29:45 +0000 (15:29 +0100)]
libvirt: Cleanup test_create_configdrive

This test made a tortured trip into _create_image_helper without using
much of its functionality. We pull this out and have it call
_create_configdrive directly.

This leaves _create_image_helper with only a single caller:
test_create_image_with_flavor_swap. This test is almost identical in
purpose to the much better test_create_image_with_swap and
test_create_image_with_legacy_swap_resizing. We refactor
test_create_image_with_swap to use ddt to cover all 3 cases, and
remove _create_image_helper.

This introduces the first use of ddt in Nova tests. It is already in
global-requirements. It was approved for use in Nova tests during the
Ocata contributor meetup:

  https://etherpad.openstack.org/p/ocata-nova-summit-meetup

Change-Id: I9d26ae3c26bab20ae60c2db011194ac0b2ead555

8 years agolibvirt: Test disk creation in test_hard_reboot
Matthew Booth [Wed, 6 Jul 2016 09:38:31 +0000 (10:38 +0100)]
libvirt: Test disk creation in test_hard_reboot

This test was asserting a call to _create_images_and_backing in a way
that didn't validate the data passed in any way. We update this to
instead validate that the expected disks are created.

This test highlights a bug in _create_images_and_backing, which is
passing a full path in place of a disk name. This will be fixed by
removing the call to _create_images_and_backing in a subsequent
commit.

This also allows us to validate the future removal of the call to
_create_images_and_backing.

Implements: bp/libvirt-imagebackend-refactor
Change-Id: I9d87c8c66f7a9ee15d0c26e8d514cd7b0eea1e09

8 years agolibvirt: Rewrite _test_finish_migration
Matthew Booth [Fri, 1 Jul 2016 16:09:39 +0000 (17:09 +0100)]
libvirt: Rewrite _test_finish_migration

Rewrite the finish_migration tests in anticipation of a major update.
Apart from switching from mox to mock, the principal change is that
we're now mocking at the backend boundary rather than the
_create_image boundary, which means we can test what we do to
individual disks. In the updated finish_migration we no longer use
_create_image, so making this change in advance allows us to see the
functional changes more clearly.

Implements: bp/libvirt-imagebackend-refactor
Change-Id: I439a5cfb054fa05ce156f7bf1d24cc8794d561e1

8 years agoMerge "Revert "Revert "Make n-net refuse to start unless using CellsV1"""
Jenkins [Thu, 1 Dec 2016 16:18:34 +0000 (16:18 +0000)]
Merge "Revert "Revert "Make n-net refuse to start unless using CellsV1"""

8 years agoMerge "Revert "Log a warning when starting nova-net in non-cellsv1 deployments""
Jenkins [Thu, 1 Dec 2016 15:50:12 +0000 (15:50 +0000)]
Merge "Revert "Log a warning when starting nova-net in non-cellsv1 deployments""

8 years agoguestfs: Don't report exception if there's read access to kernel
Kashyap Chamarthy [Wed, 23 Nov 2016 17:26:33 +0000 (18:26 +0100)]
guestfs: Don't report exception if there's read access to kernel

Commit 92ae0f1 ("libvirt - Add log if libguestfs can't read host
kernel") reworks the logic of handling access to Kernel for libguestfs.
In doing that, it erroneously raises an exception when libguestfs is
_able_ to access the Kernel.

Fix it by reporting exception only when libguestfs does _not_ have
read access to the Kernel.

This was first tried by Kevin Zhao here
Ic6802650cb8f93e0d02c51e9014eb85a7e71f6fe, but is abandoned for some
reason.

This also adds a little more direction on what to do to fix this error.

Related-Bug: #1646002

Change-Id: Id6b4108e4e4af7c98b3e1bd9de3a09ad057e7b92

8 years agoFix for live-migration job
Timofey Durakov [Thu, 1 Dec 2016 08:58:18 +0000 (11:58 +0300)]
Fix for live-migration job

Commit 9293ac0 to devstack-plugin-ceph altered
CEPH_LOOPBACK_DISK_SIZE_DEFAULT variable initialization
This fix added source for setting this variable in correct way.

Closes-Bug: #1646418

Change-Id: I84c3b78c53cfa283e9bcb7cf4b70ec6c95044e9c

8 years agoMerge "Optional name in Update Server description in api-ref"
Jenkins [Thu, 1 Dec 2016 03:37:59 +0000 (03:37 +0000)]
Merge "Optional name in Update Server description in api-ref"

8 years agoMerge "[api-ref] Minor text clean-up, formatting"
Jenkins [Thu, 1 Dec 2016 03:36:16 +0000 (03:36 +0000)]
Merge "[api-ref] Minor text clean-up, formatting"

8 years agoRemove more tests from tests-py3.txt
ChangBo Guo(gcb) [Wed, 30 Nov 2016 04:53:42 +0000 (12:53 +0800)]
Remove more tests from tests-py3.txt

This is follow-up of a3382747209fe12455,
these tests can run on Python 3, just enable them:

nova.tests.unit.api.openstack.compute.test_extended_availability_zone.ExtendedAvailabilityZoneTestV21
nova.tests.unit.api.openstack.compute.test_hide_server_addresses.HideServerAddressesTestV21
nova.tests.unit.api.openstack.compute.test_limits.WsgiLimiterProxyTest
nova.tests.unit.api.openstack.compute.test_scheduler_hints.SchedulerHintsTestCaseV21
nova.tests.unit.api.openstack.compute.test_urlmap.UrlmapTest
nova.tests.unit.api.openstack.compute.test_volumes.BootFromVolumeTest
nova.tests.unit.api.test_compute_req_id.RequestIdTest
nova.tests.unit.test_configdrive2.ConfigDriveTestCase

Partially-Implements: blueprint goal-python35

Change-Id: Ie2a6c44f3cbcd82e37da2e0c002e866d25823eda

8 years agoMerge "libvirt: prefer cinder rbd auth values over nova.conf"
Jenkins [Wed, 30 Nov 2016 22:58:33 +0000 (22:58 +0000)]
Merge "libvirt: prefer cinder rbd auth values over nova.conf"

8 years agoMerge "Port ironic unit tests to Python 3"
Jenkins [Wed, 30 Nov 2016 22:55:58 +0000 (22:55 +0000)]
Merge "Port ironic unit tests to Python 3"

8 years agoMerge "Port test_keypairs to Python 3"
Jenkins [Wed, 30 Nov 2016 22:55:17 +0000 (22:55 +0000)]
Merge "Port test_keypairs to Python 3"

8 years agoMerge "Port test_metadata to Python 3"
Jenkins [Wed, 30 Nov 2016 22:54:21 +0000 (22:54 +0000)]
Merge "Port test_metadata to Python 3"

8 years agoMerge "libvirt: cleanup network volume driver auth config"
Jenkins [Wed, 30 Nov 2016 22:45:57 +0000 (22:45 +0000)]
Merge "libvirt: cleanup network volume driver auth config"

8 years agoSupport detach interface with same MAC from instance
Leehom Li (feli5) [Mon, 19 Sep 2016 05:43:46 +0000 (13:43 +0800)]
Support detach interface with same MAC from instance

When detach_interface nova uses <interface> XML generated
from scatch, which is missing the PCI device information that
libvirt would use to uniquely identify devices.

In case instance has mutiple interfaces with same MAC address.
Libvirt will failed with below error message:
    libvirtError: operation failed: multiple devices matching
    mac address fa:16:3e:60:46:1f found

This patch fixes this problem by provide a new function
get_interface_by_cfg, this function uses cfg generated by
nova.virt.libvirt.vif.get_config  as parameter,
return a LibvirtConfigGuestInterface object.

Also added function format_dom for
LibvirtConfigGuestDeviceAddressPCI, which will be used to
generate pci address for LibvirtConfigGuestInterface.

Change-Id: I8acae90c9d2111ed35f58f374f321d64f01ba563
Closes-Bug: #1621076

8 years agoMerge "conf: Covert StrOpt -> PortOpt"
Jenkins [Wed, 30 Nov 2016 16:37:32 +0000 (16:37 +0000)]
Merge "conf: Covert StrOpt -> PortOpt"

8 years agoMerge "Check Config Options Consistency for xenserver.py"
Jenkins [Wed, 30 Nov 2016 16:36:42 +0000 (16:36 +0000)]
Merge "Check Config Options Consistency  for xenserver.py"

8 years agoMerge "Avoid unnecessary db_calls in objects.Instance._from_db_object()"
Jenkins [Wed, 30 Nov 2016 16:35:23 +0000 (16:35 +0000)]
Merge "Avoid unnecessary db_calls in objects.Instance._from_db_object()"

8 years agoMerge "docs: cleanup wording for 'SOFT_DELETED' in api-guide"
Jenkins [Wed, 30 Nov 2016 16:33:48 +0000 (16:33 +0000)]
Merge "docs: cleanup wording for 'SOFT_DELETED' in api-guide"

8 years agoMerge "Add os-start/stop functional negative tests"
Jenkins [Wed, 30 Nov 2016 16:31:43 +0000 (16:31 +0000)]
Merge "Add os-start/stop functional negative tests"

8 years agoMerge "Convert live migration uri back to string"
Jenkins [Wed, 30 Nov 2016 14:37:03 +0000 (14:37 +0000)]
Merge "Convert live migration uri back to string"

8 years agoAdd a releasenote for bug#1633518
Lee Yarwood [Thu, 10 Nov 2016 14:03:07 +0000 (14:03 +0000)]
Add a releasenote for bug#1633518

The code relating to this patch can be seen in:
I7096463c5eba951dd6322ee6965435e877ca0371

Partial-bug: #1633518
Change-Id: I297e138aca52ae10fbfaa50c79cf001fadaf557e

8 years agoMerge "Fix wait for detach code to handle 'disk not found error'"
Jenkins [Wed, 30 Nov 2016 04:41:25 +0000 (04:41 +0000)]
Merge "Fix wait for detach code to handle 'disk not found error'"

8 years agoMerge "conf: Fix indentation of network"
Jenkins [Wed, 30 Nov 2016 04:29:24 +0000 (04:29 +0000)]
Merge "conf: Fix indentation of network"

8 years agoMerge "Fix config option types"
Jenkins [Wed, 30 Nov 2016 04:13:09 +0000 (04:13 +0000)]
Merge "Fix config option types"

8 years agoMerge "Remove tests from tests-py3.txt"
Jenkins [Wed, 30 Nov 2016 03:46:32 +0000 (03:46 +0000)]
Merge "Remove tests from tests-py3.txt"

8 years agoMerge "Mention API V2 should no longer be used"
Jenkins [Wed, 30 Nov 2016 03:17:39 +0000 (03:17 +0000)]
Merge "Mention API V2 should no longer be used"

8 years agolibvirt: prefer cinder rbd auth values over nova.conf
Matt Riedemann [Fri, 4 Nov 2016 14:39:57 +0000 (10:39 -0400)]
libvirt: prefer cinder rbd auth values over nova.conf

In the case that the ceph storage backing volumes is different
from the one backing ephemeral storage in nova, the auth values
in the rbd connection_info could be different and not work if
we are using the nova.conf values for ephemeral storage.

This change makes the volume connection config code for rbd
prefer the cinder connection_info values if they exist, and
only falls back to nova config values if cinder doesn't have
anything set.

Depends-On: I4655cae3212d589177d2570403b563a83aad529a

Change-Id: Idcbada705c1d38ac5fd7c600141c2de7020eae25
Closes-Bug: #1635008

8 years agolibvirt: cleanup network volume driver auth config
Matt Riedemann [Thu, 20 Oct 2016 23:05:53 +0000 (19:05 -0400)]
libvirt: cleanup network volume driver auth config

The LibvirtNetVolumeDriver is handling both rbd and
sheepdog (iscsi) connections. The auth config logic
is mingling both backends which is really confusing.

For example, the iscsi protocol only defines auth_method,
auth_username and auth_password. It does not set an
auth_enabled value in the connection_info['data'] dict.

This change simplifies the logic involved for setting
the auth config by decoupling the rbd/iscsi handlers.

A follow-up change will build on this to fix the
rbd auth config to prefer the cinder volume connection_info
auth data over the local config for nova in the case
that different cinder backends are used for ephemeral
and block storage.

Change-Id: I8a55d87f75ecad757ce81b1f5f77c3a551154a17
Partial-Bug: #1635008

8 years agoFix wait for detach code to handle 'disk not found error'
int32bit [Wed, 23 Nov 2016 10:21:16 +0000 (18:21 +0800)]
Fix wait for detach code to handle 'disk not found error'

Currently, the code does an initial detach from the persistent and
transient domains in one call, then follows up with a call of the
retryable function, which first checks the domain xml before retrying
the transient domain detach. If the transient domain detach (which is
asynchronous) completes after we checked the domain xml, trying to
detach it again will raise a LibvirtError exception. Then, our loop
code in `_do_wait_and_retry_detach` doesn't catch it and will respond
with error. We should be handling the `disk not found error` from
libvirt and consider the job complete.

Closes-Bug: #1642689

Change-Id: I131aaf28d2f5d5d964d4045e3d7d62207079cfb0

8 years agoMerge "Fix notification doc generator"
Jenkins [Wed, 30 Nov 2016 00:14:01 +0000 (00:14 +0000)]
Merge "Fix notification doc generator"

8 years agoMerge "config options: improve libvirt remotefs"
Jenkins [Tue, 29 Nov 2016 22:27:11 +0000 (22:27 +0000)]
Merge "config options: improve libvirt remotefs"

8 years agoMerge "Improve consistency in libvirt"
Jenkins [Tue, 29 Nov 2016 22:26:37 +0000 (22:26 +0000)]
Merge "Improve consistency in libvirt"

8 years agoMerge "Config options: improve libvirt help text (2)"
Jenkins [Tue, 29 Nov 2016 22:25:59 +0000 (22:25 +0000)]
Merge "Config options: improve libvirt help text (2)"

8 years agoMerge "Remove config option snapshot_name_template"
Jenkins [Tue, 29 Nov 2016 22:23:42 +0000 (22:23 +0000)]
Merge "Remove config option snapshot_name_template"

8 years agoMerge "Remove deprecated compute_available_monitors option"
Jenkins [Tue, 29 Nov 2016 22:22:56 +0000 (22:22 +0000)]
Merge "Remove deprecated compute_available_monitors option"

8 years agoMerge "Never pass boolean deleted to instance_create()"
Jenkins [Tue, 29 Nov 2016 19:12:29 +0000 (19:12 +0000)]
Merge "Never pass boolean deleted to instance_create()"

8 years agoMerge "Fix SAWarning in TestResourceProvider"
Jenkins [Tue, 29 Nov 2016 17:49:35 +0000 (17:49 +0000)]
Merge "Fix SAWarning in TestResourceProvider"

8 years ago[api-ref] Minor text clean-up, formatting
Karen Bradshaw [Tue, 29 Nov 2016 17:31:46 +0000 (12:31 -0500)]
[api-ref] Minor text clean-up, formatting

- Cleaned up some wording, and formatted
  two rst notes.
- Moved cloudpipe.inc in index.rst to be located
  with other deprecated apis.

Change-Id: Ic3740540e8cc626110c77214acf87338e1abdd76

8 years agoConvert live migration uri back to string
Pawel Koniszewski [Tue, 29 Nov 2016 16:13:37 +0000 (17:13 +0100)]
Convert live migration uri back to string

If live_migration_inbound_addr is set in nova.conf, value of the option
will be saved under target_connect_addr in migrate_data. Unfortunately,
the type of value saved in target_connect_addr is unicode, therefore
when creating URI for live migration over dedicated interface we are
ending up with unicode type which is not acceptable by libvirt. To fix
the issue let's convert URI explictly back to string.

Change-Id: I651cc7a45fe06a2b6d81e007c4faf62947ee3203
Closes-Bug: #1638625

8 years agoNever pass boolean deleted to instance_create()
Dan Smith [Tue, 29 Nov 2016 15:05:17 +0000 (07:05 -0800)]
Never pass boolean deleted to instance_create()

This explicitly converts the deleted flag to an integer (which will
always be zero) at Instance.create() time. We already require it to
be False, but if set, we will pass the boolean instead of an integer,
which will confuse some (self-respecting) DBMs.

Change-Id: I67a340eea79b4423e77a00242ec6ae345e8c0e19
Closes-Bug: #1644513

8 years agoMerge "objects: Move 'cpumodel' to 'fields.CPU*'"
Jenkins [Tue, 29 Nov 2016 12:12:09 +0000 (12:12 +0000)]
Merge "objects: Move 'cpumodel' to 'fields.CPU*'"

8 years agoMerge "Default deleted if the instance from BuildRequest is not having it"
Jenkins [Tue, 29 Nov 2016 11:51:25 +0000 (11:51 +0000)]
Merge "Default deleted if the instance from BuildRequest is not having it"

8 years agoMerge "api-ref: add missing os-server-groups parameters"
Jenkins [Tue, 29 Nov 2016 11:30:53 +0000 (11:30 +0000)]
Merge "api-ref: add missing os-server-groups parameters"

8 years agoMerge "api-ref: body verification for abort live migration"
Jenkins [Tue, 29 Nov 2016 11:30:19 +0000 (11:30 +0000)]
Merge "api-ref: body verification for abort live migration"

8 years agoMerge "Fix expected_attrs kwarg in server_external_events"
Jenkins [Tue, 29 Nov 2016 11:26:13 +0000 (11:26 +0000)]
Merge "Fix expected_attrs kwarg in server_external_events"

8 years agoconf: Deprecate 'torrent_' options
Stephen Finucane [Mon, 28 Nov 2016 11:17:52 +0000 (11:17 +0000)]
conf: Deprecate 'torrent_' options

These are not tested and the feature either needs test coverage or
should be deprecated. Take the latter option, deprecating the feature
for a cycle to see if anyone actually cares about the feature.

Change-Id: I90206e6554bcbf5cd9105aa975c447c69640c923
Implements: bp centralize-config-options-ocata

8 years agoMerge "Improve help text for interval_opts"
Jenkins [Tue, 29 Nov 2016 06:52:09 +0000 (06:52 +0000)]
Merge "Improve help text for interval_opts"

8 years agoAdd os-start/stop functional negative tests
Maho Koshiya [Thu, 13 Oct 2016 08:23:24 +0000 (17:23 +0900)]
Add os-start/stop functional negative tests

The negative tests of os-start/stop API are not covered enough
in functional tests. We want to add the conflict tests of when
this API runs in the unexpected state of server.
* Case of os-start API, the server status must be SHUTOFF.
* Case of os-stop API, the server status must be ACTIVE or ERROR.

Change-Id: I1c44ae737ad39bc58dd3ebfd554176d6400fd9fd

8 years agoPort ironic unit tests to Python 3
ChangBo Guo(gcb) [Thu, 17 Nov 2016 10:55:53 +0000 (18:55 +0800)]
Port ironic unit tests to Python 3

* Use sorted(dict.keys()) because dict.keys() has no sort() method
  on Python 3

* Dicts are not orderable in Python 3, need work around. For more
  information, please see:
  http://stackoverflow.com/questions/22333388/dicts-are-not-orderable-in-python-3

Partially-Implements: blueprint goal-python35

Co-Authored-By: Davanum Srinivas <davanum@gmail.com>
Change-Id: Icf7fd0e392fc0d174d6312badf024367ba72fd8f

8 years agoPort test_keypairs to Python 3
ChangBo Guo(gcb) [Thu, 17 Nov 2016 10:23:39 +0000 (18:23 +0800)]
Port test_keypairs to Python 3

* webob response body should be bytes not strings
* response headers must be utf-8 strings

Partially-Implements: blueprint goal-python35

Change-Id: I85f4719feddb1eb2cc0043c692c0702087130cd8

8 years agoPort test_metadata to Python 3
Victor Stinner [Wed, 22 Jun 2016 09:24:27 +0000 (11:24 +0200)]
Port test_metadata to Python 3

* convert_password(): on Python 3, decode password from UTF-8 if it
  is a byte string
* convert_password(): don't modify password in the loop body, use an
  index increased at each iteration. This is a minor cleanup,
  unrelated to Python 3.
* ec2_md_print() now returns byte strings unchanged. On Python 3,
  str(bytes) uses "b'...'" format which is not the expected result
  (or it raises a BytesWarinng exception when using python3 -bb).
* Replace the base64 module with oslo_serialization.base64 to control
  the output type (bytes or text) on Python 2 and Python 3.
* _make_cache_key(): on Python 3, don't encode the host to UTF-8.
  Python 3 requires text.
* MetadataRequestHandler: on Python 3, encode HTTP body to UTF-8 if
  the body type is Unicode.
* test_metadata:

  - encode hmac.new() parameters using encodeutils.to_utf8()
  - use response.text rather than response.body to compare with
    Unicode string
  - use a byte strings for the instance identifier
  - fix some Unicode versus bytes issues

* tests-py3.txt: run test_metadata on Python 3

Co-Authored-By: Davanum Srinivas <davanum@gmail.com>
Co-Authored-By: ChangBo Guo(gcb) <eric.guo@easystack.cn>
Partially-Implements: blueprint goal-python35

Change-Id: Ifb43ce164d9fd80f9f85c95c762d7b010e84dfeb

8 years agoMerge "libvirt: Acquire TCP ports for console during live migration"
Jenkins [Mon, 28 Nov 2016 23:46:41 +0000 (23:46 +0000)]
Merge "libvirt: Acquire TCP ports for console during live migration"

8 years agoMerge "vif: allow for creation of multiqueue taps in vrouter"
Jenkins [Mon, 28 Nov 2016 23:46:06 +0000 (23:46 +0000)]
Merge "vif: allow for creation of multiqueue taps in vrouter"

8 years agoMerge "Check deleted flag in Instance.create()"
Jenkins [Mon, 28 Nov 2016 23:44:05 +0000 (23:44 +0000)]
Merge "Check deleted flag in Instance.create()"

8 years agoFix expected_attrs kwarg in server_external_events
Matt Riedemann [Mon, 28 Nov 2016 21:45:58 +0000 (16:45 -0500)]
Fix expected_attrs kwarg in server_external_events

The Instance.get_by_uuid method takes an expected_attrs
kwarg which needs to be a list or tuple, not just any old
iterable like a string. Because of how the underlying
Instance object code massages this value, it's not a hard
failure but does mean you don't join the columns you expect
when getting the instance.

This makes it a list and makes sure the stub in the unit
tests is checking for valid values.

Change-Id: I3ad85f9062b5cb19962d9e6a7af52440166def45
Closes-Bug: #1645479

8 years agoMerge "objects: Move 'arch' to 'fields.Architecture'"
Jenkins [Mon, 28 Nov 2016 19:32:15 +0000 (19:32 +0000)]
Merge "objects: Move 'arch' to 'fields.Architecture'"

8 years agoCheck deleted flag in Instance.create()
Dan Smith [Mon, 28 Nov 2016 15:24:21 +0000 (07:24 -0800)]
Check deleted flag in Instance.create()

An attempt to create an instance with the deleted flag set will
not work as intended, especially from instance.create(), which
can't properly pass the yet-to-be-determined deleted=id protocol.

This makes Instance.create() throw an error like the one for
being already created, and fixes the one test where we depend
on this working.

Change-Id: I60d18ca694a2eb7f333c0cf2a898cf8f17eb83dd
Closes-Bug: #1644513

8 years agoRevert "Revert "Make n-net refuse to start unless using CellsV1""
Amrith Kumar [Mon, 28 Nov 2016 19:02:27 +0000 (14:02 -0500)]
Revert "Revert "Make n-net refuse to start unless using CellsV1""

This reverts commit dbf0b2c8ae1334ee125f66aa6ed9ccb8303f42ca.

Change-Id: I247289e35588d53741e4868bdcfb38cc32a55f6e

8 years agoRevert "Log a warning when starting nova-net in non-cellsv1 deployments"
Amrith Kumar [Mon, 28 Nov 2016 18:59:53 +0000 (13:59 -0500)]
Revert "Log a warning when starting nova-net in non-cellsv1 deployments"

This reverts commit 215dc29bd9c70c4b83d47b47af9c178f8c66d132.

Change-Id: I444902b4b01fa5d348ef808043eb17cc78955422

8 years agoMerge "Add RPC version aliases for Newton"
Jenkins [Mon, 28 Nov 2016 18:01:39 +0000 (18:01 +0000)]
Merge "Add RPC version aliases for Newton"

8 years agoDefault deleted if the instance from BuildRequest is not having it
Sylvain Bauza [Mon, 28 Nov 2016 17:36:53 +0000 (18:36 +0100)]
Default deleted if the instance from BuildRequest is not having it

We should already have the rehydrated instance having the deleted field being
set. That field is also a BooleanField type, so we should never try to cast it
from an integer (even if we support it). Instead, we need to make sure that if
the field is not set for any reason (mostly because an Instance wasn't persisted
before we persisted the BuildRequest object that was nesting it), then we would
default the deleted field to False.

Change-Id: I828191f750a5978fed65a86e797388d11042b4a0
Related-Bug: #1644513

8 years agodocs: cleanup wording for 'SOFT_DELETED' in api-guide
Matt Riedemann [Mon, 28 Nov 2016 16:51:00 +0000 (11:51 -0500)]
docs: cleanup wording for 'SOFT_DELETED' in api-guide

The previous description of this status value was hard to
process. This cleans it up a bit.

Change-Id: I952bc712adf0dd7932da7eed460c10759ff3f9f2

8 years agolibvirt: Acquire TCP ports for console during live migration
Markus Zoeller [Tue, 22 Nov 2016 16:08:14 +0000 (17:08 +0100)]
libvirt: Acquire TCP ports for console during live migration

During a live migration process we reserve serial ports on
destination host and update domain XML during migration to
use the new reserved ports from destination.

If the migration succeeds we release ports on the source host.
If the migration fails we release reserved ports on the
destination host.

Co-Authored-By: Sahid Ferdjaoui <sahid.ferdjaoui@redhat.com>
Change-Id: Ie2524191d22cca2287eb7dbaa22b74d43e43c896
Closes-Bug: #1455252

8 years agoconf: Deprecate 'remap_vbd_dev' option
Stephen Finucane [Mon, 7 Nov 2016 12:07:58 +0000 (12:07 +0000)]
conf: Deprecate 'remap_vbd_dev' option

This is required for a decrepit version of Ubuntu. Just remove it.

Change-Id: Ica2c08fc00abb70d6ff7955bfe2b9a66e725f437
Implements: bp centralize-config-options-ocata

8 years agoconf: Covert StrOpt -> PortOpt
Stephen Finucane [Mon, 7 Nov 2016 12:03:36 +0000 (12:03 +0000)]
conf: Covert StrOpt -> PortOpt

...resolving the TODO in the process.

Change-Id: I076483c4a3aff369c0ba2e87abd91acafcd9f677