Merge "Add new role parameter NovaLibvirtNumPciePorts"

This commit is contained in:
Zuul 2019-06-06 00:35:03 +00:00 committed by Gerrit Code Review
commit ed90e20699
2 changed files with 25 additions and 0 deletions

View File

@ -283,6 +283,17 @@ parameters:
type: string
default: 'regionOne'
description: Keystone region for endpoint
NovaLibvirtNumPciePorts:
description: >
Set `num_pcie_ports` to specify the number of PCIe ports an
instance will get.
Libvirt allows a custom number of PCIe ports (pcie-root-port controllers) a
target instance will get. Some will be used by default, rest will be available
for hotplug use.
default: 16
type: number
tags:
- role_specific
resources:
@ -344,6 +355,7 @@ resources:
nfs_share: NovaNfsShare
nfs_options: NovaNfsOptions
nfs_vers: NovaNfsVersion
nova::compute::libvirt::num_pcie_ports: NovaLibvirtNumPciePorts
- values: {get_param: [RoleParameters]}
- values:
NovaVcpuPinSet: {get_param: NovaVcpuPinSet}
@ -363,6 +375,7 @@ resources:
NovaNfsShare: {get_param: NovaNfsShare}
NovaNfsOptions: {get_param: NovaNfsOptions}
NovaNfsVersion: {get_param: NovaNfsVersion}
NovaLibvirtNumPciePorts: {get_param: NovaLibvirtNumPciePorts}
conditions:
enable_instance_ha: {equals: [{get_param: EnableInstanceHA}, true]}

View File

@ -0,0 +1,12 @@
---
features:
- |
Add role parameter NovaLibvirtNumPciePorts which sets `libvirt/num_pcie_ports`
to specify the number of PCIe ports an instance will get.
Libvirt allows a custom number of PCIe ports (pcie-root-port controllers) a
target instance will get. Some will be used by default, rest will be available
for hotplug use. When using the 'q35' machine type, by default, it allows only
a *single* PCIe device to be hotplugged. And Nova currently sets
'num_pcie_ports' to "0" (which means, it defaults to libvirt's "1"), which is
not sufficient for hotplug use.
Default for NovaLibvirtNumPciePorts is 16.