Bug 1724122

Summary: [OSP14] 'hw_vif_model' image metadata property should be ignored for SR-IOV-based VIFs
Product: Red Hat OpenStack Reporter: Stephen Finucane <stephenfin>
Component: openstack-novaAssignee: Stephen Finucane <stephenfin>
Status: CLOSED ERRATA QA Contact: James Parker <jparker>
Severity: high Docs Contact:
Priority: high    
Version: 14.0 (Rocky)CC: amodi, chhudson, dasmith, eglynn, jhakimra, jparker, jschluet, kchamart, lyarwood, mbooth, nova-maint, rheslop, sandyada, sbauza, sgordon, stephenfin, vromanso
Target Milestone: z4Keywords: TestOnly, Triaged, ZStream
Target Release: 14.0 (Rocky)   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: openstack-nova-18.2.1-0.20190509150812.8e130e2.el7ost Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1721433
: 1724124 (view as bug list) Environment:
Last Closed: 2019-11-06 16:51:22 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1721433, 1724124    
Bug Blocks:    

Description Stephen Finucane 2019-06-26 09:58:22 UTC
+++ This bug was initially created as a clone of Bug #1721433 +++

Description of problem: 

Sriov instance's spawn fails if additional properties "hw_vif_model & hw_disk_bus" in image

If we add the below metadata properties to image, and any VM launched with this image is moving to ERROR state due to failure of SRIOV port binding

~~~  
  hw_vif_model  = virtio
  hw_disk_bus = virtio
~~~


Error Message:-

u'message': u"unsupported configuration: Unknown PCI device <driver name='vhost'/> has been specified", u'code': 500, u'details': u'  File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 1862, in _do_build_and_run_instance\n    filter_properties, request_spec)\n  File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2142, in _build_and_run_instance\n    instance_uuid=instance.uuid, reason=six.text_type(e))\n


The above is strange as why would a Sriov instance have 'vhost' as a driver? A sriov interface should be seen as vfio device in libvirt.

Version-Release number of selected component (if applicable):

RedHat OpenStack Version 13.0


How reproducible: 


Steps to Reproduce:
1. Add additional property to image:-

~~~  
  hw_vif_model  = virtio
  hw_disk_bus = virtio
~~~

2. Spawn a sriov instance


Actual results:

Instance spawn is failing:-
~~~
u'message': u"unsupported configuration: Unknown PCI device <driver name='vhost'/> has been specified", u'code': 500, u'details': u'  File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 1862, in _do_build_and_run_instance\n    filter_properties, request_spec)\n  File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2142, in _build_and_run_instance\n    instance_uuid=instance.uuid, reason=six.text_type(e))\
~~~


Expected results:

Instance spawn should not fail.

Additional info:

Comment 19 errata-xmlrpc 2019-11-06 16:51:22 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:3746