Bug 1434737

Summary: Win10 x86 guest will BSOD after converting to rhv by virt-v2v sometimes
Product: Red Hat Enterprise Linux 7 Reporter: mxie <mxie>
Component: libguestfsAssignee: Pino Toscano <ptoscano>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.4CC: juzhou, kuwei, mzhan, ptoscano, tzheng, xiaodwan
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: V2V
Fixed In Version: libguestfs-1.36.3-2.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-08-01 22:13:55 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:
Attachments:
Description Flags
BSOD-win10-x86
none
virt-v2v-kvm-win10-i386-1.36.3-1.log none

Description mxie@redhat.com 2017-03-22 09:31:15 UTC
Created attachment 1265340 [details]
BSOD-win10-x86

Description of problem:
Win10 x86 guest will BSOD after converting to rhv by virt-v2v sometimes

Version-Release number of selected component (if applicable):
rhv:4.1.1.2-0.1.el7
virt-v2v-1.36.2-2.el7.x86_64
libguestfs-1.36.2-2.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


How reproducible:
30%

Steps to Reproduce:
1.Prepare a good win10 x86 guest and using virt-v2v convert win10 x86 guest from kvm to rhv
]# virt-v2v kvm-win10-i386-qcow2 -o rhv -os 10.73.131.91:/home/nfs_export
[   0.0] Opening the source -i libvirt kvm-win10-i386-qcow2
[   0.0] Creating an overlay to protect the source from being modified
[   0.4] Initializing the target -o rhv -os 10.73.131.91:/home/nfs_export
[   0.6] Opening the overlay
[  28.5] Inspecting the overlay
[  30.5] Checking for sufficient free disk space in the guest
[  30.5] Estimating space required on target for each disk
[  30.5] Converting Windows 10 Enterprise to run on KVM
virt-v2v: warning: /usr/share/virt-tools/pnp_wait.exe is missing.  
Firstboot scripts may conflict with PnP.
virt-v2v: warning: there is no QXL driver for this version of Windows (10.0 
i386).  virt-v2v looks for this driver in /usr/share/virtio-win

The guest will be configured to use a basic VGA display driver.
virt-v2v: This guest has virtio drivers installed.
[  32.9] Mapping filesystem data to avoid copying unused and blank areas
[  33.1] Closing the overlay
[  33.3] Checking if the guest needs BIOS or UEFI to boot
[  33.3] Assigning disks to buses
[  33.3] Copying disk 1/1 to /tmp/v2v.MVCrfS/eb8a2555-2a8b-4bd8-ba45-862cc833f0f1/images/3c8442d8-f16f-4756-9bf1-c3383699b67f/02f6d789-0be9-497b-aa9b-5ec253cb15a0 (qcow2)
    (100.00/100%)
[ 893.1] Creating output metadata
[ 893.2] Finishing off

2.Import the guest from export domain to data domain after finishing v2v conversion
3.Power on the guest after finishing importing but find the guest will BSOD sometimes, pls refer to screenshot 'BSOD-win10-x86'
4.This problem is reproduced by virt-v2v auto running,pls refer to log "https://libvirt-jenkins.rhev-ci-vms.eng.rdu2.redhat.com/view/v2v/view/RHEL-7.4/job/v2v-RHEL-7.4-runtest-x86_64-acceptance-ovirt/23/testReport/rhev/convert_vm_to_ovirt/kvm_windows_win10_i386_qcow2_f_NFS/"



Actual results:
As above description

Expected results:
Win10 x86 guest could boot into os successfully after converting to rhv by virt-v2v at 100%

Additional info:
1.This problem also was reproduced when convert win10 x86 guest from esxi5.5 to rhv by virt-v2v-1.36.2-1 auto running once, pls refer to https://libvirt-jenkins.rhev-ci-vms.eng.rdu2.redhat.com/view/v2v/view/RHEL-7.4/job/v2v-RHEL-7.4-runtest-x86_64-acceptance-ovirt/10/testReport/rhel/convert_vm_to_ovirt/esx_vm_5_5_windows_win10_i386_raw_f_NFS/

Comment 2 mxie@redhat.com 2017-03-31 04:22:14 UTC
Also reproduce the bug with below build when converting win10-i386 guest from kvm to rhv by virt-v2v manual running, pls refer to attachment"virt-v2v-kvm-win10-i386-1.36.3-1.log "

virt-v2v-1.36.3-1.el7.x86_64
libguestfs-1.36.3-1.el7.x86_64
qemu-kvm-rhev-2.8.0-6.el7.x86_64
libvirt-3.1.0-2.el7.x86_64
virtio-win-1.9.0-3.el7.noarch

Comment 3 mxie@redhat.com 2017-03-31 04:22:50 UTC
Created attachment 1267713 [details]
virt-v2v-kvm-win10-i386-1.36.3-1.log

Comment 4 Richard W.M. Jones 2017-04-03 17:36:08 UTC
Possible fix for this is:

https://www.redhat.com/archives/libguestfs/2017-April/msg00003.html

which I posted upstream as commit cc162b49e6c87bf3535168853dadf10f7610865f.

Pino - can we backport this fix to RHEL 7.4?  I already pushed
it to the rhel-7.4 branch.

Comment 6 kuwei@redhat.com 2017-04-07 09:30:43 UTC
Verify the bug with below builds:
virt-v2v-1.36.3-2.el7.x86_64
libguestfs-1.36.3-2.el7.x86_64
libvirt-3.2.0-1.el7.x86_64
qemu-kvm-rhev-2.8.0-6.el7.x86_64

Steps:
Prepare a good win10 x86 and a good win2016 guest , using virt-v2v convert  from kvm to rhv
# virt-v2v win10 -o rhv -os 10.73.131.93:/home/nfs_export 
[   0.0] Opening the source -i libvirt win10
[   0.0] Creating an overlay to protect the source from being modified
[   0.3] Initializing the target -o rhv -os 10.73.131.93:/home/nfs_export
[   0.6] Opening the overlay
[   4.4] Inspecting the overlay
[   6.2] Checking for sufficient free disk space in the guest
[   6.2] Estimating space required on target for each disk
[   6.2] Converting Windows 10 Enterprise to run on KVM
virt-v2v: warning: /usr/share/virt-tools/pnp_wait.exe is missing.  
Firstboot scripts may conflict with PnP.
virt-v2v: warning: there is no QXL driver for this version of Windows (10.0 
i386).  virt-v2v looks for this driver in /usr/share/virtio-win

The guest will be configured to use a basic VGA display driver.
virt-v2v: This guest has virtio drivers installed.
[   8.4] Mapping filesystem data to avoid copying unused and blank areas
[   8.8] Closing the overlay
[   9.1] Checking if the guest needs BIOS or UEFI to boot
[   9.1] Assigning disks to buses
[   9.1] Copying disk 1/1 to /tmp/v2v.fw1mqe/4f699f1d-7f77-4e73-a0d2-a3b73c1a0c29/images/bdbe6632-fad9-4f30-b6e0-3891f259a04b/01bb7dd9-faa3-4621-b458-2a2cb190be69 (qcow2)
    (100.00/100%)
[ 124.2] Creating output metadata
[ 124.3] Finishing off
2.Import the guest from export domain to data domain after finishing v2v conversion
3.Power on the guest after finishing
4:Repeat steps1-3 more than 20 times

All win10 and win2016 guests could be converted successfully and checkpoints are passed.

So,I think the bug has verified, move the bug status to VERIFIED

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