* Makes virtual interfaces get the instance and pass it to network.api
* Sends the id from the instance when looking up vifs
* Repairs the tests
* Fixes bug 925682
File locks in nova have a bad habit of lingering if the process that
created them is killed, and there isn't a good automated way to fix this
behavior. This option allows a deployer to avoid the problem if they
know they are only running a single nova process on a machine.
Soren Hansen [Wed, 1 Feb 2012 17:10:39 +0000 (18:10 +0100)]
Remove Hyper-V support
HyperV has been unmaintained for several releases now. The unit tests
are superficial, we have no way to test it, noone has stepped forward
to maintain it, and for a very long time, we've not had any reports that
it works. Furthermore, many improvements have been made across other
hypervisor drivers that have not been done in the HyperV driver, so even
if it worked, it would only expose a subset of the functionality that
the other drivers do.
Trey Morris [Mon, 9 Jan 2012 17:52:53 +0000 (11:52 -0600)]
Ties quantum, melange, and nova network model
get_instance_nw_info() now returns network model, and keeps the network
info cache up to date.
virt shim and translation in place for virts to get at the old stuff
Make sure multiple calls to _get_session() aren't nested
Fixes bug 924918
async_call_plugin() acquires a xenapi session as does the nested call to
get_xenapi_host(). This can cause a deadlock if multiple greenthreads
all block waiting for the outer sessions to be freed to allocate the
inner session. This change moves the call to get_xenapi_host() to outside
the with statement to ensure calls to _get_session() aren't nested.
bug 921087: i18n-key and local-storage hard-coded in xenapi
This fix introduces a new flag 'sr_matching_filter', whose default value is
'other-config:i18n-key=local-storage'. This filter is used for finding the
SR on which to install guest instances. The default value is the Local
Storage in default XenServer/XCP installations, and it is what was hard-coded
so far.
To select an SR with a different matching criteria, this flag can be set
to 'other-config:my_favorite_sr=true'. On the other hand, to fall back on
the Default SR, as displayed by XenCenter and as returned by
xenapi.pool.get_default_SR, this flag can be set to to 'default-sr:true'.
This changeset also makes a small code simplification along the way.
Pádraig Brady [Tue, 31 Jan 2012 23:46:42 +0000 (23:46 +0000)]
optimize libvirt raw image handling. Bug 924970
Tests were seen to time-out on libvirt when raw images were
used, which was due to large disk images being copied around
inefficiently. A system with standard disks was seen to take
an extra 60s/10G which was a problem with large root and
ephemeral disks. The changes below attempt to minimize the
I/O in dealing with cached raw images. These changes should
also help to minimize the disk space used for such images,
by avoiding the naïve copy which undoes the sparseness.
* nova/virt/libvirt/connection.py (_cache_image): Do the
resize here, rather than in _fetch_image(), so that we
can control when the resizing is done, to minimize the
amount of data that needs to be copied. Also if we're
generating rather than fetching the image, then just
generate in the instance dir too, as this should be faster.
* nova/tests/fake_libvirt_utils.py: Remove the resize
functionality since it's no longer used.
* nova/tests/test_libvirt.py: Likewise.
* nova/virt/libvirt/utils.py (fetch_image): Likewise.
(copy_image): Shell out to cp since it deals better
with sparse files. Note the above changes avoid sparse
copies, so this is just an ancillary improvement in the area.
Michael Still [Wed, 1 Feb 2012 00:41:22 +0000 (11:41 +1100)]
Optionally pass a instance uuid to log methods.
This change is intended to make log messages including instance
uuids consistent. This eases operational support, as when a
customer asks for the history of there instance it is a simple
grep operation, instead of the current situation. I have included
a sample use, but will work through adding this to relevant log
messages over time.
Russell Bryant [Tue, 31 Jan 2012 22:42:23 +0000 (17:42 -0500)]
Fix VPN ping packet length.
Fix bug 906346.
This patch addresses the typo pointed out in bug 906346. The ping being
sent was 15 bytes long when it should have been 14. Removing a pad byte
from the format string resolves this issue. I verified that the format
described in the code comments (and now the code) was correct using an
OpenVPN connection setup packet capture.
Russell Bryant [Tue, 31 Jan 2012 21:55:00 +0000 (16:55 -0500)]
Use "display_name" in "nova-manage vm list".
Fixes bug 894807.
This patch changes the output of "nova-manage vm list" to use the
display_name for an instance instead of the hostname in the output.
This makes the output consistent with what you get with "nova list".
Russell Bryant [Tue, 31 Jan 2012 21:16:24 +0000 (16:16 -0500)]
Fix broken devref docs.
Fix bug 888102.
This patch fixes the documentation generated here:
http://nova.openstack.org/devref/index.html
There was a typo in a script that resulted in the module names being
invalid and no docs being generated. This one character patch fixes it
up and makes the docs happy.
Splits Resource.__call__() into two parts to allow for easy auditing
of the API stack--checking execution times, etc. No behavior change
or execution time impact should be expected.
Russell Bryant [Tue, 31 Jan 2012 17:58:22 +0000 (12:58 -0500)]
Empty connection pool after test_kombu.
Empty the connection pool after the tests in test_kombu have run. This
ensures that there is nothing leftover that will affect tests of other
implementations that use nova.rpc.amqp (impl_qpid right now).
Russell Bryant [Tue, 31 Jan 2012 17:52:16 +0000 (12:52 -0500)]
Be more explicit about emptying connection pool.
This patch makes some code in test_qpid be more explicit about emptying
the connection pool. It now ensures that it removes exactly how many
connections are in the pool.
The previous code made a couple of assumptions. First, it assumed that
only one connection was in the pool (which is true, but it's still nice
not to make the assumption here in the cleanup code). Second, it
assumed that free() returned the number of connections that have been
placed in the pool. This is not correct. The result also includes the
number of connections that could be created based on the max size of the
pool. Use the free_items attribute instead, which gives the exact number
of connections that have been put() in the pool.
Trey Morris [Mon, 30 Jan 2012 23:44:07 +0000 (17:44 -0600)]
fixes melange ipam lib
Melange can have multiple ip_blocks assigned to a network. However
the ipam lib assumes that each block is its own L2 network and assigns
ips from each ip_block for every instance.
Hengqing Hu [Tue, 31 Jan 2012 13:20:04 +0000 (21:20 +0800)]
Return instancesSet in TerminateInstances ec2 api
Fixe bug #862680
Return instancesSet to follow ec2 TerminateInstances api specification:
'http://docs.amazonwebservices.com/AmazonEC2/dg/2007-01-03/ApiReference-SOAP-TerminateInstances.html'
Remove dead test_terminate_instances code in test_cloud.py
iscsiadm returns 0 if local db contains no target records. As a result,
no exception is caught and no entry gets created (--op new) before continuing
to login. Devstack/single-node users avoided this because, apparently, records
are created in initiator db on target creations.
Update: Address smokestack failures if err == None
Bug #923865: (xenapi driver)instance creation fails if no guest agent is avaiable for admin password configuration
Ensure that if the guest agent is not installed, the admin password configuration is
skipped. The fact that either one of 'version' or 'agent_build' is None (or both)
should be an accurate indication of such a condition.
john-griffith [Mon, 30 Jan 2012 18:16:42 +0000 (11:16 -0700)]
Implementation of new Nova Volume driver for SolidFire ISCSI SAN
* Adds new SolidFire driver that subclasses nova.volume.san.SanISCSIDriver
* Adds unit tests for new driver
* Adds new exception subclasses in nova.exception
* Adds John Griffith to Authors
Implements solidfire-san-iscsidriver
Change-Id: I4dc7508ba08f5333cde74d4cfeaae3939c5d2b02