Bug 1374651 - Can't install qxl driver for display device in win7 guest after converting to glance by virt-v2v
Summary: Can't install qxl driver for display device in win7 guest after converting to...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libguestfs
Version: 7.0
Hardware: x86_64
OS: Unspecified
low
low
Target Milestone: pre-dev-freeze
: 7.4
Assignee: Richard W.M. Jones
QA Contact: Virtualization Bugs
URL:
Whiteboard: V2V
Depends On: 1359086
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-09-09 10:42 UTC by mxie@redhat.com
Modified: 2017-08-01 22:11 UTC (History)
12 users (show)

Fixed In Version: libguestfs-1.36.1-1.el7
Doc Type: Bug Fix
Doc Text:
Cause: when exporting guests to Glance, virt-v2v did not set the hw_video_model property of images. Consequence: Nova does not configure the guest to use the correct video model (QXML, for example). Fix: virt-v2v set the hw_video_model property with the proper video model. Result: in OpenStack, the guest is configured to use its video model.
Clone Of:
Environment:
Last Closed: 2017-08-01 22:11:26 UTC


Attachments (Terms of Use)
screenshot (103.78 KB, image/png)
2016-09-09 10:42 UTC, mxie@redhat.com
no flags Details
win7-v2v-glance.log (405.19 KB, text/plain)
2016-09-09 10:43 UTC, mxie@redhat.com
no flags Details


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2023 normal SHIPPED_LIVE libguestfs bug fix and enhancement update 2017-08-01 19:32:01 UTC

Description mxie@redhat.com 2016-09-09 10:42:34 UTC
Created attachment 1199380 [details]
screenshot

Description of problem:
Can't install qxl driver for display device in win7 guest after converting to glance by virt-v2v

Version-Release number of selected component (if applicable):
virt-v2v-1.32.7-3.el7.x86_64
libguestfs-1.32.7-3.el7.x86_64
qemu-kvm-1.5.3-122.el7.x86_64
libvirt-2.0.0-8.el7.x86_64
openstack:12.0.2-1.el7ost

How reproducible:
100% 

Steps to Reproduce:
1. Convert win7 guest from vmware to glance by virt-v2v
# virt-v2v -ic vpx://root@10.66.145.47/data/10.66.144.40/?no_verify=1 esx6.0-win7-x86_64 --password-file /tmp/passwd -o glance
[   0.1] Opening the source -i libvirt -ic vpx://root@10.66.145.47/data/10.66.144.40/?no_verify=1 esx6.0-win7-x86_64
[   1.2] Creating an overlay to protect the source from being modified
[   2.8] Initializing the target -o glance
[   7.8] Opening the overlay
[  16.0] Inspecting the overlay
[  64.9] Checking for sufficient free disk space in the guest
[  64.9] Estimating space required on target for each disk
[  64.9] Converting Windows 7 Ultimate to run on KVM
virt-v2v: This guest has virtio drivers installed.
[  79.4] Mapping filesystem data to avoid copying unused and blank areas
[  79.8] Closing the overlay
[  79.9] Checking if the guest needs BIOS or UEFI to boot
[  79.9] Assigning disks to buses
[  79.9] Copying disk 1/1 to /var/tmp/glance.e4faSq/sda (raw)
    (100.00/100%)
[ 639.8] Creating output metadata
+------------------+--------------------------------------+
| Property         | Value                                |
+------------------+--------------------------------------+
| checksum         | 3bec2c54d44eca46d68a4687695f64c3     |
| container_format | bare                                 |
| created_at       | 2016-09-09T07:40:57Z                 |
| disk_format      | raw                                  |
| id               | f836eeda-6f03-44ba-ba20-903a417a6062 |
| min_disk         | 0                                    |
| min_ram          | 0                                    |
| name             | esx6.0-win7-x86_64                   |
| owner            | 6c4dac53186d44fcbac29d3f3f575125     |
| protected        | False                                |
| size             | 12884901888                          |
| status           | active                               |
| tags             | []                                   |
| updated_at       | 2016-09-09T07:43:27Z                 |
| virtual_size     | None                                 |
| visibility       | private                              |
+------------------+--------------------------------------+
404 Not Found: No image found with ID esx6.0-win7-x86_64 (HTTP 404)
virt-v2v: warning: glance: failed to set image properties (ignored)
[ 800.9] Finishing off
Image properties:
  --min-ram 4096
  --property 'os_version'='6.1'  --property 'hw_disk_bus'='virtio'  --property 'hw_vif_model'='virtio'  --property 'architecture'='x86_64'  --property 'hypervisor_type'='kvm'  --property 'vm_mode'='hvm'  --property 'os_type'='windows'  --property 'os_distro'='windows'

2.After conversion, lanuch the win7 instance using the image in openstack and checkpoint for win7 guest, but find that qxl driver can't installed for display device and  pls refer to screenshot

3.Check xml of win7 guest in openstack server, win7 guest has vnc+cirrus graphic mode as below
# virsh dumpxml instance-0000001f
<domain type='kvm' id='33'>
  <name>instance-0000001f</name>
..... 
 <graphics type='vnc' port='5903' autoport='yes' listen='0.0.0.0' keymap='en-us'>
      <listen type='address' address='0.0.0.0'/>
    </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.But check that v2v has set qxl for guest video in v2v conversion log, details pls refer to attachment log, but openstack still set cirrus for guest video.that it is the reason why can't install qxl driver for display device in win7 guest

libguestfs: trace: v2v: pwrite_device = 2
gcaps_block_bus = virtio
gcaps_net_bus = virtio-net
gcaps_video = qxl
gcaps_arch = x86_64
gcaps_acpi = true


 
Actual results:
As above description

Expected results:
Can install qxl driver for display device in win7 guest after converting to glance by virt-v2v

Additional info:

Comment 2 mxie@redhat.com 2016-09-09 10:43:13 UTC
Created attachment 1199381 [details]
win7-v2v-glance.log

Comment 3 Richard W.M. Jones 2016-09-09 10:54:51 UTC
I asked Ming Xie to file this RFE.  However I'm not clear if
OpenStack can actually support QXL/Spice now.  If it can now do
that, then please reassign this bug to RHEL 7 -> libguestfs.

Comment 5 Vladik Romanovsky 2016-11-01 13:34:28 UTC
(In reply to Richard W.M. Jones from comment #3)
> I asked Ming Xie to file this RFE.  However I'm not clear if
> OpenStack can actually support QXL/Spice now.  If it can now do
> that, then please reassign this bug to RHEL 7 -> libguestfs.

Richard, 

QXL itself is supported with native clients.
However, since we have removed the spice-HTML5 client users have no simple way to connect to the guest. Users can use the native spice client to directly connect to the host.

It seems that --property hw_video_model=qxl is missing from the Image properties, there nova doesn't set the guest to use qxl..

Thanks,
Vladik

Comment 6 Richard W.M. Jones 2016-11-01 14:03:10 UTC
Patch sent upstream for setting hw_video_model property:

https://www.redhat.com/archives/libguestfs/2016-November/msg00004.html

Comment 10 mxie@redhat.com 2017-03-13 09:18:03 UTC
Verify the bug with builds:
virt-v2v-1.36.2-1.el7.x86_64
libguestfs-1.36.2-1.el7.x86_64
libvirt-3.1.0-2.el7.x86_64
qemu-kvm-rhev-2.8.0-6.el7.x86_64
libguestfs-winsupport-7.2-2.el7.x86_64
virtio-win-1.9.0-3.el7.noarch


Steps:
1.Convert a win7 guest from kvm to openstack by virt-v2v
# virt-v2v kvm-win7-x86_64 -o glance
[   0.0] Opening the source -i libvirt kvm-win7-x86_64
[   0.0] Creating an overlay to protect the source from being modified
[   0.2] Initializing the target -o glance
[   1.3] Opening the overlay
[   3.4] Inspecting the overlay
[   6.7] Checking for sufficient free disk space in the guest
[   6.7] Estimating space required on target for each disk
[   6.7] Converting Windows 7 Ultimate to run on KVM
virt-v2v: warning: /usr/share/virt-tools/pnp_wait.exe is missing.  
Firstboot scripts may conflict with PnP.
virt-v2v: This guest has virtio drivers installed.
[   8.4] Mapping filesystem data to avoid copying unused and blank areas
[   8.6] Closing the overlay
[   8.9] Checking if the guest needs BIOS or UEFI to boot
[   8.9] Assigning disks to buses
[   8.9] Copying disk 1/1 to /var/tmp/glance.mAGo6L/sda (raw)
    (100.00/100%)
[ 335.7] Creating output metadata
+------------------+--------------------------------------+
| Property         | Value                                |
+------------------+--------------------------------------+
| architecture     | x86_64                               |
| checksum         | 035f475cf45fec5a7c04af78e1325e06     |
| container_format | bare                                 |
| created_at       | 2017-03-13T07:55:51Z                 |
| disk_format      | raw                                  |
| hw_disk_bus      | virtio                               |
| hw_video_model   | qxl                                  |
| hw_vif_model     | virtio                               |
| hypervisor_type  | kvm                                  |
| id               | f78b83b6-1167-4301-a3b5-af50e8ad88d5 |
| min_disk         | 0                                    |
| min_ram          | 1024                                 |
| name             | kvm-win7-x86_64                      |
| os_distro        | windows                              |
| os_type          | windows                              |
| os_version       | 6.1                                  |
| owner            | 6c4dac53186d44fcbac29d3f3f575125     |
| protected        | False                                |
| size             | 12884901888                          |
| status           | active                               |
| tags             | []                                   |
| updated_at       | 2017-03-13T08:14:30Z                 |
| virtual_size     | None                                 |
| visibility       | private                              |
| vm_mode          | hvm                                  |
+------------------+--------------------------------------+
[1461.7] Finishing off

2.After conversion, launch the win7 instance using the image in openstack

3.Checkpoints for win7 guest are passed except that graphic driver is still VGA after restarting guest according to reminder

4.Right click the display device and manual update display driver from VGA to qxl successfully

Additional info
1.Also could reproduce the problem of step3 on win2008r2 guest


Hi rjones,

The problem of step 3 may be same as bug 1356550, and I also verified the bug 1356550, the display of win7 still can't be updated to qxl driver automatically after converting the guest from kvm to rhv,so the bug1356550 has not been fixed yet, could I move this bug to verified status because of problem of step3 is a known bug

Comment 11 Richard W.M. Jones 2017-03-13 16:46:38 UTC
The fix here was to pass this property to glance:

> | hw_video_model   | qxl                                  |

As that is being done, this bug is *verified*.

Now as you say, it may also be that we aren't installing the qxl
driver for Windows 7, causing the problematic step 3.  That is
another bug, likely bug 1356550 which you linked to.

Comment 12 mxie@redhat.com 2017-03-14 02:03:07 UTC
According to the comment 10 and comment 11, move this bug from ON_QA to VERIFIED

Comment 13 errata-xmlrpc 2017-08-01 22:11:26 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-2017:2023


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