I came across [1] today while triaging a bug [2]. Unless I'm mistaken, the user has requested SR-IOV PF passthrough for their server and for whatever reason we can't find the PCI device for the PF passthrough port so we don't reflect the actual device MAC address on the port. Is that worth stopping the server create? Or is logging an ERROR enough here?

The reason being we get an IndexError here [3]. Ultimately if we found a PCI device but it's not whitelisted, we'll raise an exception anyway when building the port binding profile [4].

So is it reasonable to just raise PciDeviceNotFound whenever we can't find a PCI device on a compute host given a pci_request_id? In other words, it seems something failed earlier during scheduling and/or the PCI device resource claim if we get this far and things are still messed up.

[1] https://github.com/openstack/nova/blob/237ced4737a28728408eb30c3d20c6b2c13b4a8d/nova/network/neutronv2/api.py#L1426
[2] https://bugs.launchpad.net/nova/+bug/1795064
[3] https://github.com/openstack/nova/blob/237ced4737a28728408eb30c3d20c6b2c13b4a8d/nova/network/neutronv2/api.py#L1404 [4] https://github.com/openstack/nova/blob/237ced4737a28728408eb30c3d20c6b2c13b4a8d/nova/network/neutronv2/api.py#L1393

--

Thanks,

Matt

__________________________________________________________________________
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

Reply via email to