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 1480623 - Disable uninstallation of VMware tools (again) [rhel-7.4.z]
Summary: Disable uninstallation of VMware tools (again) [rhel-7.4.z]
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libguestfs
Version: 7.4
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: rc
: ---
Assignee: Richard W.M. Jones
QA Contact: Virtualization Bugs
URL:
Whiteboard: V2V
Depends On: 1477905
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-08-11 14:07 UTC by Jaroslav Reznik
Modified: 2017-09-05 11:30 UTC (History)
9 users (show)

Fixed In Version: libguestfs-1.36.3-6.el7_4.3
Doc Type: Bug Fix
Doc Text:
Red Hat Enterprise Linux 7.4 implemented a feature that enabled the virt-v2v utility to automatically remove VMware tools from Linux guest virtual machines that virt-v2v is converting. However, when the VMware tools on the source guest were installed from a tarball, this feature did not work correctly. As a consequence, the virt-v2v conversion took significantly longer and, in some cases, became unresponsive. With this update, virt-v2v does not attempt to remove VMware tools that were installed from a tarball, which prevents the described problem from occurring. Note that VMware tools installed using RPM packages are still removed during the conversion.
Clone Of: 1477905
Environment:
Last Closed: 2017-09-05 11:30:47 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
before-rhel7-vmware-tool (263.34 KB, image/png)
2017-08-15 12:46 UTC, mxie@redhat.com
no flags Details
before-ubuntu-vmware-tool (135.79 KB, image/png)
2017-08-15 12:47 UTC, mxie@redhat.com
no flags Details
after-ubuntu-vmware-tool (26.92 KB, image/png)
2017-08-15 12:48 UTC, mxie@redhat.com
no flags Details
before-debian-vmware-tool (100.83 KB, image/png)
2017-08-15 12:49 UTC, mxie@redhat.com
no flags Details
after-debian-vmware-tool (140.73 KB, image/png)
2017-08-15 12:49 UTC, mxie@redhat.com
no flags Details
virt-v2v-ubuntu-vmware-tool.log (1.87 MB, text/plain)
2017-08-15 12:50 UTC, mxie@redhat.com
no flags Details
virt-v2v-debian-vmware-tools.log (1.85 MB, text/plain)
2017-08-15 12:51 UTC, mxie@redhat.com
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2582 0 normal SHIPPED_LIVE libguestfs bug fix update 2017-09-05 15:18:58 UTC

Description Jaroslav Reznik 2017-08-11 14:07:26 UTC
This bug has been copied from bug #1477905 and has been proposed to be backported to 7.4 z-stream (EUS).

Comment 3 mxie@redhat.com 2017-08-15 12:45:36 UTC
Try to verify the bug with below builds:
virt-v2v-1.36.3-6.el7_4.3.x86_64
libguestfs-1.36.3-6.el7_4.3.x86_64
virtio-win-1.9.3-1.el7.noarch
libguestfs-winsupport-7.2-2.el7.x86_64
libvirt-3.2.0-14.el7_4.2.x86_64
qemu-kvm-rhev-2.9.0-16.el7_4.3.x86_64
kernel-3.10.0-693.el7.x86_64

Steps:

Due to v2v don't uninstall VMware tools in Windows guests at all according to https://bugzilla.redhat.com/show_bug.cgi?id=1155610, so just do some test scenarios on linux guests


Scenario1:convert rhel6 guest which has installed vmware tools from vmware to rhv
1.1 Install vmware tools in rhel6 guest on vsphere clinet, then related vmware tools packages will be installed in guest 
# rpm -qa |grep vmware
xorg-x11-drv-vmware-13.1.0-2.el6.x86_64
vmware-tools-libraries-nox-8.6.17-1.el6.x86_64
vmware-tools-foundation-8.6.17-1.el6.x86_64
vmware-tools-libraries-x-8.6.17-1.el6.x86_64
 
1.2 Convert guest from vmware to rhv by virt-v2v and there is no error about vmware tools during conversion
# virt-v2v -ic vpx://root.75.182/data/10.73.72.61/?no_verify=1 Auto-esx6.0-rhel6.8-vmware-tool --password-file /tmp/passwd -o rhv -os 10.73.131.93:/home/nfs_export -of raw -b ovirtmgmt 
[   0.0] Opening the source -i libvirt -ic vpx://root.75.182/data/10.73.72.61/?no_verify=1 Auto-esx6.0-rhel6.8-vmware-tool
[   1.6] Creating an overlay to protect the source from being modified
[   2.3] Initializing the target -o rhv -os 10.73.131.93:/home/nfs_export
[   2.6] Opening the overlay
[  33.9] Inspecting the overlay
[ 126.2] Checking for sufficient free disk space in the guest
[ 126.2] Estimating space required on target for each disk
[ 126.2] Converting Red Hat Enterprise Linux Server release 6.8 (Santiago) to run on KVM
virt-v2v: This guest has virtio drivers installed.
[ 857.9] Mapping filesystem data to avoid copying unused and blank areas
[ 859.0] Closing the overlay
[ 859.2] Checking if the guest needs BIOS or UEFI to boot
[ 859.2] Assigning disks to buses
[ 859.2] Copying disk 1/1 to /tmp/v2v.HyjMRX/bdf9c90b-e6f0-439c-aa9f-6305fd5fad7e/images/fc12edb8-8c6d-4de2-a19e-3d1041400e35/954c891a-79b3-4917-9dcb-2fc7afb4d8fa (raw)
    (100.00/100%)
[2215.5] Creating output metadata
[2215.6] Finishing off

1.3 After finishing conversion, check whether there is vmware tools package in guest
# rpm -qa |grep vmware
xorg-x11-drv-vmware-13.1.0-2.el6.x86_64

Result:
Related vmware tools packages could be removed successfully for rhel6 guest during virt-v2v conversion 


Scenario2:convert rhel7 guest which has installed vmware tools from vmware to kvm
2.1 Install vmware tools in rhel7 guest on vsphere clinet, then vmware tools service will be running in guest after finshing vmware tools installation and reboot guest, pls refer to screenshot "before-rhel7-vmware-tool.png"  
#service vmware-tools status
vmtoolsd is running

2.2 Convert guest from vmware to kvm by virt-v2v and there is no error about vmware tools during conversion
# virt-v2v -ic vpx://root.75.182/data/10.73.72.61/?no_verify=1 esx6.0-rhel7.4-uefi-vmware-tool  --password-file /tmp/passwd
[   0.0] Opening the source -i libvirt -ic vpx://root.75.182/data/10.73.72.61/?no_verify=1 esx6.0-rhel7.4-uefi-vmware-tool
[   1.2] Creating an overlay to protect the source from being modified
[   1.9] Initializing the target -o libvirt -os default
[   1.9] Opening the overlay
[  14.8] Inspecting the overlay
[ 114.0] Checking for sufficient free disk space in the guest
[ 114.0] Estimating space required on target for each disk
[ 114.0] Converting Red Hat Enterprise Linux Server 7.4 Beta (Maipo) to run on KVM
virt-v2v: This guest has virtio drivers installed.
[ 890.6] Mapping filesystem data to avoid copying unused and blank areas
virt-v2v: warning: fstrim on guest filesystem /dev/sda1 failed.  Usually 
you can ignore this message.  To find out more read "Trimming" in 
virt-v2v(1).

Original message: fstrim: fstrim: /sysroot/: the discard operation is not 
supported
[ 892.2] Closing the overlay
[ 892.4] Checking if the guest needs BIOS or UEFI to boot
virt-v2v: This guest requires UEFI on the target to boot.
[ 892.4] Assigning disks to buses
[ 892.4] Copying disk 1/1 to /var/lib/libvirt/images/esx6.0-rhel7.4-uefi-vmware-tool-sda (raw)
    (100.00/100%)
[2405.7] Creating output metadata
Pool default refreshed

Domain esx6.0-rhel7.4-uefi-vmware-tool defined from /tmp/v2vlibvirta3d69e.xml

[2406.0] Finishing off


2.3 After finishing conversion, check whether vmware tools service is running in guest
#service vmware-tools status
vmtoolsd is not running


Result:
VMware tools service will be stopped for rhel7 guest during virt-v2v conversion



Scenario3:convert ubuntu guest which has installed vmware tools from vmware to rhv
3.1 Install vmware tools in ubuntu guest on vsphere clinet, then vmware tools service will be running in guest after finshing vmware tools installation and reboot guest, pls refer to screenshot "before-ubuntu-vmware-tool.png"  

3.2 Convert guest from vmware to rhv by virt-v2v and there is no error about vmware tool during conversion
# virt-v2v -ic vpx://root.75.182/data/10.73.72.61/?no_verify=1 esx6.0-ubuntu16.04-i386 --password-file /tmp/passwd -o rhv -os 10.73.131.93:/home/nfs_export
[   0.0] Opening the source -i libvirt -ic vpx://root.75.182/data/10.73.72.61/?no_verify=1 esx6.0-ubuntu16.04-i386
[   1.6] Creating an overlay to protect the source from being modified
[   2.6] Initializing the target -o rhv -os 10.73.131.93:/home/nfs_export
[   3.2] Opening the overlay
[  18.0] Inspecting the overlay
[  29.0] Checking for sufficient free disk space in the guest
[  29.0] Estimating space required on target for each disk
[  29.0] Converting Ubuntu 16.04.1 LTS to run on KVM
virt-v2v: warning: could not determine a way to update the configuration of 
Grub2
virt-v2v: This guest has virtio drivers installed.
[ 549.1] Mapping filesystem data to avoid copying unused and blank areas
[ 561.2] Closing the overlay
[ 561.4] Checking if the guest needs BIOS or UEFI to boot
[ 561.4] Assigning disks to buses
[ 561.4] Copying disk 1/1 to /tmp/v2v.jElqOA/bdf9c90b-e6f0-439c-aa9f-6305fd5fad7e/images/104a2110-2542-4182-a003-1deff17b8859/744a46e5-8f53-4075-b5cd-74aea67dd1f5 (raw)
    (100.00/100%)
[1941.4] Creating output metadata
[1941.5] Finishing off

3.3 After finishing conversion, vmware tools service is still running in guest,pls refer to screenshot "after-ubuntu-vmware-tool.png"  


Result:
VMware tools service can't be stopped for ubuntu guest during virt-v2v conversion, pls refer to log "virt-v2v-ubuntu-vmware-tool.log"



Scenario4:convert debian guest which has installed vmware tools from vmware to rhv
4.1 Install vmware tools in debian guest on vsphere clinet, then vmware tools service will be running in guest after finshing vmware tool installation and reboot guest, pls refer to screenshot "before-debian-vmware-tool.png"  

4.2 Convert guest from vmware to rhv by virt-v2v and there is no error about vmware tools during conversion
# virt-v2v -ic vpx://root.75.182/data/10.73.72.75/?no_verify=1 esx5.1-debian8.7.1-x86_64 --password-file /tmp/passwd -o rhv -os 10.73.131.93:/home/nfs_export
[   0.0] Opening the source -i libvirt -ic vpx://root.75.182/data/10.73.72.75/?no_verify=1 esx5.1-debian8.7.1-x86_64
[   1.2] Creating an overlay to protect the source from being modified
[   1.7] Initializing the target -o rhv -os 10.73.131.93:/home/nfs_export
[   1.9] Opening the overlay
[  10.4] Inspecting the overlay
[  19.0] Checking for sufficient free disk space in the guest
[  19.0] Estimating space required on target for each disk
[  19.0] Converting 8.7 to run on KVM
virt-v2v: warning: could not determine a way to update the configuration of 
Grub2
virt-v2v: This guest has virtio drivers installed.
[ 238.5] Mapping filesystem data to avoid copying unused and blank areas
[ 240.2] Closing the overlay
[ 240.5] Checking if the guest needs BIOS or UEFI to boot
[ 240.5] Assigning disks to buses
[ 240.5] Copying disk 1/1 to /tmp/v2v.UZn8LX/bdf9c90b-e6f0-439c-aa9f-6305fd5fad7e/images/4cc030be-a338-4da7-bb63-97bf8af24548/13281456-abd8-4ef7-9584-df285656f7dc (raw)
    (100.00/100%)
[2939.2] Creating output metadata
[2939.3] Finishing off


4.3 After finishing conversion, vmware tools service is still running in guest,pls refer to screenshot "after-debian-vmware-tool.png"  


Result:
VMware tools service can't be stopped for debian guest during virt-v2v conversion, pls refer to log "virt-v2v-debian-vmware-tools.log"


Hi Pino,

  Please help to look at scenario3 and scenario4's test result, whether v2v support uninstall vmware tools for ubuntu and debain guests?

Comment 4 mxie@redhat.com 2017-08-15 12:46:33 UTC
Created attachment 1313655 [details]
before-rhel7-vmware-tool

Comment 5 mxie@redhat.com 2017-08-15 12:47:12 UTC
Created attachment 1313657 [details]
before-ubuntu-vmware-tool

Comment 6 mxie@redhat.com 2017-08-15 12:48:11 UTC
Created attachment 1313659 [details]
after-ubuntu-vmware-tool

Comment 7 mxie@redhat.com 2017-08-15 12:49:09 UTC
Created attachment 1313661 [details]
before-debian-vmware-tool

Comment 8 mxie@redhat.com 2017-08-15 12:49:46 UTC
Created attachment 1313663 [details]
after-debian-vmware-tool

Comment 9 mxie@redhat.com 2017-08-15 12:50:38 UTC
Created attachment 1313665 [details]
virt-v2v-ubuntu-vmware-tool.log

Comment 10 mxie@redhat.com 2017-08-15 12:51:50 UTC
Created attachment 1313667 [details]
virt-v2v-debian-vmware-tools.log

Comment 11 Pino Toscano 2017-08-15 13:14:07 UTC
(In reply to mxie from comment #3)
> Scenario1:convert rhel6 guest which has installed vmware tools from vmware
> to rhv
> 1.1 Install vmware tools in rhel6 guest on vsphere clinet, then related
> vmware tools packages will be installed in guest 
> # rpm -qa |grep vmware
> xorg-x11-drv-vmware-13.1.0-2.el6.x86_64
> vmware-tools-libraries-nox-8.6.17-1.el6.x86_64
> vmware-tools-foundation-8.6.17-1.el6.x86_64
> vmware-tools-libraries-x-8.6.17-1.el6.x86_64

Note the fix for this bug disables the uninstallation of VMware tools installed from tarball, so with a /usr/bin/vmware-uninstall-tools.pl script to uninstall them.  The removal of packages is still performed, since it was tested correctly when it was fixed, and even your scenarios here show it works fine.

> 1.3 After finishing conversion, check whether there is vmware tools package
> in guest
> # rpm -qa |grep vmware
> xorg-x11-drv-vmware-13.1.0-2.el6.x86_64

This is just the Xorg driver, which most probably should be uninstalled as well, although that's out of the scope of this bug.
It's harmless anyway, so not a short-term problem.

>   Please help to look at scenario3 and scenario4's test result, whether v2v
> support uninstall vmware tools for ubuntu and debain guests?

The uninstallation of the packages of VMware tools from Debian/Ubuntu guests is not supported yet.  Can you please open a new bug, attaching the  virt-v2v-ubuntu-vmware-tool.log and virt-v2v-debian-vmware-tools.log logs, so we can track it?

Thanks!

Comment 12 mxie@redhat.com 2017-08-16 05:45:59 UTC
Thanks Pino, I think "xorg-x11-drv-vmware-13.1.0-2.el6.x86_64" is not package of vmware tools because non-vmware OS also has this package, in addition,I have filed new bug1481930 to track problem of scenario3 and scenario4 of comment3. so move this bug from ON_QA to VERIFIED

Comment 14 errata-xmlrpc 2017-09-05 11:30: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, 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:2582


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