3586 Commits

Author SHA1 Message Date
Zuul
b6d0e55746 Merge "doc: pretty up return code table for sync_aggregates" 2019-08-29 13:45:13 +00:00
Zuul
eea4e6b206 Merge "docs: pretty up return code table or heal_allocations" 2019-08-29 13:45:03 +00:00
Zuul
703fb5c73e Merge "Add a "Caveats" section to the eventlet profiling docs" 2019-08-29 13:44:53 +00:00
Zuul
21df56a37a Merge "Docs and functional test for max_local_block_devices" 2019-08-29 13:44:38 +00:00
Zuul
9c2b1be0d6 Merge "nova-manage db archive_deleted_rows is not multi-cell aware" 2019-08-28 20:59:18 +00:00
Zuul
67ee187c06 Merge "Remove 'hw:cpu_policy', 'hw:mem_page_size' extra specs from API samples" 2019-08-28 16:12:39 +00:00
zhangbailin
27b6c18c66 Specify availability_zone to unshelve
This adds support, in a new microversion, for specifying an availability
zone to the unshelve server action when the server is shelved offloaded.

Note that the functional test changes are due to those tests using the
"latest" microversion where an empty dict is not allowed for unshelve
with 2.77 so the value is changed from an empty dict to None.

Implements: blueprint support-specifying-az-when-restore-shelved-server
Closes-Bug: #1723880

Change-Id: I4b13483eef42bed91d69eabf1f30762d6866f957
2019-08-27 12:57:10 -04:00
Stephen Finucane
b01676c418 Remove 'hw:cpu_policy', 'hw:mem_page_size' extra specs from API samples
In a future change, the use of 'hw:cpu_policy' will require a host to
report PCPU inventory. Rather than modify the fake driver used in these
tests to report such inventory, just use a different extra spec,
'hw:numa_nodes'. This has the added bonus of being supported by both the
libvirt and Hyper-V virt drivers, unlike 'hw:cpu_policy' and
'hw:mem_page_size', which are only supported by the libvirt virt driver.

Change-Id: Id203dc07f08557b1b094ec72e1df3493ec9524b1
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2019-08-27 17:00:46 +01:00
Chris Dent
6fa5bd43fb Add a "Caveats" section to the eventlet profiling docs
There are some bits of wisdom and workarounds required to have a
positive experience when profiling in an eventlet environment.

This patch adds a section where such wisdom can accumlate, and
also provides a workaround for a specific problem when profiling
nova-compute.

Change-Id: Id6362f20c831c43e4d3316fe573e28c6b891d459
2019-08-27 11:41:31 +01:00
Kevin_Zheng
97b8cb3f58 nova-manage db archive_deleted_rows is not multi-cell aware
The archive_deleted_rows cmd depend on DB connection config from config
file, and when applying super-conductor mode, there are several config
files for different cells. If so, the command can only archive rows in
cell0 DB as it only reads the nova.conf

This patch added code that provides --all-cells parameter to the
command and read info for all cells from the api_db and then archive
rows across all cells.

The --all-cells parameter is passed on to the purge command when
archive_deleted_rows is called with both --all-cells and --purge.

Co-Authored-By: melanie witt <melwittt@gmail.com>

Change-Id: Id16c3d91d9ce5db9ffd125b59fffbfedf4a6843d
Closes-Bug: #1719487
2019-08-27 06:01:58 +00:00
Zuul
781f47b243 Merge "Document map_instances return codes in table format" 2019-08-26 14:31:23 +00:00
Zuul
5e1de8ac24 Merge "Change nova-manage unexpected error return code to 255" 2019-08-26 14:31:15 +00:00
Zuul
f4343f7b5c Merge "Document archive_deleted_rows return codes" 2019-08-26 14:26:38 +00:00
Matt Riedemann
364fa30062 Docs and functional test for max_local_block_devices
We get questions about if it's possible to configure nova to
always use cinder for root volumes even if the user isn't
explicitly booting from volume. This change adds a FAQ entry
about that to the block device mappings docs and also suggests
a way to force users to use volume-backed servers using the
max_local_block_devices option. The config option help for that
option is also cleaned up since --image is a CLI option but we
should stick to REST API parameters in descriptions and the
default mentioned in the help already gets rendered by oslo.config.
Finally, a simple functional test is added to assert the workaround
mentioned in the docs.

Change-Id: I3e77796b051e8d007fefe2eea06d38e8265e8272
2019-08-23 12:12:08 -04:00
Zuul
a55ae413ea Merge "doc: remove confusing docs about aggregate allocation ratios" 2019-08-22 20:13:47 +00:00
Zuul
efbe94cd7d Merge "Remove deprecated [neutron]/url option" 2019-08-22 19:57:32 +00:00
Matt Riedemann
a637d6e071 doc: pretty up return code table for sync_aggregates
This just changes the bullet format to a more appealing
table format and is consistent with the other commands
in here that use a table format for documenting return
codes.

Change-Id: I427e64f49f152231810ca48908f1ceff5b8a41d9
2019-08-22 12:57:11 -04:00
Matt Riedemann
73ff2a7878 docs: pretty up return code table or heal_allocations
This just converts the bullet list to the prettier table
format like archive_deleted_rows and map_instances use.

Change-Id: I33b78a4d55c9a34fca6ab20b2b9e8db41d747da5
2019-08-22 12:52:57 -04:00
Zuul
44e5c88b22 Merge "FUP for I5576fa2a67d2771614266022428b4a95487ab6d5" 2019-08-22 12:15:08 +00:00
Zuul
1ae57fe04d Merge "Deprecate Aggregate[Core|Ram|Disk]Filters" 2019-08-21 22:27:13 +00:00
Matt Riedemann
7675e28bd1 Document map_instances return codes in table format
This pretties up the return code documentation for the
map_instances command and while in here formats the
--max-count and --reset option mentions in the description.

Change-Id: I03d67e75f5633f4b21bf753698674747a0ed06a8
2019-08-21 17:15:41 -04:00
Matt Riedemann
df2845308d Change nova-manage unexpected error return code to 255
If any nova-manage command fails in an unexpected way and
it bubbles back up to main() the return code will be 1.
There are some commands like archive_deleted_rows,
map_instances and heal_allocations which return 1 for flow
control with automation systems. As a result, those tools
could be calling the command repeatedly getting rc=1 thinking
there is more work to do when really something is failing.

This change makes the unexpected error code 255, updates the
relevant nova-manage command docs that already mention return
codes in some kind of list/table format, and adds an upgrade
release note just to cover our bases in case someone was for
some weird reason relying on 1 specifically for failures rather
than anything greater than 0.

Change-Id: I2937c9ef00f1d1699427f9904cb86fe2f03d9205
Closes-Bug: #1840978
2019-08-21 17:03:11 -04:00
Matt Riedemann
561ed634f4 Document archive_deleted_rows return codes
The archive_deleted_rows command has a specific set of return
codes for both errors and flow control so we should document
those in the CLI guide.

A FIXME is left in the code because of the odd case of when
you could get 1 back meaning "we archived some stuff" or
"something really bad happened".

Change-Id: Id10bd286249ad68a841f2bfb3a3623b429b2b3cc
2019-08-21 16:51:43 -04:00
Matt Riedemann
8f53a051cc Remove deprecated [neutron]/url option
The url option was deprecated in Queens:

  I41724a612a5f3eabd504f3eaa9d2f9d141ca3f69

The same functionality is available in the
endpoint_override option so tests and docs
are updated to use that where they were using
url before.

Note that because the logic in the get_client
method changed, some small changes were made to
the test_withtoken and test_withtoken_context_is_admin
unit tests to differentiate from when there is a
context with a token that is not admin and an
admin context that does not have a token which
was otherwise determined by asserting the default
region name.

Change-Id: I6c068a84c4c0bd88f088f9328d7897bfc1f843f1
2019-08-21 17:55:56 +00:00
Matt Riedemann
69faaddc6c FUP for I5576fa2a67d2771614266022428b4a95487ab6d5
This addresses a single review comment for the vPMU
flavor extra spec docs [1].

[1] https://review.opendev.org/#/c/671338/13/doc/source/user/flavors.rst@379

Change-Id: Id8ba982b0efa92630be60f79c6ecb67f7fd79100
2019-08-21 11:45:51 -04:00
Sean Mooney
588194d785 Deprecate Aggregate[Core|Ram|Disk]Filters
The Aggregate[Core|Ram|Disk]Filters have not worked
correctly since ocata, this change deprecates them
for removal next cycle.
http://lists.openstack.org/pipermail/openstack-dev/2018-January/126283.html

Related-Bug: #1804125
Change-Id: Ibfbfdae9e6ec93f772631a84e8969f4e11da8aee
2019-08-20 16:45:23 -04:00
Sean Mooney
326bc658ee Libvirt: add support for vPMU configuration.
This change adds the ablity for a user or operator to contol
the virtualisation of a performance monitoring unit within a vm.
This change introduces a new "hw:pmu" extra spec and a corresponding
image metadata property "hw_pmu".

The glance image metadata doc will be updated seperately by:
https://review.opendev.org/#/c/675182

Change-Id: I5576fa2a67d2771614266022428b4a95487ab6d5
Implements: blueprint libvirt-pmu-configuration
2019-08-20 14:41:57 +00:00
Matt Riedemann
77efc084fc doc: remove confusing docs about aggregate allocation ratios
Change Ifaf596a8572637f843f47daf5adce394b0365676 added a note
about the behavior change in Ocata where allocation ratios
set on host aggregates was ignored because of placement resource
provider allocation ratios being used.

Later, change I7d8e822cd40dccaf5244e2cd95fa1af43fa9ed87 added
a lot more detail about allocation ratios in the scheduler docs
including the initial* allocation ratio config options. The note
from the previous change was moved and as a result leads to some
confusion since the doc starts by saying essentially, "you can
use these aggregate filters to manage allocation ratios on a set
of hosts" and then the immediate note says essentially, "oh btw
that doesn't work since ocata, sorry!".

To avoid the confusion, this simply removes the part about how
the aggregate filters can be used to manage allocation ratios.

Change-Id: I62710b0b8c098cca3f67020f4a6da5e684115414
Related-Bug: #1804125
2019-08-20 10:07:38 -04:00
Surya Seetharaman
62f6a0a1bc API microversion 2.76: Add 'power-update' external event
This patch adds a new external event called "power-update"
through which ironic will convey all (power_off and power_on)
power state changes (running -> shutdown or shutdown -> running
will be the only ones handled by nova and the rest will be ignored)
on a physical instance to nova. The database will be updated
accordingly to reflect the real vm_state and power_state of the
instance. This way nova will not be able to enforce
an incorrect power state on the physical instance during
the periodic "sync_power_states" task.

Implements blueprint nova-support-instance-power-update
Story: 2004969
Task: 29423

Change-Id: I2b292050cc3ce5ef625659f5a1fe56bb76072496
2019-08-15 13:19:44 -04:00
Ghanshyam Mann
b26bc7fd7a Multiple API cleanup changes
This microversion implements below API cleanups:

1. 400 for unknown param for query param and for request body.

2. Making server representation always consistent among all APIs
   returning the complete server representation.

3. Change the default return value of ``swap`` field from the empty string
   to 0 (integer) in flavor APIs.

4. Return ``servers`` field always in the response of GET
   hypervisors API even there are no servers on hypervisor

Details: https://specs.openstack.org/openstack/nova-specs/specs/train/approved/api-consistency-cleanup.html

Partial-Implements: blueprint api-consistency-cleanup

Change-Id: I9d257a003d315b84b937dcef91f3cb41f3e24b53
2019-08-12 08:52:38 -05:00
Zuul
e373761b49 Merge "Cache host to cell mapping in HostManager" 2019-08-12 12:55:46 +00:00
Zuul
790f628883 Merge "Add a document that describes profiling eventlet services" 2019-08-12 10:05:45 +00:00
Chris Dent
886142b17a Add a document that describes profiling eventlet services
Profiling eventlet using services is a bit different from standard
situations so here is a document that tries to explain the basics
on how to get started doing it.

Change-Id: If8c34653285f07c5cc1abccabfec16f18daafdde
2019-08-09 11:37:41 +01:00
Eric Fried
9ffdc0bcbc Use :oslo.config:* in nova-manage doc
Fix up some sphinx-isms in nova-manage.rst:

- Replace ``[group]/option`` with :oslo.config:option:`group.option`
- Replace ``[group]`` with :oslo.config:group:`group`
- Replace `default role used for italics` with *explicit italics*
- Fix up a mention of [placement_database] -- for which we can't use
  :oslo.config:* because that section doesn't exist anymore -- to
  pertain only to Rocky & Stein, where it did exist.

Change-Id: I9cfb9d0b20d4dfc18236a2d528a8f65534c9a263
2019-08-07 17:55:32 -05:00
Matt Riedemann
2c5134d5f3 Don't mention CONF.api_database.connection in user-facing messages/docs
CONF.api_database.connection is a variable in code, not something
an operator needs to know what it means, so this changes that
mention in the docs and error message for the nova-manage db
archive_deleted_rows command.

Change-Id: If27814e0006a6c33ae6270dff626586c41eafcad
Closes-Bug: #1839391
2019-08-07 17:29:51 -04:00
Zuul
af40e3d1a6 Merge "tox: Keeping going with docs" 2019-08-07 20:39:56 +00:00
Matt Riedemann
3a69fdb333 Cache host to cell mapping in HostManager
If the instances per host are not cached in the HostManager
we lookup the HostMapping per candidate compute node during
each scheduling request to get the CellMapping so we can target
that cell database to pull the instance uuids on the given host.

For example, if placement returned 20 compute node allocation
candidates and we don't have the instances cached for any of those,
we'll do 20 queries to the API DB to get host mappings.

We can improve this by caching the host to cell uuid after the first
lookup for a given host and then after that, get the CellMapping
from the cells cache (which is a dict, keyed by cell uuid, to the
CellMapping for that cell).

Change-Id: Ic6b1edfad2e384eb32c6942edc522ee301123cbc
Related-Bug: #1737465
2019-08-06 16:20:23 -04:00
Matt Riedemann
d780216c6a doc: fix physets typo
I'm pretty sure this was meant to be physnets given the
context and this was added with Ide262733ffd7714fdc702b31c61bdd42dbf7acc3
which is about provider physical network affinity to NUMA nodes.

Change-Id: Ia9282325441ec42af6b03cda704b1cc7bac8d9f4
2019-08-05 14:07:59 -04:00
Wang Huaqiang
4945e6dbd4 doc: correct the information of 'cpu_map'
libvirt has split the CPU feature flags file 'cpu_map.xml' into
a bunch of flag files for each CPU model, which are stored under
directory 'src/cpu_map/'.

Update this change accordingly.

Change-Id: Id45587adb6ecd8e0bdef344c90979eaea61e61b8
2019-08-02 20:19:18 +08:00
Matt Riedemann
2e57826a77 Remove Request Spec Migration upgrade status check
The "Request Spec Migration" upgrade status check was added
in Rocky [1] and the related online data migration was removed
in Stein [2]. Now that we're in Train we should be able to
remove the upgrade status check.

The verify install docs are updated to remove the now-removed
check along with "Console Auths" which were removed in Train [3].

[1] I1fb63765f0b0e8f35d6a66dccf9d12cc20e9c661
[2] Ib0de49b3c0d6b3d807c4eb321976848773c1a9e8
[3] I5c7e54259857d9959f5a2dfb99102602a0cf9bb7

Change-Id: I6dfa0b226ab0b99864fc27209ebb7b73e3f73512
2019-07-30 12:58:39 -04:00
Dongcan Ye
e8f5641aef Fix wrong huge pages in doc
Change-Id: Ic3839eeca02c50451c884d23d313a135f04994ba
Related-Bug: #1816454
2019-07-29 09:53:38 +00:00
Zuul
054bf13a78 Merge "Remove 'nova.virt.driver.ComputeDriver.estimate_instance_overhead'" 2019-07-25 18:16:39 +00:00
Stephen Finucane
97096c8e4a Remove 'nova.virt.driver.ComputeDriver.estimate_instance_overhead'
With the removal of the Core, Ram and Disk filters in change
I8a0d332877fbb9794700081e7954f2501b7e7c09, there's now only a single
caller for the 'estimate_instance_overhead' function. This call results
in the 'memory_mb_used', 'local_gb_used', 'vcpus_used', 'free_ram_mb'
and 'free_disk_gb' fields of a compute nodes 'ComputeNode' object being
modified when calculating usage as part of the resource tracker to
include driver-specific overhead. However, these fields are no longer
used for for anything except logging and the 'os-hypervisors' API. Since
overhead is not reflected in placement (and therefore the scheduler),
reporting them as part of the various usage values for both logging and
that API is actually a bit of a lie and is likely to cause confusion
among users. Remove the whole thing and make our logs and the
'os-hypervisors' API better match what's stored in placement.

Change-Id: I033e8269194de54432079cbc970431e3dcea7ce5
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2019-07-24 16:26:01 +01:00
Zuul
ab34c941be Merge "Remove deprecated Core/Ram/DiskFilter" 2019-07-23 23:36:06 +00:00
Zuul
9dbf7b7ca9 Merge "Drop delete_build_requests_with_no_instance_uuid online migration" 2019-07-23 22:43:45 +00:00
Zuul
383a4cf371 Merge "Update api-ref location" 2019-07-23 16:22:27 +00:00
Stephen Finucane
78645e61c6 Remove deprecated Core/Ram/DiskFilter
These were deprecated during Stein [1] and can now be removed, lest they
cause hassle with the PCPU work. As noted in [1], the aggregate
equivalents of same are left untouched for now.

[1] https://review.opendev.org/#/c/596502/

Change-Id: I8a0d332877fbb9794700081e7954f2501b7e7c09
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2019-07-23 07:49:41 -07:00
Zuul
4781ef3321 Merge "Update AZ admin doc to mention the new way to specify hosts" 2019-07-23 13:28:31 +00:00
Zuul
8fc20874b8 Merge "nova-manage: heal port allocations" 2019-07-22 21:59:30 +00:00
Andreas Jaeger
dbe6321537 Update api-ref location
The api documentation is now published on docs.openstack.org instead
of developer.openstack.org. Update all links that are changed to the
new location.

Note that Neutron publishes to api-ref/network, not networking anymore.

Note that redirects will be set up as well but let's point now to the
new location.

For details, see:
http://lists.openstack.org/pipermail/openstack-discuss/2019-July/007828.html

Change-Id: Id2cf3aa252df6db46575b5988e4937ecfc6792bb
2019-07-22 19:17:28 +02:00