Description of problem: Current Fedora 24 is advertised of being technically capable of providing VirGL 3D support in virtual machines, see http://blog.wikichoon.com/2016/05/spice-openglvirgl-acceleration-on.html on this matter. In order to enable VirGL 3D, the machine description file needs the following modifications which can be found at http://www.spice-space.org/spice-user-manual.html: "You need to add a virtio-gpu video device to your virtual machine instead of QXL. <video> <model type='virtio' heads='1'> <acceleration accel3d='yes'/> </model> </video> Then you need to enable OpenGL on your SPICE graphics node: <graphics type='spice' autoport='no'> <gl enable='yes'/> </graphics>." However, after editing the machine description file accordingly by means of 'virsh edit ..', merely launching gnome-boxes without even starting the virtual machine has the unexpected effect of removing the GL directive "<gl enable='yes'/>". Consequently, the virtual machine is using the "virtio" video device without 3D acceleration. Version-Release number of selected component (if applicable): gnome-boxes-3.20.2-4.fc24 How reproducible: Always Steps to Reproduce: 1. Set up machine description file for VirGL support. 2. Launch gnome-boxes. Actual results: The GL directive "<gl enable='yes'/>" is missing from the machine description file; after launching the virtual machine, VirGL 3D is disabled. Expected results: The GL directive "<gl enable='yes'/>" is present in the machine description file; after launching the virtual machine, VirGL 3D is enabled. Additional info: - When the virtual machine is started by means of 'virsh start ..' prior to launching gnome-boxes, then the GL directive "<gl enable='yes'/>" is preserved in the machine description file, and VirGL 3D is effectively enabled. - Contrary to the behaviour in Fedora 24, under Fedora 25, gnome-boxes preserves the GL directive "<gl enable='yes'/>" in the machine description file and VirGL 3D is effectively enabled.
Current Fedora 25 again exhibits the old faulty behaviour where the GL directive "<gl enable='yes'/>" in the machine description file is removed. Launching the virtual machine with 'virsh start ..' and connecting to it with gnome-boxes after start-up preserves the GL directive "<gl enable='yes'/>" and enables VirGL 3D successfully.
Hmm, could be some similar problem to a bug which was fixed recently in libvirt-glib (but this one would not be fixed): libvirt-glib will silently drop nodes it does not know from the XML when using it to get the list of devices, and then readding these same devices to the VM. And I'm not sure libvirt-glib is aware of the <gl> node yet.
(In reply to Christophe Fergeau from comment #2) To be more precise: VirGL 3D support worked correctly for a Fedora 25 host until a few weeks ago when I last tried successfully. From the original description: "Contrary to the behaviour in Fedora 24, under Fedora 25, gnome-boxes preserves the GL directive "<gl enable='yes'/>" in the machine description file and VirGL 3D is effectively enabled.". The current regression identically matches the usual behaviour of a Fedora 24 host.
(In reply to Christophe Fergeau from comment #2) libvirt-glib News ================= 1.0.0 - Nov 4, 2016 ==================== - .. - Add ability to set SPICE gl property - Add support for virtio video model - Add support for 3d accel property - .. . Contrary to what the NEWS file of the current libvirt-glib version suggests, Fedora 25 and Fedora 26 both fail to activate VirGL and instead remove the GL directive "<gl enable='yes'/>" in the machine description file.
What this news entry suggests is that Boxes could *set* the 'gl' option if it wanted to. Given the way libvirt-glib works, this means nothing wrt preserving that option in preexisting XML files. 1.0.0 will preserve <unknown><gl enable="yes"/></unknown> but not <graphics><gl enable="yes"/></graphics></devices></domain> :((
(In reply to Christophe Fergeau from comment #5) As pointed out in the original description of this issue, gnome-boxes and dependent packages behaved correctly under Fedora 25 back in August 2016. Thus, the current behaviour is a regression compared to that previous situation.
Looking at https://koji.fedoraproject.org/koji/packageinfo?packageID=12913 it seems f25 and f24 had the same libvirt-glib version until early November 2016, but the initial report says they behave differently. To be honest I would not be surprised if this never worked.
For current Fedora 25 and Fedora 26, gnome-boxes removes the GL directive from the machine description file effectively disabling VirGL 3D. Fedora 26 includes the very latest (stable) packages including - gnome-boxes-3.24.0-1.fc26 - libvirt-*-3.2.1-1.fc26 - libvirt-glib-1.0.0-2.fc26 - spice-gtk3-0.33-3.fc26 With Fedora 25, it is at least possible to work around this issue by launching a VirGL-enabled VM by means of 'virsh start ..' and connecting to the running session with gnome-boxes. With Fedora 26, even this is no longer possible: gnome-boxes simply crashes when clicking the corresponding thumbnail.
(In reply to Joachim Frieben from comment #8) > With Fedora 26, even this is no longer > possible: gnome-boxes simply crashes when clicking the corresponding > thumbnail. I had to backport https://bugzilla.gnome.org/show_bug.cgi?id=780963 in order to be able to click on a thumbnail without Boxes going back to the overview. After that, I indeed get a crash with "gnome-boxes: Couldn't find current GLX or EGL context.", dunno if that is what you are seeing? The same thing happens with virt-viewer, so that would indicate a regression somewhere else in the stack.
(In reply to Christophe Fergeau from comment #9) Correct, I do also see this message "gnome-boxes: Couldn't find current GLX or EGL context." issued to the shell from which gnome-boxes was launched.
This message is a reminder that Fedora 25 is nearing its end of life. Approximately 4 (four) weeks from now Fedora will stop maintaining and issuing updates for Fedora 25. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '25'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 25 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 25 changed to end-of-life (EOL) status on 2017-12-12. Fedora 25 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.
Issue is still present for all of Fedora 26, 27, and 28.
This message is a reminder that Fedora 26 is nearing its end of life. Approximately 4 (four) weeks from now Fedora will stop maintaining and issuing updates for Fedora 26. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '26'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 26 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
This message is a reminder that Fedora 27 is nearing its end of life. On 2018-Nov-30 Fedora will stop maintaining and issuing updates for Fedora 27. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '27'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 27 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 27 changed to end-of-life (EOL) status on 2018-11-30. Fedora 27 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.