Recent changes broke support for the --flagfile argument. It would attempt
to find the argument and then pull off the filename portion, but it would
only skip one letter, instead of the full argument name. The resulting
error would be:
Change-Id: Ic252b0c778774a7ea3e24a9ed8b182deb5987f65
OSError: [Errno 2] No such file or directory: 'lagfile=../nova.conf'
Bugfix for lp901819
Move DB lookups out of the virt layer for bw usage.
Migrate to storing the mac address in the table.
Only lookup network label when sending usage events.
Attempt to use info_cache for label lookup before
punting to rpc call.
Change-Id: Iffb4bc220804be7d5fe26d6416b90cd747b72753
* Adds a rootwrap filter to limit readable files
* Adds a utils method to read a file as root
* adds tests to verify the additions work
Change-Id: Ic1ffb6f72f9b73795d5f39fac719842e6bdf16dd
Having to manually sudo to the nova user to make things work is
tedious. Make it so that if we can't read the conffile, we just
re-exec under sudo.
Fixes bug 805695
Change-Id: I322cece80ca757c69147fb3f8474ad137d9bff82
Move it here so that it can be kept in sync with openstack-common using
the new update.py script for code in openstack-common's incubation area.
See here for more details:
http://wiki.openstack.org/CommonLibrary#Incubation
Note: this commit just moves the existing code in Nova with no other
changes. A subsequent commit will sync it with latest openstack-common
so that it is easier see the new changes.
Change-Id: If88d678b1b9bad3d37117de7f7159d7fea8ab4c8
Phase 1 of the image-cache-management blueprint. Implement
checksumming and verification of base images, as well as
removal of base images which are not in use. Removal is
enabled with a flag.
Change-Id: Ib04a02075a103c2fef6716fd0ac87c41a3535d37
Fixes bug 925664
The model was disassociated from instance, but the code wasn't updated to
use instance_id instead
Change-Id: I532bd1f0f1d89353b6353215e80b74e9a14d989d
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.
Change-Id: I1ae20cc54a4614b200093ffd581d3ab21d7c241b
Fail early if you can't import mox, rather than return
a cryptic and undecipherable error. Fixes bug 810424.
Change-Id: Ie56d3e7447bbba841fdc882cb1f8f70e234812ef
This will allow us to support backends other than linux_net (i.e.
quantum L3 when it is available) for defining L3 connectivity.
Change-Id: I0b2ece2278bd68166741107a88cedd106d1ab651
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
Change-Id: I070ea7d8564af6c644059d1c209542d250d19ddb
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.
Change-Id: Idbc5e48ede4a8d2836dd1b102a9a0e172540776c
Fixes bug 884825. The bug was pointing out some unused variables
noticed by pylint.
utils.runthis() was only used in one place and doesn't really provide
much value over utils.execute(), so just remove it.
Change-Id: I3dcc34bd840a128418b58a8a66acb62adf3fc9cc
The next obvious step in porting to cfg is to define all options using
cfg schemas directly rather than using the flags.DEFINE_* helpers.
This is a large change, but it is almost entirely pure refactoring and
does not result in any functional changes.
The only change to note is that the default values for glance_host,
glance_api_servers and default_publisher_id options are now using opt
value interpolation i.e.
-glance_host=_get_my_ip()
+glance_host='$my_ip'
-glance_api_servers=['%s:%d' % (FLAGS.glance_host, FLAGS.glance_port)]
+glance_api_servers=['$glance_host:$glance_port']
-default_publisher_id=FLAGS.host
+default_publisher_id='$host'
Also note that the lower_bound check on the {report,periodic}_interval
options are no more, but this has been true since cfg was first added.
Change-Id: Ia58c8f0aaf61628bb55b1b8485118a2a9852ed17
Possibly through copy-paste errors, some sqlalchemy session keyword args
made it into the db api. Some aren't even passed in to the IMPL's
equivalent function, and a db.api client has no sensible way of creating
such a session to pass in. Therefore this patch removes them.
Change-Id: I75237b542bdf4f75c1a07ae38bf485e0ff080339
This commit introduces the OSAPI admin extensions for host aggregates.
This is part of a series of commits that have started with change:
https://review.openstack.org/#change,3035
Change-Id: If0c92dca7d6f5d794f84bdb2adc172c55dec6e74
This commit introduces the first cut of integration between the OSAPI
Admin extensions for host aggregates and the virt layer.
This is part of a series of commits that have started with change:
https://review.openstack.org/#change,3035
Change-Id: I75d8b616e3b8f8cef75d40d937e0dce9f29b16db
These problems were introduced in https://review.openstack.org/2918
* nova-manage needs the change from local_gb to root_gb/ephemeral_gb.
* fixes 'nova-manage flavor ...'
* fixes 'nova-manage service describe_resource ...'
Change-Id: I63040359a425aac3ef7a0a84e6834b1dfe3a8790
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
Querying for resource usage within a given time range seems to have a
logic flaw: it will only report instances that have run the entire
length of the specified range.
AIUI What we really want is any instance that spent any time consuming
resources at any point in the specified range. Fix the logic to
implement this.
v2:
Update function comments as well
Change-Id: I4fa567982457e5f447ec33cf3d96457f50d71d86
This extension is a step towards deprecating openstackx for horizon.
Most of the extension code is based on the equivalent in openstackx.
v2:
s/lifecycle/manage/ for all bits
Address Pádraig style issues
Drop purge API option
Adjust now inaccurate comment in DB api
Make extension admin_only
Extend existing /flavors namespace rather than os-flavor-lifecycle
Only allow API access from admin user
v3:
Some pep8 fixes
v4:
Adjust to root_gb, ephemeral_gb changes
Drop admin_only (it's on the way out AIUI)
Change-Id: I3fdfccdd8e7337e1759f5875c3b15fa9954371ef
In the interests of improving DRY in the sqlalchemy db backend API,
abstract out _exact_match_filter().
Change-Id: Ic381a071005dced6989e9e9696930fd85b6d5d46
Implements blueprint disk-configuration-parity
This change splits local_gb into root_gb and ephemeral_gb. libvirt
interpreted local_gb as what ephemeral_gb is now, whereas XenAPI
interpreted local_gb as what root_gb is now.
Change-Id: I496600991bac1e990326d4ded1607fee08209d68
The table represents the current state of compute nodes and will be
used by the scheduler when selecting a host.
Re: https://blueprints.launchpad.net/nova/+spec/scaling-zones
This is just the db & notification portion of the branch. The scheduler
portion is being deferring until comstuds branch gets merged since it
conflicts heavily.
NOTE: Compute notifications are now two-part.
There is a compute.instance.XXX.start event and a compute.instance.XXX.end
message instead of the previous compute.instance.XXX event (which is
the same as the .end message)
Change-Id: Ia8e68680cb0924c59df84f2eec858febf4926d65
Since keys are just the domain name, we need to be able
to reuse them. That means we have to do a real record
deletion to free up namespace rather than just mark the
records as deleted.
For blueprint public-and-private-dns.
Change-Id: If47e961cf2cb977d297b506bd397f1a438499f18
distributed scheduler isn't checking service_is_up or
services['disabled'] due to filters not having access to service.
Fixed both. Since ec2 API also uses service_down_time, I moved
service_is_up() into utils and made ec2 use it.
Change-Id: I0321844a47031b2de4d8738e032a4634edd1e945
Adding this functionality required the existing DNS api
to be rearranged considerably.
Nova needs to track some information about domains that is
outside the scope of the DNS driver, specifically the availability
zone of a private domain and the project of a public domain.
In order to track those attributes, this patch adds a new table
to the Nova database, dns_domains.
This patch perpetuates some naming ambiguities (e.g. zone vs. domain).
A future renaming patch will sort all this out.
For blueprint public-and-private-dns.
Change-Id: I80865207d34ab7c6e2afc5638863a299b3913f8e
This is the first of a series of commits that add the host-aggregates capability,
as described on the blueprint page.
This commit, more precisely, introduces changes to the Nova model: model classes
related to aggregates have been added, as well as DB API methods to interact with
the model; a sqlalchemy migration script plus a bunch of tests are also part of
this changeset.
Commits that will follow are going to add:
- Extensions to OSAPI Admin, and related python_novaclient mappings
- Implementation of the XenAPI virt layer
- Integration of OSAPI and virt layer, via the compute_api
- smoketests
- openstack-manuals documentation
These commits will be pushed for review not necessarily in this exact order.
Change-Id: Iceb27609dc53bf4305c02d7cbc436fba4c4a7256
Fixes LP853979
Remove the FK references for network data.
Remove unused db functions that used the FK's
Update db functions to not joinload
Update notification to optionally take network_info if compute has it
Update EC2 Api to use the network cache, falling back to rpc.call
Remove test_instance_get_project_vpn_joins which tests calls not used
Change-Id: I1a01ccc5ebcf7efeafe014af62be893325bb0825
This will allow us to mark deprecated classes and functions/methods as
such. A warning is issued each time a deprecated function/method is
called, or when a deprecated class is instantiated, or when any class
or static method on a deprecated class is called.
Change-Id: I4b5858492bc14768ac2e12c542bc343962761e34
* Implements blueprint multiple-floating-ip-ranges
* Adds pool and interface fields to floating ip tables
* Adds extension to get a list of available pools
* Optionally allows a pool to be specified when allocating
* Changes nova-manage command to allow pool and interface
* Ip binding uses the interface from table instead of flag
* Adds default pool flag to use when pool is not specified
* updates test to work with new fields
* adds tests for extension
Change-Id: Ieb4cbbf07b211697d08178b1cf2252caf75049a2
* adds a boolean return representing whether file was reloaded
* ensures file is actually closed by using a context manager
Change-Id: I4d998c34caa6dde65aaf780c188778477b7f6753