This removes the majority of the nova-volume code from the codebase.
It updates relevent config options to default to cinder. It updates a
number of existing tests that were depending on code that was removed.
A few things still need to be removed:
* volume/driver.py & volume/iscsi.py
These files are used by the libvirt volume driver tests. These
tests should be updated to mock the relevant calls.
* scheduler/simple.py & scheduler/multi.py
These files should no longer be necessary so they can be removed
in a subsequent patch
* exception.py cleanup
Once the above files are removed there are a number of unused
exceptions which can be removed
* database calls and database tables
The database calls have not been removed and the tables have not
been dropped. This can be done in a separate migration
* additional config options and nova.conf.sample
There may be a few extra config options that can be removed and the
conf sample can be regenerated
Implements bp delete-nova-volume
Change-Id: I0b540e54dbabd26901a7530035a38583bb521fda
nova-dhcpbridge can read in an alternate config file location but wasn't
using it to parse config options. This fixes a regression introduced in
00786bc554.
This change is motivated by the fact that nova-dhcpbridge is passed to
dnsmasq in restart_dhcp() in nova/network/linux_net.py, and there is
currently no support for overriding config options for nova-dhcpbridge
in that call. There is support for overriding the FLAGFILE env variable
in that call, but nova-dhcpbridge was ignoring that. If I start
nova-network with an alternate config this provides a way for me to pass
that config to nova-dhcpbridge as well.
Change-Id: I002ea768500555a089bd1d5b0fea2354b27fba14
Replace hardcoded topic strings like 'volume' or 'compute'
with config constants like FLAGS.volume_topic, etc. See
bug #1057831 and bug #1061628.
Change-Id: I817ecc3cbe3245b51a0c047be58d17edfec8a838
utils.default_cfgfile have been removed from nova/utils, so
remove it here as well.
Fixes LP: #1065069
Change-Id: I71f6c7850123ef0c1ef4fedf608de13b31dafb32
Signed-off-by: Chuck Short <chuck.short@canonical.com>
fixes Bug #1056910
Allows the user to create a flavor without optional arguments.
The variable, ephemeral, is not currently set to a default value.
This none type value causes exceptions in subsequent code, which
occurs when specifying only mandatory parameters.
Change-Id: Ic440136b000dc296bef3bb6f8b0856ff5e7e4e79
The nova-novncproxy service was using rpc.call directly when it should
have been going through the rpcapi client proxy class. This patch fixes
that.
Fix bug 1067858.
Change-Id: I626fb01ff61ff507520d528122358ef687d297b7
This review wraps some strings which were missing out on
internationalization. It also adds a slightly more helpful error
message for quota key validation.
Change-Id: Id6f1f2578b78815b69cf43823d83ad24ca4123aa
This patch adds versioning support for the nova-network rpc API. During
Folsom development I added versioning to all rpc APIs with the exception
of network and volume. I was holding off on those to see what the fate
of that code in nova was going to be for sure. Adding it to the volume
API in nova doesn't make much sense at this point (but doing it in
Cinder does). Since nova-network is sticking around for a while, it
seems worthwhile to add a version number to the API for any future
changes while the code is still in the tree.
There are plenty of things in this rpc API that could be cleaned up or
improved, but I held off on doing any of those things. I would
recommend the same for anyone else (unless it's a bug that needs to be
fixed). I think any further improvements should be focused on Quantum
integration with Nova or Quantum itself.
Fixes bug 1060197.
Change-Id: I63ce57657388166544202af9c44c2298ae551aea
nova-manage doesn't validate the key value supplied to
update the quota, as a result unnecessary records will be
created in db and user will be under the impression that
quota value got updated.
This patch validates the input value given to the key.
fixes bug 1064359
Change-Id: I9928f30881aa2780a23005b5f69aa67a44f314c5
Following dprince's change to use
FLAGS, rather than cfg.CONF,
zmq_opts needs to be registered explicitly.
Change-Id: I66bc71563435088ee9224fdd603602e35f3e3bff
Python ignores SIGPIPE on startup, because it prefers to check every
write and raise an IOError exception rather than taking the signal. Most
Unix subprocesses don't expect to work this way. This patch (adapted
from Colin Watson's post at http://tinyurl.com/2a7mzh5) sets SIGPIPE
back to the default action for nova.utils.execute and nova-rootwrap
created subprocesses.
Fixes bug 1053364
Change-Id: I17e1629bb4ef4268515c6734ddb6e12746739c52
Updates quota value to -1 in db rather than None
if the user specify the quota limit as "unlimited".
Fixes bug 979087
Change-Id: I0ec412189ad9630c4a875655294c1e77886108f5
The nova-manage volume commands weren't updated when the switch
from int volume-id's to uuid's was made. This updates the
param2id method to call the appropriate conversion, and doesn't
attempt to cast the value to an int.
There is an additional issue with the nova-manage commands with the
introduction of Cinder. The calls in nova-manage are direct to the
nova database which when using Cinder is not valid. Add an error message
when trying to use delete or re-attach commands as they don't work.
This change deprecates the nova-manage delete function as it's now
implemented as an admin extension (nova commit id: If795599d and
cinder commit id: I29f4b892).
The reattach command is only valid for nova-volumes, a similar extension
will need to be added to cover cinder at which time the nova-manage volume
reattach can be deprecated as well.
Partial fix for bug #1051603
Change-Id: I666d4e627dee4a2025f7135560ee36c40f4bf17a
When creating a new flavor, it's now possible to omit flavorid. In this
case it will be automatically generated using utils.gen_uuid().
nova-manage and OS API updated accordingly.
Fixes: bug #1043410
Change-Id: Ibf9229599dac953177fbf1ffac5242ed716142db
Current websockify constructor in nova-novncproxy requires
target_path to be explicitely set. This commit adds the missing
parameter. Fixes bug 1031998.
Change-Id: I05e346b5df5bc1501b55ff606fc4cefdda889d60
Updates the bin/nova-rpc-zmq-receiver so that it makes use of FLAGS,
calls parse_args, and loads the nova.conf config file like all
other nova- binaries.
Fixes LP Bug #1044153
Change-Id: I904e5d2ae491cd805be78038493d437dd1f7f3cc
blueprint project-specific-flavors
This change implements API extension to manage project specific flavor
types, so that non-public flavor type can only see by projects with
access rights.
Change-Id: Ie2d2c605065b0c76897f843a4548a0c984a05f1a
The NetworkManager code will not raise webob exceptions, so there's no
point in explicitly catching those.
Also, the contrib.networks module is unused in nova-manage.
Change-Id: I5f9fe7fa7f4365f44e7a70b3d9536da8f10b8fa7
Implements blueprint os-api-network-create
The ability to create new networks is currently only exposed by the
nova-manage CLI. Here we add support for network creation in the
os-networks API extension.
With the exception of num_networks and network_size, all the parameters
supported by 'nova-manage network create' are supported. Only a single
network may be created by each API call.
To avoid code duplication, the nova-manage code is refactored and moved
into NetworkManager so that it can be re-used by the API.
DocImpact
Change-Id: I682d498ab35ea43b553b64e13e677fe9eeb8e08b
See bug 1034384, bug 1037590.
This reverts commit https://github.com/openstack/nova/commit/391f345d,
but leaves the DB migration in place while adding a further
migration to reverse it.
The motivation for reversion is that the per-user quota logic would
totally undermine the per-project quotas set for a pre-existing
openstack install.
The per-user quota logic could be re-introduced in a fixed state
after Folsom-3.
Change-Id: Idd4b55a2404a25f43f6737b661f828c28501066f
bug 1034692
Quantum team is removing all v1 support in Folsom, so this code
will not be used or supported with Quantum Folsom release.
Change-Id: I4c397d5238fcc3a15320e052bdc4735dfec1f176
Implements blueprint per-user-quotas.
Based on the original quotas structure.
NOTE:
quota_instances, quota_cores, quota_ram, quota_volumes,
quota_gigabytes, quota_key_pairs and quota_security_groups
are supported per user.
Allow 'projectadmin' role to access the user quota setting
methods.
Add commands 'nova-manage quota project/user' for quotas
management.
Change-Id: I07a39499432571fedd819c53ae414240cefc3354
bug 1031263
The nova database API use instance_type id as parameter to access flavor
extra spec. However, the flavor extra_specs API extension use flavor_id as
parameter wrongly.
As the instance_type ID is a purely nova internal ID, the database should
not expose it and instead use flavor_id as the parameter
Change-Id: I5f509cb7c4457d8c399df32f559a874d498be762
Signed-off-by: Yunhong, Jiang <yunhong.jiang@intel.com>
Fixes bug #1032177
If a floating IP is not associated with an instance, nova-manage fails
with:
local variable 'instance_uuid' referenced before assignment
This is a regression introduced by commit fc82c6d. Simply rename
the local variable to instance_uuid.
Change-Id: Ia6df23c945f0815c65bcfd2f49e8ba3225d03d7f
Mark the root_helper option deprecated and introduce usage of
the rootwrap_config option instead. The root_helper option will
still fully be supported in Folsom, but will be removed in Grizzly.
Transition notes: you should replace:
root_helper=sudo nova-rootwrap /etc/nova/rootwrap.conf
by:
rootwrap_config=/etc/nova/rootwrap.conf
Implements bp deprecate-root-helper
Change-Id: I8dfc94e9b91f7ffc82d393b345f09409da347e78
blueprint update-flavor-key-value
Enhance nova-manage so that it can add, delete and list key/value pairs for
flavors extra specs.
Change-Id: I0665bec6aecd7f7a1d8e845fd930f4bd5a841522
Signed-off-by: Yunhong, Jiang <yunhong.jiang@intel.com>
This fix correct the problem reported in bug 930193
nova-manage does not return a full list of fixed IPs. The reason
is that the call to fixed_ip['instance_id'] can throw exception
when fixed_ip does not have instance_id as its member. The changes
in this fix corrects the problem.
rebase to resolve the automatic merge issue.
Change-Id: Ic15a0a0f43f53b82f9d88a03803c96b44a8ddcb9
The fix addresses the bug reported in bug 1025827
currently command 'nova-manage fixed list' will return
'Command failed.' message when there is no network defined or
all networks have been deleted or even when a network gets
deleted, then a new network gets created. In all these cases,
the command produces the 'Command failed.' error message which
does not really tell what went wrong. This fix will produce
'No fixed IP found' in these conditions.
changes made for globalization.
changes made for based on the comments for patchset 7.
Change-Id: I3c2e9bf3fa3c748e680c1df27d243a648ed47cf5
this fix addresses the bug #1021810
Currently command 'nova-manage network list' or
'nova-manage fixed list' will return 'Command failed.' message when
there is no network defined or networks get deleted. This fix combined
with fixes to bug 1025827 will fix both command problem.
also change the print out message so that it can be translated.
code structure changes according to the suggestion from comments.
Change-Id: Id9a1a10217aac971cbbba9db5829c8478892db1a
Fixes bug 1017682 the netaddr.IPNetwork.iter_hosts
method doesn't return any IPs when /32 or /31 and
should throw an exception instead of silent error
Change-Id: Id8875b6016a4dbb40b29d2f7687e6c35491e0129