Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 2026014

Summary: [For OSP17] [RFE] libvirt: Switch the default video model from 'cirrus' to 'virtio'
Product: Red Hat OpenStack Reporter: Kashyap Chamarthy <kchamart>
Component: openstack-novaAssignee: Kashyap Chamarthy <kchamart>
Status: CLOSED ERRATA QA Contact: OSP DFG:Compute <osp-dfg-compute>
Severity: low Docs Contact:
Priority: low    
Version: 17.0 (Wallaby)CC: alifshit, dasmith, egallen, eglynn, igallagh, jhakimra, jparker, kchamart, sbauza, sgordon, smooney, vromanso
Target Milestone: z1Keywords: FutureFeature, Patch, TestOnly, Triaged
Target Release: 17.0   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: openstack-nova-23.2.2-0.20220720130412.7074ac0.el9ost Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-01-25 12:28:47 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: Yoga
Embargoed:

Description Kashyap Chamarthy 2021-11-23 16:15:18 UTC
What?
-----

Change Nova's default video display from 'cirrus' to 'virtio'.

Why?
----

First of all, it was declared deprecated[0] back in RHEL-8.

Second, the "cirrus" display device has many limitations and is
"considered harmful"[1] by QEMU graphics maintainers since 2014.

The recommended[1] choice by the QEMU graphics maintainers is 'virtio'
(using the libvirt term) for both UEFI and BIOS guests:

  - Any Linux guest with kernel 4.4 (or a kernel with the Linux
    'virtio-vgpu' driver backported) can take full advantage of the
    'virtio' display device.

  - In case your guest kernel does _not_ have the kernel driver (called
    "virtio-gpu.ko"), no problem: the 'virtio' display device will
    gracefully fallback to VGA compatibility mode.

In other words, 'virtio' is a reasonable default _whether_ or not the
guest has a kernel 'virtio-gpu' driver. If the guest kernel has the
driver, it'll be used. Otherwise, it transparently falls back to the
VGA compat mode.

Lastly, the 'virtio' display device gets the most upstream
development[3], and "support for new, cool features will most likely be
added to this device."
Version requirements
--------------------

  - Linux kernel version 4.4 or above
  - QEMU version 2.6

Upstream Nova and its CI handsomely satisfy both the requirements:

  - Nova's minimum QEMU is 4.2.0
  - Ubuntu Focal, the LTS release, ships with Linux 5.4 series, so we're
    good there too. (And OSes like CentOS7 have the 'virtio-gpu' driver
    backported to them.)

Upgrade impact
--------------

The 'cirrus' device still exists upstream; so any Nova guest with
'cirrus' that is migrated to a compute host that has 'virtio' as the
default will migrate just fine. Upon cold-reboot (stop + start), the
Nova instance will pick up 'virtio' as the default display device.


[0] https://bugzilla.redhat.com/show_bug.cgi?id=1651994 — Declare the
    "Cirrus VGA" device emulation of QEMU as deprecated in RHEL8
[1] https://www.kraxel.org/blog/2014/10/qemu-using-cirrus-considered-harmful/
[2] https://www.kraxel.org/blog/2019/09/display-devices-in-qemu/
[3] https://www.kraxel.org/blog/2019/09/display-devices-in-qemu/#virtio-vga

Comment 1 Kashyap Chamarthy 2021-11-23 16:18:08 UTC
Upstream blueprint:

    https://blueprints.launchpad.net/nova/+spec/virtio-as-default-display-device


The simple patch is already merged:

    https://opendev.org/openstack/nova/commit/cc59698d6903

Comment 5 OSP Team 2022-09-22 10:40:58 UTC
According to our records, this should be resolved by openstack-nova-23.2.2-0.20220720130412.7074ac0.el9ost.  This build is available now.

Comment 12 errata-xmlrpc 2023-01-25 12:28:47 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 (Red Hat OpenStack Platform 17.0.1 bug fix and enhancement 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-2023:0271