Commit Graph

501 Commits

Author SHA1 Message Date
Lucian Petrut 9ef76890e9 Allocations leaked during migration rollback
Allocations committed against the destination host are not reverted
during live migration rollbacks. The reason is that we're not passing
the migrate data object properly.

At some point, the rollback callback signature has changed. We picked
it up but only for the main (non-cluster) driver:
I5f247d733642464f4ede0430d4dfc8a27a02e7fd

This change addresses the cluster driver as well.

Change-Id: I8c509d411b8fdf7e65622f1fbb2095fe9c3b98b5
Closes-Bug: #1841068
(cherry picked from commit d9c1cb6aa1)
2019-09-05 10:04:37 +00:00
Lucian Petrut 0c46d011a5 Update driver interface (get_info)
The "get_info" now accepts a "use_cache" flag. This was backported
to Rocky as part of a bugfix:
I907b69eb689cf6c169a4869cfc7889308ca419d5

Change-Id: I54ae1111d008ff85b1e4bbb0a4943c06ca147c7f
2019-09-05 12:20:52 +03:00
OpenDev Sysadmins 107d79ab52 OpenDev Migration Patch
This commit was bulk generated and pushed by the OpenDev sysadmins
as a part of the Git hosting and code review systems migration
detailed in these mailing list posts:

http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003603.html
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004920.html

Attempts have been made to correct repository namespaces and
hostnames based on simple pattern matching, but it's possible some
were updated incorrectly or missed entirely. Please reach out to us
via the contact information listed at https://opendev.org/ with any
questions you may have.
2019-04-19 19:50:54 +00:00
Claudiu Belu ae04ee248e Update .gitreview for stable/rocky
Change-Id: I8be5835e17df136aa32c8d8a0fca4c47e84ee1ad
2018-10-16 07:16:02 +00:00
Claudiu Belu 5a3a42d037 Revert "Switch nova uuidsentinel with oslo_utils' uuidsentinel"
This reverts commit 87fdd92f3d. The
changes were not made in Rocky.

Updates UPPER_CONSTRAINTS_FILE for stable/rocky

Additionally, sets the nova dependency branch to stable/rocky.

Change-Id: I0fa03ffa83978787726c983f69560bba79ece7ba
2018-10-05 08:32:58 +00:00
Claudiu Belu 87fdd92f3d Switch nova uuidsentinel with oslo_utils' uuidsentinel
uuidsentinel has been removed from nova in favor of the oslo_utils
one.

Change-Id: I2d70b3d96f630507adba770d4d4ccf4c9d4e8d01
2018-09-27 18:51:16 -07:00
Chuck Short e2ffcc2f0e Remove moxstubout usage
As of oslotest 2.5.0 moxstubout is deprecated so
remove it.

Change-Id: Ife7054711838df5f60acefdb02c4e31298a69c1f
Signed-off-by: Chuck Short <chucks@redhat.com>
2018-08-22 08:51:10 -04:00
Zuul 28370dac84 Merge "fix tox python3 overrides" 2018-08-06 10:26:04 +00:00
Zuul dce221ac08 Merge "add lower-constraints job" 2018-08-06 10:26:03 +00:00
Zuul 155fb10c20 Merge "Enable trusted certificates support" 2018-08-06 09:36:18 +00:00
Zuul 44bab385b2 Merge "trivial: Changes files Windows style line ending to Unix style" 2018-08-06 09:30:17 +00:00
Lucian Petrut d4f1fa457a Enable trusted certificates support
A recent feature has been added, allowing users to specify
trusted certificates (e.g. as barbican secret ids). The idea is
to ensure that the certificates used to sign and validate the
glance image are actually trusted by the user.

In order to enable this feature within our driver, all we have to
do is pass the trusted certificate ids (stored as an instance
object attribute) to the method that fetches glance images.

Blueprint: nova-validate-certificates

Change-Id: Ic28f2b3ecf4ca92dcb7e9643c6e0d207d40b5287
2018-08-02 17:36:50 +03:00
Zuul 2513599af7 Merge "Trivial: Sync renamed driver capability" 2018-08-02 14:32:03 +00:00
Doug Hellmann 74ea9d7166 add lower-constraints job
Create a tox environment for running the unit tests against the lower
bounds of the dependencies.

Create a lower-constraints.txt to be used to enforce the lower bounds
in those tests.

Add openstack-tox-lower-constraints job to the zuul configuration.

See http://lists.openstack.org/pipermail/openstack-dev/2018-March/128352.html
for more details.

Change-Id: I90c548df545990a4575628d918f2bce72071c9ca
Depends-On: https://review.openstack.org/555034
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-08-02 07:31:06 -07:00
Zuul 767b700e18 Merge "Switch to stestr" 2018-08-02 14:00:55 +00:00
Claudiu Belu 9cecf31510 trivial: Changes files Windows style line ending to Unix style
Recently, a new pep8 rule (H903) was introduced which checks for Windows
style endings. Because of this, Zuul is failing the pep8 job.

The files were converting using dos2unix.

Change-Id: I7ea5bf692ca19895046cb0803ea9c833b19eafc7
2018-08-02 06:35:50 -07:00
Claudiu Belu 8dd2910195 tests: uses oslotest as the test base
oslotest's base will add mock.patch.stopall, so we don't have to.

Change-Id: If13a465000648dfbf1e229a3b8d765e8b3204db4
2018-08-01 11:10:38 -07:00
Lucian Petrut e75804f027 Trivial: Sync renamed driver capability
The 'recreate' capability has been renamed to 'evacuate'. We need
to pick up this change.

Change-Id: Ib2cda086efe5547ad17decfd57b9267d16802139
2018-08-01 12:19:14 +03:00
Vu Cong Tuan ce3f8b7fc1 Switch to stestr
According to Openstack summit session [1],
stestr is maintained project to which all Openstack projects should migrate.
Let's switch to stestr as other projects have already moved to it.

[1] https://etherpad.openstack.org/p/YVR-python-pti

Change-Id: Ic328c6d6f47fabd3a9b8c013e60dfd44e9d38ac1
2018-07-10 10:32:55 +07:00
Zuul f82d74ff1a Merge "Avoid cleaning up cached images when configured not to" 2018-06-13 13:33:36 +00:00
huang.zhiping e31c139206 fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: Ibb8ce8e655643161b0b7d4e84f0c2897e9c6417c
2018-06-08 22:59:48 +08:00
Zuul 011d2fe885 Merge "uncap eventlet" 2018-06-04 20:41:16 +00:00
Claudiu Belu 48bb0d6b41 Fixes zuul issues
Some issues were not caught during the initial mock autospec
patch which was added to compute_hyperv, and now they're causing
some unit tests to fail. This patch fixes those issues.

Secondly, the docs job relies on tools/tox_install.sh to install
nova, but it is not passing the required arguments, causing it to
fail. This patch updates the script so it can properly execute.

Change-Id: I91cbadb2a05ee4880c3fa761696818ec95c40df2
2018-06-04 12:00:33 +00:00
Lucian Petrut 7caef58be0 Avoid cleaning up cached images when configured not to
This change ensure that we're honoring the "remove_unused_base_images"
config option, allowing deployers to disable the auto-removal of
old images.

Change-Id: I49a0a83ab34ca0b9da5d589aaa9006d169275b15
Closes-Bug: #1773342
2018-05-25 15:04:16 +03:00
Doug Hellmann c6259b382a uncap eventlet
We will manage the eventlet version using constraints now. See the
thread starting at
http://lists.openstack.org/pipermail/openstack-dev/2018-April/129096.html
for more details.

Change-Id: Idc5272a0b635bdc2495b470a8b6eca17899ff3df
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-04-11 11:50:10 -04:00
Zuul aadc23122c Merge "autospecs os-win utils classes" 2018-03-21 16:36:53 +00:00
Claudiu Belu d19606a828 autospecs os-win utils classes
Most of the os-win utils are created through
os_win.utilsfactory, which all rely on its function
'_get_class' to load and initialize the proper Utils
based on the OS version.

This commit patches the mention method, returning
an autospeced mock for the desired Utils instead.

Closes-Bug: #1735588

Change-Id: If0002b2c711aaeaf13273bed9b912fdd9c639a64
2018-03-21 12:04:01 +00:00
OpenStack Proposal Bot 24b2bc3322 Updated from global requirements
Change-Id: I4a8167b385c0f778e60f40bc504a9482f22266ce
2018-03-16 07:20:13 +00:00
Zuul b7a5775ab6 Merge "Flush console log file before retrieving content" 2018-03-09 07:16:05 +00:00
Claudiu Belu e27b942877 Pass user context to virt driver when detaching volume
We need this in a later change to pull volume attachment
information from cinder for the volume being detached so
that we can do some attachment counting for multiattach
volumes being detached from instances on the same host.

(cherry-picked from commit d2941bfd165055348dd584b630d4e631ef05e328)

Change-Id: If6e869b1c3516220b7deb0599d699caa2ed33889
Related-Bug: #1752115
2018-03-08 07:23:17 -08:00
Zuul 77b1b06f4c Merge "Cluster driver: Blacklist iSCSI/FC volume drivers" 2018-02-16 19:11:26 +00:00
Zuul 481c5c9439 Merge "docs: Update Cinder volume usage section" 2018-02-16 19:08:45 +00:00
Zuul 84b87fbb11 Merge "Add release notes" 2018-02-16 14:31:05 +00:00
Lucian Petrut 937aa55ffa Cluster driver: Blacklist iSCSI/FC volume drivers
There are critical known issues related to the cluster driver and
passthrough disks.

When an instance is failed over, the instance attached volumes need
to be accessible on the destination host. This will not happen
transparently for such disks, for which reason the instance may
bounce between a few nodes and then end up in error state,
basically defeating the purpose of the cluster driver.

This change ensures that the Hyper-V Cluster driver rejects
iSCSI/FC Cinder volumes, raising an error that describes possible
alternatives.

Closes-Bug: #1749958

Change-Id: I231b51c648e1349fcb8df4cd818b2d2887a55d69
2018-02-16 16:29:11 +02:00
Lucian Petrut 707432f45a docs: Update Cinder volume usage section
This change documents how to identify Cinder volumes from within
the guets as well as online resize limitations.

Change-Id: I725e958ae85353acdf1a1eb110f1a03c3629f0b2
2018-02-16 16:12:23 +02:00
Lucian Petrut 5b43e2ded4 Add release notes
We've enabled the release notes zuul job quite late in the release
cycle, for which reason some of the notes are missing, being added
by this change.

This change also adds a reference to the release notes page on
the main compute-hyperv docs page.

Change-Id: If5c717bad101b55379201a02afe6f88b3cd9345d
2018-02-16 16:12:20 +02:00
Zuul 1fc3788eb8 Merge "doc: Adds vNIC plug / unplugging information" 2018-02-16 14:05:20 +00:00
Claudiu Belu 734b46ec6d doc: Adds vNIC plug / unplugging information
There are a few restrictions when attaching / detaching a
vNIC to a Hyper-V instance.

Change-Id: Ibbfb3271f357d31446174c2e3c00f1478455df1b
2018-02-15 21:03:24 -08:00
Lucian Petrut f50f40ffc4 [Trivial] docs: fix code blocks indentation
For some code blocks, we have a superfluous 2-space indentation.
For this reason, the generated docs are quite inconsistent.

This change fixes this issue.

Change-Id: Ib37906f61875c17d32635f3b11937f429a7027fc
2018-02-15 19:41:51 +02:00
Lucian Petrut f5d32fa5fa docs: Update storage reference
This change provides additional information about the available
storage options.

Change-Id: Ia1d17632210469021aa1a1d3e3dc1b8d38a8d466
2018-02-15 19:41:47 +02:00
Zuul 27dcc93473 Merge "Adds documentation (part 2)" 2018-02-15 13:19:08 +00:00
Claudiu Belu 958eda9796 Adds documentation (part 2)
This patch adds additional documentation regarding various
features introduced in the Hyper-V Driver, how to configure
the compute node in order to use them, and how to use them:

* Generation 2 VMs
* UEFI Secure Boot
* Shielded VMs
* Setting boot order
* RemoteFX
* Hyper-V vNUMA
* QoS
* PCI devices
* Serial ports
* Nested Virtualization

Additionally, this patch adds more details on how to add the
compute nodes to Nova cells.

Change-Id: Ie475da2a8dca947344de22e287225c972258b3c2
2018-02-15 03:58:06 -08:00
Zuul 7cc9d95e29 Merge "Fixes eventlet monotonic clock issue" 2018-02-15 07:48:04 +00:00
Claudiu Belu 897321130a Fixes eventlet monotonic clock issue
The eventlet clock must be patched with the monotonic clock
in order to avoid issues caused by drifs of system time.

This is done in nova/__init__.py, but if compute-hyperv is
installed after nova, compute-hyperv will overwrite that
file.

Closes-Bug: #1749088

Change-Id: I0d32406a65d1f4d57435766d41a0f1c1efba2782
2018-02-14 07:48:40 +00:00
Zuul 3d4bc292dd Merge "Lock snapshot/destroy operations" 2018-02-13 14:55:29 +00:00
Lucian Petrut 95e979d907 Lock snapshot/destroy operations
At some point, we've removed the instance snapshot lock, allowing
destroy requests to proceed immediately. We assumed that this
should be fine as long as we're stopping pending WMI jobs.

The issue is that the snapshot operation is still not fully
preemptive. VHD related operations (e.g. copy, merge, upload to
glance) are not preemptive at the moment, for which reason
destroy requests will fail due to file locks.

Unless the new 'force_destroy_instances' config option is enabled
(disabled by default), we're locking the destroy/snapshot operations.

This partially reverts commit
e4208017fe.

Closes-Bug: #1748394

Change-Id: I3119c5bc5a714be867af19510dfab576f354835b
2018-02-13 14:30:18 +00:00
Zuul 0664a5181f Merge "Zuul: Remove project name" 2018-02-13 14:11:26 +00:00
Lucian Petrut c4c65971d3 Fix instance dir check when spawning
When spawning instances, we're checking if the instance dir
already exists, in which case we're logging a message, stating
that existing instance files will be reused.

Well, at least that's what we thought we were doing. Actually,
we're always logging this message as the check is wrong.

This change fixes this issue.

Change-Id: I6cf52ae23d90e687103e8bea0b6c4f9eaba6d36c
Closes-Bug: #1747961
2018-02-09 11:07:20 +02:00
Zuul 19917084d3 Merge "Prepare for readthedocs" 2018-02-07 11:53:31 +00:00
Lucian Petrut 3d816ede99 Prepare for readthedocs
Since compute-hyperv is not an official OpenStack project, we cannot
host our docs on docs.openstack.org. For this reason, we'll use
readthedocs.

As readthedocs will not use tox, we have to explicitly provide the doc
build requirements that are not included in requirements.txt.
Unfortunately, we'll have to update this file manually at least once
per release.

Also, reathedocs will invoke sphinx-doc from the /doc dir, for which
reason it cannot find etc/compute-hyperv-config-generator.conf. The
according reference is updated, explicitly declaring the namespaces
to be used when generating the config reference.

Change-Id: Idab6f10f92f7f2e40962f1cabaac8691e6c46619
2018-02-07 13:11:16 +02:00