6b532096f6c72627dccb32fa49e8045d6afbdc6d
Commit Graph

288 Commits

Author SHA1 Message Date
Ziad Sawalha
6b532096f6 Use Keystone Extension Syntax for EC2 Creds
- Syntax is OS-KSEC2:ec2Credentials (not ec2Credentials)
- adds to fix for bug 917408
- Syntax also requires a call to /tokens instead of /ec2tokens
- Changes are compatible (old syntax supported)
- Warning will be issued to log if URL syntax is old
Change-Id: I5ff9d1643122de2f383517e60f15852720c54490
2012年02月03日 11:21:27 -08:00
Maru Newby
07d74aa916 Raise ApiError in response to InstanceTypeNotFound
* Updates methods in nova.compute.instance_types to catch
 InstanceTypeNotFound exceptions and re-raise them as ApiError.
 - Previously, the methods in instance_types were raising ApiError in
 response to DBError, but the underlying db calls have since been
 updated to detect empty results and throw more specific exceptions.
 * Updates get_instance_type_by_flavor_id to not try to catch DBError,
 as the underlying db call only ever raises FlavorNotFound.
 get_instance_type_by_flavor_id should not raise ApiError, as callers
 expect the FlavorNotFound exception and know how to handle it.
 * Fixes bug 872618
Change-Id: I8652f04889adb448017afd253ecdcc840fbb660f
2012年02月03日 00:15:12 -08:00
Nirmal Ranganathan
999db21e1a Throw an user error on creating duplicate keypairs
Fixes bug 902162
Change-Id: I1b73943aab338bde90b4d47bc015964e9981af5d
2012年02月02日 15:35:07 -06:00
Jenkins
03a028e621 Merge "Optionally pass a instance uuid to log methods." 2012年02月01日 23:54:36 +00:00
Thorsten Tarrach
553982fb8b fixed bug 920856
Changed the responses to match that of Amazon EC2
Changed test to expect that response
Change-Id: Ia03a0ea663614944067c0a0193058ba91e149ad2
2012年02月01日 16:00:45 +01:00
Michael Still
605c22b180 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.
Change-Id: I1f61c04f32dbb960471950ac7231313d9d9ced12
2012年02月01日 15:43:46 +11:00
john-griffith
c9ac6e1671 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
2012年01月30日 11:19:52 -07:00
Jenkins
f4c0fbafc1 Merge "Blueprint xenapi-provider-firewall and Bug #915403." 2012年01月25日 15:56:29 +00:00
Jenkins
30ac47bcbd Merge "blueprint host-aggregates: maintenance operations to host OSAPI exts" 2012年01月25日 15:20:08 +00:00
Deepak Garg
fe1c97ff4c Blueprint xenapi-provider-firewall and Bug #915403 .
1. Provides dom0 IPtables driver to implement the Provider firewall rules.
 2. Existing libvirt code has been refactored to reduce the amount of duplicated code to a minimum
 3. The three provider apis in ec2/admin.py file are now fixed the following way:
 a. remove_external_address_block returned 'OK' on removing blocks which didn't exist. This is now fixed.
 b. block_external_addresses raised exception earlier on duplicate network blocks. Now the exception is logged and failed status message is returned.
 c. all the three provider apis now logs for invalid and improper inputs and return uniform (a dictionary ) and proper status messages for all cases.
 4. appropriate unit tests added to cover the same
Change-Id: I27d83186f850423a6268947aed0c9a349d8f8d65
2012年01月24日 22:31:35 -08:00
Tomoe Sugihara
2594e480b2 Add os-start/os-stop server actions to OSAPI
Implements blueprint start-stop-methods-support-in-os-servers-xapi
Change-Id: I7aa241ffdd2ec3a7c9800411268f4adc47960be8
2012年01月25日 11:10:13 +09:00
Jenkins
5156c0e757 Merge "bug 917397" 2012年01月24日 23:18:16 +00:00
Russell Bryant
be96c43390 Add support for Qpid to nova.rpc.
Implements blueprint apache-qpid-rpc.
This patch adds a new implementation of the nova.rpc API that uses Qpid
as the messaging backend. We first considered trying to add Qpid
support to kombu, but the kombu API did not map very well to Qpid, which
is based on a newer version of AMQP. It was easier to just map the nova
rpc API to Qpid.
For more information about how to use Qpid with Nova, see this wiki
page:
 http://wiki.openstack.org/QpidSupport
The structure of impl_qpid is largely based on impl_kombu, but adapted
to use the Qpid APIs as necessary. This patch also factors out some of
the code shared with impl_kombu into nova.rpc.common to try to cut down
on duplicated code.
The unit tests were written from scratch instead of taking advantage
of the common rpc unit tests. The common unit tests only work if qpidd
is running, but they do pass if enabled. The unit tests for impl_qpid
instead use mox to mock out the Qpid objects and ensure the right
operations happen on them when the rpc API is exercised.
This patch was a joint effort between myself and William Henry, which is
why he was added to the Authors file in this patch.
Change-Id: Ibacaa956e016ef96f014443074e2a4622e31f090
2012年01月24日 16:18:05 -05:00
Cole Robinson
fefb88877c extensions: Allow registering actions for create + delete
This allows an extension to add new actions for create and delete
operations to an existing collection.
Currently when extending an existing collection (API namespace), an
extension can register brand new 'actions', and extend any preexisting API
functionality, but unfortunately create and delete are special cases that
don't fall under the 'actions' classification, meaning the infrastructure
can't handle them unless extending an existing impl.
Stubbing out the create/delete methods in the original resource with
the equiv of a NotImplementedError doesn't work, since 'extend'ing
requires the original implementation to exit correctly.
Whitelist 'create' and 'delete' and handle them appropriately.
v2:
 Add myself to Authors
 Update wsgi.action docs
 Add a test case
v3:
 Actually update Authors
Change-Id: I550ae93c5e200f18644042ac81656bc76dbe8955
2012年01月24日 13:30:23 -05:00
John Garbutt
2cf8b77c69 blueprint host-aggregates: maintenance operations to host OSAPI exts
This commit introduces sub for a host maintenance_mode option into
the osapi. It is required for the host aggregates work.
This is part of a series of commits that have started with change:
https://review.openstack.org/#change,3035
Change-Id: Ib462ef9ad6b641bf1083cc176dfba6645020ccec
2012年01月23日 14:37:47 +00:00
Dave Lapsley
dc0f299337 bug 917397
Add configuration sanity to QuantumManager. Logs error message
if a parameter not used by QuantumManager's create_networks()
method is passed into it.
Change-Id: I1d6daa7f77590a61b542122ada33ed1c188df19f
2012年01月20日 20:47:51 -05:00
Kiall Mac Innes
ccc2471f3e Fixes bug #919390 - Block Migration fails when keystone is un use.
I've Updated the calls to nova.virt.libvirt.utils.fetch_image() to match the rest of the class.
Additionally, nova.virt.images.fetch() currently makes no use of the user/project id supplied.
Change-Id: I2db4b8c1b6542909fcc2b452fc961e22fe2557bf
2012年01月20日 21:11:47 +00:00
Philip Knouff
7afc12b9a2 Fixed the log line
Fixed bug #877417
Change-Id: Iddb9a6d4eb798b0f41f0ef1ab01cb02d16d16dbe
2012年01月16日 17:16:27 -05:00
Zhongyue Luo
1611c23928 greenlet version inconsistency
Fixes Bug #917003
The latest version of greenlet is installed in install_venv.py while
the version required is set to 0.3.1 in pip-requires.
Change-Id: I145deb46a8edc41e87634dc5ca839baf5acd8065
2012年01月16日 01:58:39 -05:00
masumotok
8e57055cec First implementation of bp/live-migration-resource-calc
Fix based on revewer's comment
upgraded the migration version
nova/db/sqlalchemy/migrate_repo/versions/069_block_migration.py
rebase on master
Change-Id: Ia762f8dec761c3d595bc6fcd39f127f6d92306d2
2012年01月13日 15:24:28 +09:00
Daniel P. Berrange
d97b64b6e6 Tell users what is about to be installed via sudo
Rather than just giving users the sudo password prompt immediately,
actually tell them what is about to be installed, so they know
whether it is reasonable to be entering their password.
Change-Id: Ic0c1de812be119384753895531a008075b13494e
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2012年01月05日 16:08:04 +00:00
Hengqing Hu
a8fd6bf24b use name gateway_v6 instead of gateway6
fixes bug #890099
Change-Id: I2b516c4b41d387846f8edb9a7b82f3016f0e0eac
2012年01月03日 11:13:13 +08:00
Jenkins
ea21fe6965 Merge "Adds EC2 ImportKeyPair API support." 2011年12月30日 19:50:52 +00:00
lzyeval
6247c949f5 re-raising exceptions fix
Fixes bug #910008
Change-Id: I7914fe1eaffeb0be5feb414f3ea0ad563a36c21f
2011年12月31日 02:31:06 +09:00
Ivan Kolodyazhny
135fd91916 Bug 751229: Floating address range fixed
Change-Id: I4c7ab8512fe3a00dd555d3a183b2c2348cef9e21
2011年12月29日 09:20:58 +02:00
MotoKen
5bdc35b115 Adds EC2 ImportKeyPair API support.
Implements import_key_pair instead of import_public_key.
Change-Id: I256b76aeb4ff94030a58692bfd12b2d7c53ae461
2011年12月27日 15:01:25 +08:00
Jenkins
36c4616711 Merge "Bug#898257 abstract out disk image access methods" 2011年12月22日 19:23:21 +00:00
Cor Cornelisse
d503d6b107 Use SQLAlchemy to drop foreign key in DB migrate
A foreign key constraint needs to be removed in order to succeed in the
DB migration. An earlier submitted fix for this uses a mysql drop
statement. I think it's cleaner to use sqlalchemy to do this, as it's
done this way in other version migrations as well. Fix for bug 907254.
Update: IBM from 1928 called, they want their 80 CPL limit
back. - on a more serious note, fixed jenkins PEP8 failure
Update2: Replaced tab by a spaces
Update3: Don't do Foreign Key stuff if the engine is sqlite
Update4: Add myself to the Authors file
Update5: With the correct mail address
Change-Id: Ib021e0ddb2c80ee63888435a9e3761c053534160
2011年12月22日 18:35:09 +01:00
Pádraig Brady
5335b4ab0e Bug#898257 abstract out disk image access methods
Rather than providing two mutually exlusive image
access methods (loop and qemu-nbd), try each in turn.
This is to prepare for a follow up patch which will
add libguestfs as a method to try.
* nova/virt/mount.py: A new Mount class to abstract the
devce allocation, partition mapping and file sys mounting,
for each access type.
* nova/virt/disk/loop.py: A specialization of the base Mount class
to provide loop back mounting support.
* nova/virt/disk/nbd.py: A specialization of the base Mount class
to provide qemu-nbd mounting support.
* nova/virt/disk/api.py: A new file containing the nova.virt.disk
module interface.
(img_handlers): A new list of access methods to try,
with the order being honored.
(_DiskImage): An internal helper class that uses the plugin classes
above, to provide the operations available on a disk image file.
When mounting, iterate over each access method until one succeeds.
If a hint is provided about a CoW format image, the list of
methods to try will be reduced accordingly.
Note expected errors are no longer raised as exceptions during mounting.
Instead, on failure to mount an image, errors are collated and raised.
Interveining errors are logged in debug mode for successful mounts.
* nova/virt/libvirt/connection.py: Adjust the function parameter
names to be more general, rather than referencing specific
implementations like 'nbd' and 'tune2fs'.
Simplify the destroy_container() by storing and passing
back a reference to the _DiskImage object, which has the
necessary state to unmount.
* nova/utils.py (trycmd): A helper function to both deal with,
commands that issue ignorable warnings to stderr,
and commands that EXIT_SUCCESS while issuing errors to stderr.
nova/virt/xenapi/vm_utils.py: Adjust for the moved virt.disk package
Change-Id: If3a4b1c8f4e2f2e7300a21071340dcc839cb36d7
2011年12月22日 11:50:52 +00:00
Russell Bryant
30731e7d60 Document return type from utils.execute().
Change-Id: Id0bc0dff09a809fe3999c4ec5014ac40ccfd8d6d
2011年12月19日 14:37:46 -05:00
Jenkins
af54e79b78 Merge "Added support for creating nova volume snapshots using OS API." 2011年12月14日 09:15:10 +00:00
Yun Mao
1c0859283f fixed typos. removed an unused import
Change-Id: I3cc1d2b2e89f5f4bd82dd8a259363d4e88708531
2011年12月12日 23:12:03 -05:00
Gaurav Gupta
bfefe6317f Added support for creating nova volume snapshots using OS API.
Fixes bug 883676
blueprint nova-volume-snapshot-backup-api
Change-Id: Id3e1ad39ef791b93dd014cada87c2d295454701f
2011年12月12日 15:28:33 -08:00
Jenkins
9c34c82cf0 Merge "Handle the 'instance' half of blueprint public-and-private-dns" 2011年12月09日 18:57:06 +00:00
James E. Blair
5235106e95 Rename .nova-venv to .venv.
This simplifies a number of Jenkins jobs which currently, other
than directory names, could be the same for all OpenStack
projects. By renaming the virtualenv directory, the redundant
Jenkins virtualenv build and copy jobs can be eliminated.
Change-Id: Ieaf1dac3207ecb34b911c7edcd2086809abdf49e
2011年12月08日 15:17:51 -08:00
Andrew Bogott
88a0f06ac7 Handle the 'instance' half of blueprint public-and-private-dns
Added a minimalist flat-file DNS example driver, MiniDNS.
Added tests for MiniDNS and a test that uses MiniDNS
to validate instance DNS creation.
Change-Id: I512018b7ed90ac2f388277443ee69b872ed60ef2
2011年12月07日 12:57:20 -06:00
François Charlier
35df6a4714 Fixes a typo preventing attaching RBD volumes.
A typo in spelling 'rbd' as 'rdb' prevents attaching RBD volumes
to instances.
Fixes bug 900359.
Change-Id: I872369a21b5935c37c4299f3f748d2d133a78bb3
2011年12月06日 10:48:34 +01:00
Duncan McGreggor
5f72723b41 Add missing documentation for shared folder issue with unit tests and Python
lock file.
Addresses documentation need raised in bug 897155
Change-Id: Idc95c12f939948bbbefd84a79b3785e3c2fd752c
2011年12月05日 09:54:31 -08:00
Ghe Rivero
2c438f55be Updated nova-manage to work with uuid images
Fixes bug 899299
Change-Id: Ib0be692503b8761a5600902a1e0d7a4dc371a680
2011年12月05日 16:59:31 +01:00
Joseph W. Breu
3b29258ed3 Updates simple scheduler to allow strict availability_zone scheduling
This update adds strict availability_zone scheduling of new instances when
an availabity_zone option is not present in the creation call. This patch
does not change the expected default behavior.
Previous behavior was to default the zone to None and only update the zone
in the scheduler if an availability_zone was supplied. This incorrectly
allowed the scheduler to place new instances created without an
availability_zone onto compute nodes where the availability_zone had been
changed to something other than the default of 'nova'.
Setting default_schedule_zone to 'nova' will prevent new instance scheduling
into availability_zones other than the default 'nova' zone. This change
defaults the zone to None but allows the user to override this with the
default_schedule_flag.
In practice, if you have 2 availability_zones (nova, megazone) you can
configure default_schedule_zone on the API node to 'nova' and any instances
created will be created into the 'nova' availability_zone if one was not
supplied. Instances created with an availability_zone will be created as
normal into the availability_zone supplied.
Change-Id: Id23bac8448ea7ce6a1e1227d046c921328dbfe33
2011年12月01日 08:53:08 -06:00
Adrian Smith
9f643c80c6 Fix for bug 887712
Check weather the instance_id passed into instance_update() is a model id
or a UUID.
Change-Id: Ic361299cdbfa5c3786815753c47a8e4f3ba6d494
2011年11月29日 19:00:50 +00:00
Jenkins
48244d5122 Merge "Fix Bug #891718 " 2011年11月28日 20:21:45 +00:00
Ollie Leahy
e0ef89f091 Fixes bug 888649
Change exception.VolumeIsBusy to derive from NovaException instead of
Error, so that an 'unexpected keyword' exception is not thrown when
the exception is raised with keyword parameters.
Add unit test to confirm that the 'unexpected keyword' exception is not
thrown when the exception is raised by nova.volume.driver.VolumeDriver
Responded to reviewer observations, fix pep8 errors in tset_volume.py,
added email address to Authors file.
Change-Id: I15464cb0cf72a2c71f430e4c8c5c2b27cd4e2ef9
2011年11月28日 14:13:13 +00:00
Likitha Shetty
6b1df267d0 Fix Bug #891718
Change-Id: I0f458b4dd8996e1fe9fc22f48edd36493515980e
2011年11月28日 14:51:05 +05:30
Jenkins
1851662edb Merge "Bug #887805 Error during report_driver_status(): 'LibvirtConnection' object has no attribute '_host_state'" 2011年11月12日 17:53:58 +00:00
Alvaro Lopez
6e7b0387e4 Fixes bug 871877
Added an aditional testunit to the VlanNetworkTestCase to check
if the FixedIpNotFoundForNetwork exception is raised properly.
Change-Id: I92a0ca22aadcfa9a7fd434375e239be8ccf4f387
2011年11月10日 14:59:58 +01:00
Édouard Thuleau
1ecd70f23a Bug #887805 Error during report_driver_status(): 'LibvirtConnection' object has no attribute '_host_state'
Fixes the host status reports from LibvirtConnection driver.
This fix initializes in class 'LibvirtConnection', the local variable
'_host_state' and replaces the variable 'session' by the local
variable 'read_only'.
Change-Id: Ia3ba29dc287c793c79a2bbde0d5ec69eb6ada480
2011年11月10日 09:52:11 +01:00
Derek Higgins
ad7fcf225e Undefine libvirt saved instances
Fixes bug 814561
Adding a call to managedSaveRemove if the instance has a
saved instance, so they are now undefined in addition to running
instances during destroy
With test case
Also added myself to Authors
Change-Id: If93e8ac6972116152f38e187bd1a61c652855814
2011年11月09日 22:48:46 +00:00
garyk
813794ed46 Blueprint lasterror
Add in a log report to nova-manage
Usages:
Get the last errors in the nova logs
 nova-manage logs errors
Get the last x nova messages in the syslog. The default is 10
 nova-manage logs syslog <x>
Change-Id: Id5d3a546051e25175b6523711f437618d07c3f19
2011年11月08日 16:50:46 +02:00
Unmesh Gurjar
bef4ae5092 Fix lp:861160 -- newly created network has no uuid
Implemented code review changes.
Fixed issue causing pep8 build failure.
Change-Id: If2cc0e23be8d4e1558a10fa86e6ba4cdec61b7d1
2011年10月31日 11:32:09 +05:30