RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1225789 - Wrong video driver is installed for rhel5.11 guest after conversion to libvirt
Summary: Wrong video driver is installed for rhel5.11 guest after conversion to libvirt
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libguestfs
Version: 7.2
Hardware: x86_64
OS: Unspecified
medium
high
Target Milestone: rc
: ---
Assignee: Richard W.M. Jones
QA Contact: Virtualization Bugs
Jiri Herrmann
URL:
Whiteboard: V2V
Depends On: 1218766
Blocks: 1288337 1305606 1313485
TreeView+ depends on / blocked
 
Reported: 2015-05-28 09:06 UTC by tingting zheng
Modified: 2016-11-03 17:52 UTC (History)
9 users (show)

Fixed In Version: libguestfs-1.32.0-2.el7
Doc Type: Release Note
Doc Text:
Guest display problems after *virt-v2v* conversion have been fixed Previously, the video card driver setting of a guest converted with the *virt-v2v* utility was ignored, causing various display problems in the guest. This update ensures that *virt-v2v* generates the libvirt XML file for the converted guest properly. As a result, the video card setting is preserved, and the guest can take full advantage of graphical capabilities after the conversion.
Clone Of:
: 1312254 (view as bug list)
Environment:
Last Closed: 2016-11-03 17:52:56 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
The screenshot of X server fail-rhel5.11 guest (53.31 KB, image/png)
2015-05-28 09:06 UTC, tingting zheng
no flags Details
The screenshot of X server diagnose-rhel5.11 (60.74 KB, image/png)
2015-05-28 09:08 UTC, tingting zheng
no flags Details
Debug log (284.77 KB, text/plain)
2015-05-28 09:09 UTC, tingting zheng
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2016:2576 0 normal SHIPPED_LIVE Moderate: libguestfs and virt-p2v security, bug fix, and enhancement update 2016-11-03 12:06:51 UTC

Description tingting zheng 2015-05-28 09:06:51 UTC
Created attachment 1031117 [details]
The screenshot of X server fail-rhel5.11 guest

Description of problem:
Wrong video driver is installed for rhel5.11 guest after conversion to libvirt

Version-Release number of selected component (if applicable):
libguestfs-1.28.1-1.36.el7.x86_64
virt-v2v-1.28.1-1.36.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1.Prepare a rhel5 guest with vnc graphics on xen server.
# virsh dumpxml xen-hvm-rhel5.11-i386
<graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/>

2.Use virt-v2v to convert the guest to libvirt.
# virt-v2v -ic xen+ssh://10.66.106.64 -os default -b virbr0 xen-hvm-rhel5.11-i386 -of raw
[   0.0] Opening the source -i libvirt -ic xen+ssh://10.66.106.64 xen-hvm-rhel5.11-i386
[   0.0] Creating an overlay to protect the source from being modified
[   0.0] Opening the overlay
[   8.0] Initializing the target -o libvirt -os default
[   8.0] Inspecting the overlay
[  22.0] Checking for sufficient free disk space in the guest
[  22.0] Estimating space required on target for each disk
[  22.0] Converting Red Hat Enterprise Linux Server release 5.11 (Tikanga) to run on KVM
virt-v2v: This guest has virtio drivers installed.
[  39.0] Mapping filesystem data to avoid copying unused and blank areas
[  40.0] Closing the overlay
[  40.0] Copying disk 1/1 to /var/lib/libvirt/images/xen-hvm-rhel5.11-i386-sda (raw)
    (100.00/100%)
[ 188.0] Creating output metadata
Pool default refreshed

Domain xen-hvm-rhel5.11-i386 defined from /tmp/v2vlibvirtd6a7e9.xml

[ 190.0] Finishing off

3.Check the guest xml of graphics part,it's vnc with cirrus model.
# virsh dumpxml xen-hvm-rhel5.11-i386
    <graphics type='vnc' port='5900' autoport='yes' listen='127.0.0.1' keymap='en-us'>
      <listen type='address' address='127.0.0.1'/>
    </graphics>
    <video>
      <model type='cirrus' vram='16384' heads='1'/>
      <alias name='video0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
    </video>

4.Try to boot the guest,it fails to start X server.Detailed info pls see the screenshot.

5.Login guest,check the video driver,cirrus driver is not here and qxl is installed.
# cat /etc/X11/xorg.conf |grep cirrus

Actual results:
As description.

Expected results:
Cirrus driver is installed and X server can be launched successfully.

Additional info:
1.For rhel6 and rhel7 guest,correct driver(cirrus driver) is installed for guest with vnc graphics after conversion to libvirt.

Comment 1 tingting zheng 2015-05-28 09:08:31 UTC
Created attachment 1031118 [details]
The screenshot of X server diagnose-rhel5.11

Comment 2 tingting zheng 2015-05-28 09:09:29 UTC
Created attachment 1031120 [details]
Debug log

Comment 4 Richard W.M. Jones 2015-05-28 09:27:30 UTC
I found the same thing during my own testing.  It's a bug, and
a regression over the old virt-v2v which used to install
xorg-x11-drv-qxl in the guest during conversion.

Comment 5 Pino Toscano 2015-10-22 16:36:48 UTC
This should be fixed with
https://github.com/libguestfs/libguestfs/commit/f56031d5493af36e46de7a97f150a8724b6007fa
which is in libguestfs >= 1.31.20.

So it should be fixed by the rebase (bug #1218766).

tingting: the result now is that any RHEL guest has QXL as video card set in libvirt.

Comment 6 tingting zheng 2015-10-23 06:04:35 UTC
(In reply to Pino Toscano from comment #5)
> This should be fixed with
> https://github.com/libguestfs/libguestfs/commit/
> f56031d5493af36e46de7a97f150a8724b6007fa
> which is in libguestfs >= 1.31.20.
> 
> So it should be fixed by the rebase (bug #1218766).
> 
> tingting: the result now is that any RHEL guest has QXL as video card set in
> libvirt.

Hi,Pino

Do you mean that no matter the original guest has graphics/video as vnc+cirrus or spice+qxl,after converted to libvirt,it all becomes spice+qxl?

Comment 7 Pino Toscano 2015-10-23 07:08:40 UTC
(In reply to tingting zheng from comment #6)
> (In reply to Pino Toscano from comment #5)
> > This should be fixed with
> > https://github.com/libguestfs/libguestfs/commit/
> > f56031d5493af36e46de7a97f150a8724b6007fa
> > which is in libguestfs >= 1.31.20.
> > 
> > So it should be fixed by the rebase (bug #1218766).
> > 
> > tingting: the result now is that any RHEL guest has QXL as video card set in
> > libvirt.
> 
> Hi,Pino
> 
> Do you mean that no matter the original guest has graphics/video as
> vnc+cirrus or spice+qxl,after converted to libvirt,it all becomes spice+qxl?

No, the change is only about cirrus vs. qxl. vnc or spice is left as it is. So vnc+cirrus will be vnc+qxl, and spice+qxl will stay as it is (as it's qxl already).

Comment 10 Xiaodai Wang 2016-02-26 08:48:22 UTC
I tested the with (vnc+cirrus) and it's converted to vnc+qxl successfully. And then tested it with spice+cirrus, it changed to vnc+qxl instead of spice+qxl unexpectedly.

Before converting (spice+cirrus):
# virsh dumpxml rhel7.2-10301 | grep graphic -A5
    <graphics type='spice' autoport='yes' listen='0.0.0.0'>
      <listen type='address' address='0.0.0.0'/>
    </graphics>
    <sound model='ich6'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    </sound>
    <video>
      <model type='cirrus' vram='16384' heads='1'/>

After converting (vnc+qxl):
# virsh dumpxml aaa | grep graphic -A5
    <graphics type='vnc' port='-1' autoport='yes' listen='0.0.0.0'>
      <listen type='address' address='0.0.0.0'/>
    </graphics>
    <sound model='ich6'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    </sound>
    <video>
      <model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1'/>

Comment 11 Richard W.M. Jones 2016-02-26 09:07:51 UTC
I created bug 1312254 for this issue described in comment 10.

Comment 12 mxie@redhat.com 2016-03-01 09:23:23 UTC
Verify the bug with builds:
virt-v2v-1.32.3-1.el7.x86_64
libguestfs-1.32.3-1.el7.x86_64

Steps:

Scenario1
1 Prepare a guest with spice+cirrus mode on libvirt
  # virsh dumpxml xen-fv-rhel6.6-x86_64
<graphics type='spice' autoport='yes' keymap='en-us'/>
    <video>
      <model type='cirrus' vram='65536' heads='1'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
    </video>

2 Using virt-v2v to convert the guest
# virt-v2v xen-fv-rhel6.6-x86_64 -on spice-cirrus
[   0.0] Opening the source -i libvirt xen-fv-rhel6.6-x86_64
[   0.0] Creating an overlay to protect the source from being modified
[   1.3] Initializing the target -o libvirt -os default
[   1.3] Opening the overlay
[  23.6] Inspecting the overlay
[  40.1] Checking for sufficient free disk space in the guest
[  40.1] Estimating space required on target for each disk
[  40.1] Converting Red Hat Enterprise Linux Server release 6.6 (Santiago) to run on KVM
virt-v2v: This guest has virtio drivers installed.
[ 126.1] Mapping filesystem data to avoid copying unused and blank areas
[ 126.3] Closing the overlay
[ 126.6] Checking if the guest needs BIOS or UEFI to boot
[ 126.6] Assigning disks to buses
[ 126.6] Copying disk 1/1 to /var/lib/libvirt/images/spice-cirrus-sda (qcow2)
    (100.00/100%)
[ 177.9] Creating output metadata
Pool default refreshed

Domain spice-cirrus defined from /tmp/v2vlibvirtd43734.xml

[ 178.9] Finishing off


3 Check  display mode in guest spice-cirrus xml after converting by virt-v2v
#virsh dumpxml spice-cirrus 
 <graphics type='spice' port='5902' autoport='yes' listen='127.0.0.1' keymap='en-us'>
      <listen type='address' address='127.0.0.1'/>
    </graphics>
    <video>
      <model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1'/>
      <alias name='video0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
    </video>

Result now:
 guest display with spice+cirrus mode could be converted to spice+qxl successfully


Scenario2

1 Prepare a rhel5 guest with vnc graphics on xen server.
# virsh dumpxml xen-hvm-rhel5.11-i386
<graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/>

2.Use virt-v2v to convert the guest to libvirt.
# virt-v2v -ic xen+ssh://10.66.106.64 -b virbr0  xen-hvm-rhel5.11-i386 -of raw
[   0.0] Opening the source -i libvirt -ic xen+ssh://10.66.106.64 xen-hvm-rhel5.11-i386
[   0.4] Creating an overlay to protect the source from being modified
[   1.1] Initializing the target -o libvirt -os default
[   1.1] Opening the overlay
[ 101.6] Inspecting the overlay
[ 113.3] Checking for sufficient free disk space in the guest
[ 113.3] Estimating space required on target for each disk
[ 113.3] Converting Red Hat Enterprise Linux Server release 5.11 (Tikanga) to run on KVM
virt-v2v: This guest has virtio drivers installed.
[ 131.5] Mapping filesystem data to avoid copying unused and blank areas
[ 132.3] Closing the overlay
[ 132.4] Checking if the guest needs BIOS or UEFI to boot
[ 132.4] Assigning disks to buses
[ 132.4] Copying disk 1/1 to /var/lib/libvirt/images/xen-hvm-rhel5.11-i386-sda (raw)
    (100.00/100%)
[ 579.4] Creating output metadata
Pool default refreshed

Domain xen-hvm-rhel5.11-i386 defined from /tmp/v2vlibvirt42f8e1.xml

[ 580.3] Finishing off

3 Check the guest xml of graphics part,it's vnc with qxl model.
 # virsh dumpxml xen-hvm-rhel5.11-i386
 <graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/>
    <video>
      <model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
    </video>

Additional info:
Guest with vnc+cirrus mode and could be converted to vnc+qxl successfully

Result:
 guest display with vnc mode and will be converted to vnc+qxl mode, but according to https://bugzilla.redhat.com/show_bug.cgi?id=1300250#c10 and  https://bugzilla.redhat.com/show_bug.cgi?id=707055#c2, display:vnc + qxl mode is not supported. Hi,rjones, could you help to see this?

Comment 13 Richard W.M. Jones 2016-03-01 09:28:48 UTC
Note comment 12 refers to bug 1312254.  I have replied on that bug.

Comment 14 keanli 2016-04-14 03:29:30 UTC
I can reproduce it with:
libguestfs-1.31.7-1.el7.x86_64
virt-v2v-1.31.7-1.el7.x86_64

Reproduce steps:
1.Prepare a rhel5 guest with vnc graphics on xen server.
virsh dumpxml xen-hvm-rhel5.11-i386
<graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/>
2,Convert it to kvm using the virt-v2v
virt-v2v -ic xen+ssh://10.73.3.21 -of raw xen-hvm-rhel5.11-i386 -os default
There is no any error appear on the command line , convert successfully 
3, Check the guest xml of graphics part,it's vnc with cirrus model.
4,Finally, try to boot the guest,it fails to start X server.

Testing with:
libguestfs-1.32.3-1.el7.x86_64
virt-v2v-1.32.3-1.el7.x86_64

The steps are same with reproduce steps  
1,after step3.Check the xml file after convert it 
#virsh dumpxml xen-hvm-rhel5.11-i386
<graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/>
<video>
<model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1' primary='yes'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
</video>
<memballoon model='virtio'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
2,step4:can boot the guest to X server normally

Refer to the above comments,the bug has been fixed,so move the bug to VERIFIED.

Comment 16 errata-xmlrpc 2016-11-03 17:52:56 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://rhn.redhat.com/errata/RHSA-2016-2576.html


Note You need to log in before you can comment on or make changes to this bug.