Commit Graph

60062 Commits

Author SHA1 Message Date
Ghanshyam Mann d97af33c06 Enable new defaults and scope checks by default
As discussed in PTG, we need to test the new RBAC in the
integrated gate and accordingly enable the new defaults
and scope check by default. A new integrated testing job
has been added and results show that the new defaults and
scope checks are working fine. During testing, we found a
few bugs in neutron policies but all are fixed now.

enforce_scope and enforce_new_defaults are oslo policy config
options but they are per service level and the default value
can be overridden. Oslo policy 3.11.0 version allows to override
the default value for these config options[1] so upgrading the
oslo policy version in requirements.txt

Depends-On: https://review.opendev.org/c/openstack/devstack/+/869781
Depends-On: https://review.opendev.org/c/openstack/placement/+/869525

[1] https://github.com/openstack/oslo.policy/blob/3.11.0/oslo_policy/opts.py#L125

Change-Id: I977b2daedf880229c8d364ca011f2ea965b86e3a
2023-01-10 23:37:13 -06:00
Balazs Gibizer 5e5b6751d3 Remove basepython def from tox.ini
It seems that with tox 4.2.6 the missing interpreter error was fixed but
the generative testenv feature is broken and the
[testenv:functional{,-py38,-py39,-py310}] format is leads to missing
interpreter error. It is due to a conflict between basepython = python3
and the version fragment in the generative target suppressed by
ignore_basepython_conflict = true.

This patch removes basepython = python3 assuming that developers already
switched for python3 in their environment as python2.7 is EOL.

Also we took the opportunity to add the global constraints via the
install_command instead of deps as deps is not used during the
installation of the editable package.

Change-Id: I258a7c13434b29402804181dea275b42d5539df0
2023-01-09 16:17:30 +01:00
Zuul ba9d4c909b Merge "Support cold migrate and resize with PCI tracking in placement" 2023-01-05 14:40:02 +00:00
Zuul c18f6f9a4f Merge "doc: soft delete and shadow tables" 2023-01-03 18:55:21 +00:00
Zuul 00a62d218d Merge "Func test for PCI in placement scheduling" 2022-12-21 19:20:17 +00:00
Zuul 1c46c4e9e5 Merge "Store allocated RP in InstancePCIRequest" 2022-12-21 19:20:09 +00:00
Zuul afc2ebacac Merge "[doc] Fix BFV Rescue trait name in microversion" 2022-12-21 16:52:24 +00:00
Balazs Gibizer e667a7f8d8 Support cold migrate and resize with PCI tracking in placement
This patch adds support for cold migrate, and resize with PCI
devices when the placement tracking is enabled.

Same host resize, evacuate and unshelve will be supported by subsequent
patches. Live migration was not supported with flavor based PCI requests
before so it won't be supported now either.

blueprint: pci-device-tracking-in-placement
Change-Id: I8eec331ab3c30e5958ed19c173eff9998c1f41b0
2022-12-21 16:17:34 +01:00
Balazs Gibizer 1462883dcc Func test for PCI in placement scheduling
This patch adds various functional test cases showing that the placement
allocation candidate restricts the available PCI pools during the run of
the filter scheduler and that the placement PCI allocation later drives
the PCI claim code in the compute.

blueprint: pci-device-tracking-in-placement
Change-Id: If46ee131a9e5499ae91da93ddaac88aa49182f56
2022-12-21 16:17:34 +01:00
Balazs Gibizer f86f1800f0 Store allocated RP in InstancePCIRequest
After the scheduler selected a target host and allocated an allocation
candidate that is passed the filters nova need to make sure that PCI
claim will allocate the real PCI devices from the RP which is allocated
in placement. Placement returns the request group - provider mapping for
each allocation candidate so nova can map which InstancePCIRequest was
fulfilled from which RP in the selected allocation candidate. This
mapping is then recorded in the InstancePCIRequest object and used
during the PCI claim to filter for PCI pools that can be used to claim
PCI devices from.

blueprint: pci-device-tracking-in-placement
Change-Id: I18bb31e23cc014411db68c31317ed983886d1a8e
2022-12-21 16:17:34 +01:00
Zuul b9a49ffb04 Merge "Filter PCI pools based on Placement allocation" 2022-12-20 19:04:59 +00:00
Zuul 72281b9f93 Merge "Add a hacking rule for the setDaemon method" 2022-12-20 16:25:03 +00:00
Zuul 7f7aabd26e Merge "Improving logging at '_allocate_mdevs'." 2022-12-20 16:24:55 +00:00
Zuul 3ec23d3f37 Merge "Update gate jobs as per the 2023.1 cycle testing runtime" 2022-12-20 16:24:47 +00:00
Zuul a2139db1ff Merge "Doc: Fix list servers detailed response param" 2022-12-20 16:07:24 +00:00
Zuul 7db43d8f38 Merge "libvirt: fix typo in test_config" 2022-12-20 16:07:16 +00:00
Zuul 6a67b5f03f Merge "db: Drop redundant indexes on instances and console_auth_tokens tables" 2022-12-20 16:07:00 +00:00
Zuul aec72ddeb6 Merge "Modify the command of getting serial console" 2022-12-20 15:05:36 +00:00
Zuul 9881e8d629 Merge "Correct reST markup in config help string" 2022-12-20 15:05:27 +00:00
Zuul fe839970cf Merge "fix typo in architecture document" 2022-12-20 15:03:36 +00:00
Zuul 9d0b55b70b Merge "Fix link to Cyborg device profiles API" 2022-12-20 15:03:28 +00:00
Zuul a077a5f5dd Merge "Add os_vif in nova-config-generator" 2022-12-20 15:03:18 +00:00
Zuul 12fd902ada Merge "add header alingment for PrettyTable 3.4.0" 2022-12-20 15:03:10 +00:00
Zuul b54beee429 Merge "Make allocation candidates available for scheduler filters" 2022-12-17 17:12:31 +00:00
John Garbutt 8a476061c5 Ironic: retry when node not available
After a baremetal instance is deleted, and its allocation is removed
in placement, the ironic node might start cleaning. Eventually nova
will notice and update the inventory to be reserved.
During this window, a new instance may have already picked this
ironic node.

When that race happens today the build fails with an error:
"Failed to reserve node ..."

This change tries to ensure the remaining alternative hosts are
attempted before aborting the build.
Clearly the race is still there, but this makes it less painful.

Related-Bug: #1974070
Change-Id: Ie5cdc17219c86927ab3769605808cb9d9fa9fa4d
2022-12-15 16:33:43 +00:00
Zuul 2f4feeabc2 Merge "Map PCI pools to RP UUIDs" 2022-12-15 13:10:45 +00:00
Zuul d7de0c121a Merge "Ironic nodes with instance reserved in placement" 2022-12-14 14:11:40 +00:00
Zuul 8b4104f9f7 Merge "Split PCI pools per PF" 2022-12-13 17:33:49 +00:00
Zuul 035b1c6fbe Merge "Support resource_class and traits in PCI alias" 2022-12-13 17:33:41 +00:00
Zuul 0ac870c8fa Merge "Create RequestGroups from InstancePCIRequests" 2022-12-13 17:33:34 +00:00
Zuul e40ac0c798 Merge "Support multiple config file with mod_wsgi" 2022-12-12 15:16:14 +00:00
Bence Romsics 3420b77f62 doc: soft delete and shadow tables
While collecting information because of a question I received
about soft delete and shadow tables I realized that the documentation
contains bits and pieces here and there, but I couldn't find more.
This change summarizes what I found from docs and asking around.
I hope you find it useful.

Change-Id: I5ff90224cc27c57dc463604559d25298ed7b3f98
2022-12-09 09:15:11 +01:00
Sean Mooney 73fe84fa0e Support multiple config file with mod_wsgi
Unlike uwsgi, apache mod_wsgi does not support passing
commandline arguments to the python wsgi script it invokes.

As a result while you can pass --config-file when hosting the
api and metadata wsgi applications with uwsgi there is no
way to use multiple config files with mod_wsgi.

This change mirrors how this is supported in keystone today
by intoducing a new OS_NOVA_CONFIG_FILES env var to allow
operators to optional pass a ';' delimited list of config
files to load.

This change also add docs for this env var and the existing
undocumented OS_NOVA_CONFIG_DIR.

Closes-Bug: 1994056
Change-Id: I8e3ccd75cbb7f2e132b403cb38022787c2c0a37b
2022-12-07 12:36:32 +01:00
Zuul bee679751b Merge "Adds check for VM snapshot fail while quiesce" 2022-12-03 13:11:20 +00:00
Zuul d05f9ef0dc Merge "Adds regression functional test for 1980720" 2022-12-01 08:45:51 +00:00
Zuul 9e2fdb4470 Merge "extend_volume of libvirt/volume/fc should not use device_path" 2022-11-29 22:02:15 +00:00
Zuul 0ac487fd6c Merge "Don't provide MTU value in metadata service if DHCP is enabled" 2022-11-29 22:02:04 +00:00
Zuul 5d66c89634 Merge "Handle mdev devices in libvirt 7.7+" 2022-11-29 21:52:22 +00:00
Slawek Kaplonski 6bdc79af30 Don't provide MTU value in metadata service if DHCP is enabled
For networks with subnets with enabled DHCP service don't provide
mtu value in the metadata. That way cloud-init will not configure it
"statically" in e.g. netplan's config file and guest OS will use MTU
value provided by the DHCP service.


Closes-Bug: #1899487
Change-Id: Ib775c2210349b72b3dc033554ac6d8b35b8d2d79
2022-11-29 15:12:24 +00:00
Amit Uniyal c8d5397b0a Adds check for VM snapshot fail while quiesce
Added check if quiesce fails because libvirt fails to connect with
qemu guest agent inside instance

Closes-Bug: #1980720
Change-Id: I134a4060ace2678f76ae3606bf117c07194a8d92
2022-11-29 14:09:53 +00:00
Amit Uniyal 50802572dc Adds regression functional test for 1980720
Related-Bug: #1980720
Change-Id: I223995b5f8cb72cb47d04e969819efe4885dfc88
2022-11-29 14:08:41 +00:00
Zuul 4b8729011a Merge "Temporary skip some volume detach test in nova-lvm job" 2022-11-29 11:08:29 +00:00
Ghanshyam Mann 2aa779016d Temporary skip some volume detach test in nova-lvm job
A few tests related to volume detach are timeout in
nova-lvm job (failing 100%[1]). Root cause of timeout is not
known and it may take time to find and fix the issue. To unblock
gate and keep runing rest of the tests in lvm job, let's skip
the failing tests until they are fixed.

Related-Bug: #1998148

[1] https://zuul.opendev.org/t/openstack/builds?job_name=nova-lvm&branch=master&skip=0

Change-Id: Id29ce352df84168d0a45512e2c59820aefc75943
2022-11-28 17:54:45 -06:00
Zuul 2d774541c5 Merge "Bump minimum version of os-vif to 3.1.0" 2022-11-24 10:23:28 +00:00
Zuul 17d8b92ed1 Merge "Reproducer for bug 1951656" 2022-11-23 19:59:33 +00:00
Ghanshyam Mann 58500c9967 Update gate jobs as per the 2023.1 cycle testing runtime
As per 2023.1 testing runtime[1], we need to test on Ubuntu
Jammy (which will be taken care by tempest and devstack patches
to move base jobs to Jammy) and at least single job to run on
Ubutnu Focal (for smooth upgrade). Also, python 3.10 testing is
voting now.

This commit adds a new job to run on focal which can be removed
in future cycle when testing runtime drop the requirement of Focal
testing. Also, make python 3.10 functional and unit test job as voting
(openstack-tox-py310 is running as part of generic template so we do
not need to explicitly add that)

[1] https://governance.openstack.org/tc/reference/runtimes/2023.1.html

Change-Id: Ia43f73dba00b0b5932939bcc7d11b97a83072ee3
2022-11-22 13:44:26 -06:00
Zuul 3675dbf7a4 Merge "Update contributor guide for 2023.1 Antelope" 2022-11-21 21:50:41 +00:00
Billy Olsen a28b907c4f Handle mdev devices in libvirt 7.7+
Libvirt 7.7 changed the mdev device naming to include the parent PCI
device when listing node devices. The domain, however, will still only
see the UUID and not see the parent PCI device. Changing the parsing to
simply drop the PCI identifier is not enough as the device cannot be
found when attempting to lookup the new ID.

Modify the Libvirt Driver's _get_mediated_device_information to tolerate
different formats of the mdev name. This first uses the legacy behavior
by trying to lookup the device name that is passed in (typically
mdev_<uuid> format) and if that is not found, iterates the list of mdev
node devices until the right UUID is found and selects that one.

Note that the lookup of the mdev device by UUID are needed in order
to keep the ability to recreate assigned mediated devices on a reboot of
the compute node.

Additionally, the libvirt utils parsing method mdev_name2uuid, has
been updated to tolerate both mdev_<uuid> and mdev_<uuid>_<pciid>
formats.

Closes-Bug: 1951656

Change-Id: Ifed0fa16053228990a6a8df8d4c666521db7e329
2022-11-18 16:16:18 +01:00
Sylvain Bauza 1852019747 Reproducer for bug 1951656
Due to a new mdev naming, we can't parse it.

Change-Id: I0f785178b132dfef668829558dea9f7e674abadb
Related-Bug: #1951656
2022-11-18 16:15:01 +01:00
Zuul 596772d522 Merge "Replace "db archive" with "db archive_deleted_raws"" 2022-11-17 15:11:03 +00:00