Bug 1812652

Summary: Disable USB when not required
Product: Red Hat OpenStack Reporter: Marcelo Tosatti <mtosatti>
Component: openstack-novaAssignee: Stephen Finucane <stephenfin>
Status: CLOSED ERRATA QA Contact: James Parker <jparker>
Severity: urgent Docs Contact:
Priority: medium    
Version: unspecifiedCC: alifshit, dasmith, egallen, eglynn, jhakimra, jparker, jschluet, kchamart, lcapitulino, nilal, sbauza, sgordon, smooney, stephenfin, vromanso, williams
Target Milestone: betaKeywords: Patch, Triaged
Target Release: 17.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: openstack-nova-23.2.1-0.20220428212241.327693a.el9ost Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-09-21 12:09:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version: Wallaby
Embargoed:

Description Marcelo Tosatti 2020-03-11 18:39:33 UTC
Description of problem:

To achieve the necessary low latency on a KVM-RT guest, it is necessary to drop
certain devices from the XML configuration, as described here:

https://bugzilla.redhat.com/show_bug.cgi?id=1787442

However, as recommended by OpenStack developers in the BZ above, no XML modifications should be made, instead it should be fixed via image props/extra specs.

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

13 (should be fixed in newer releases).

How reproducible:
See bug above (BZ 1787442)

Steps to Reproduce:
See bug above (BZ 1787442).

Comment 2 Stephen Finucane 2020-03-13 14:53:51 UTC
*** Bug 1813007 has been marked as a duplicate of this bug. ***

Comment 3 Stephen Finucane 2020-10-07 16:45:35 UTC
I've started working on this. Currently, on an x86 host, no USB devices will be added unless graphics are enabled. The only devices that nova currently supports where a USB bus may be used are input devices (keyboard, mouse, tablet) and disk devices. If graphics are disabled, no input device will be attached. You can disable graphics at a host-level by setting '[vnc]enabled=False' and '[spice]enabled=False' (note: SPICE is not currently supported in OSP so this should be 'false' by default). However, libvirt will automatically add a USB bus even if there are no USB-based devices. My proposed fix is to explicitly disable the bus in this case. With that fix in place, disabling graphics and ensuring disks use a non-USB bus (this would only happen if you set the 'hw_disk_bus' image metadata property to 'usb').

@Marcelo Tosatti: Does that sound reasonable? I assume graphics are not a desirable feature on real-time instances.

Comment 4 Marcelo Tosatti 2020-10-15 17:04:01 UTC
(In reply to Stephen Finucane from comment #3)
> I've started working on this. Currently, on an x86 host, no USB devices will
> be added unless graphics are enabled. The only devices that nova currently
> supports where a USB bus may be used are input devices (keyboard, mouse,
> tablet) and disk devices. If graphics are disabled, no input device will be
> attached. You can disable graphics at a host-level by setting
> '[vnc]enabled=False' and '[spice]enabled=False' (note: SPICE is not
> currently supported in OSP so this should be 'false' by default). However,
> libvirt will automatically add a USB bus even if there are no USB-based
> devices. My proposed fix is to explicitly disable the bus in this case. With
> that fix in place, disabling graphics and ensuring disks use a non-USB bus
> (this would only happen if you set the 'hw_disk_bus' image metadata property
> to 'usb').
> 
> @Marcelo Tosatti: Does that sound reasonable? 

Yes.

> I assume graphics are not a desirable feature on real-time instances.

VNC graphics processing can cause latency spikes, as seen by:

https://bugzilla.redhat.com/show_bug.cgi?id=1787442#c0

Comment 16 errata-xmlrpc 2022-09-21 12:09:42 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 (Release of components for Red Hat OpenStack Platform 17.0 (Wallaby)), 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/RHEA-2022:6543