Bug 1301892

Summary: internal error: Invalid or not yet handled value 'emptyBackingString' for VMX entry 'ide1:0.fileName' for device type 'cdrom-image'
Product: Red Hat Enterprise Linux 7 Reporter: Marcel Kolaja <mkolaja>
Component: libvirtAssignee: Michal Privoznik <mprivozn>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: high Docs Contact:
Priority: high    
Version: 7.2CC: acanan, bugs, danken, dyuan, eblake, ian, jdenemar, jherrman, jsuchane, michal.skrivanek, mprivozn, nsoffer, rbalakri, shavivi, snagar, tjelinek, tzheng, ylavi
Target Milestone: rcKeywords: Upstream, ZStream
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: libvirt-1.2.17-13.el7_2.3 Doc Type: Bug Fix
Doc Text:
Previously, when using the libvirt library with the VMWare ESXi hypervisor, loading a guest virtual machine that contained empty CD-ROM images failed with an "internal error" message. With this update, libvirt is able to successfully parse ESXi configuration values for empty CD-ROM images, and the described failure no longer occurs.
Story Points: ---
Clone Of: 1275039 Environment:
Last Closed: 2016-02-16 11:16:33 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1275039    
Bug Blocks: 1266088    

Description Marcel Kolaja 2016-01-26 09:54:15 UTC
This bug has been copied from bug #1275039 and has been proposed
to be backported to 7.2 z-stream (EUS).

Comment 6 tingting zheng 2016-01-28 07:57:18 UTC
Reproduce this bug with:
libvirt-1.2.17-13.el7_2.2.x86_64

Steps:
1.In esx 6.0,find a guest,modify it's vmx file as below:
From:
ide1:0.deviceType = "cdrom-image"
ide1:0.fileName =  "/vmfs/volumes/f0a07907-3759bde7/en_win_srv_2003_r2_enterprise_with_sp2_cd1_X13-05460.iso"                        ide1:0.present = "TRUE"

to:
ide1:0.deviceType = "cdrom-image"
ide1:0.fileName = "emptyBackingString"    ----> modify this value                                                     
ide1:0.present = "TRUE"

2.Save the above change,from vsphere client,I can see in "CD/DVD driver 1" shows iso File path as "[]".

3.Use virsh to connect the esx server and dumpxml the xml of the above guest.
# virsh -c esx://$esx/?no_verify=1
Enter username for $esx [root]: 
Enter root's password for $esx: 

virsh # list --all
 Id    Name                           State
----------------------------------------------------
 1     win2012R2-vcenter              running
 33    iscsi-test                     running
 43    VMware-vcenter-server-app      running
 -     app_vcenter600                 shut off
 -     Auto-esx6.0-win7-efi           shut off
 -     bug1260689-win2008R2-GPO-Macfee shut off
 -     esx6.0-rhel5.11-i386           shut off
 -     esx6.0-rhel5.11-x86_64         shut off
 -     esx6.0-rhel6.7-i386            shut off
 -     esx6.0-rhel6.7-x86_64          shut off
 -     esx6.0-rhel7.2-x86_64          shut off
 -     esx6.0-win2003-i386            shut off
 -     esx6.0-win2003-x86_64          shut off
 -     esx6.0-win2008-i386            shut off
 -     esx6.0-win2008-x86_64          shut off
 -     test-juzhou                    shut off


virsh # dumpxml test-juzhou
error: internal error: Invalid or not yet handled value 'emptyBackingString' for VMX entry 'ide1:0.fileName' for device type 'cdrom-image'

Verify the bug with:
libvirt-1.2.17-13.el7_2.3.x86_64

In the steps as above,in step3,the result shows as below:
virsh # dumpxml test-juzhou
<domain type='vmware'>
  <name>test-juzhou</name>
  <uuid>423f34eb-61a7-72db-5a24-2f6088db68bd</uuid>
  <memory unit='KiB'>2097152</memory>
  <currentMemory unit='KiB'>2097152</currentMemory>
  <vcpu placement='static'>1</vcpu>
  <cputune>
    <shares>1000</shares>
  </cputune>
  <os>
    <type arch='x86_64'>hvm</type>
  </os>
  <clock offset='utc'/>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>destroy</on_crash>
  <devices>
    <disk type='file' device='disk'>
      <source file='[datastore1] test-juzhou/test-juzhou.vmdk'/>
      <target dev='sda' bus='scsi'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
    </disk>
    <disk type='file' device='disk'>
      <source file='[datastore1] test-juzhou/test-juzhou_1.vmdk'/>
      <target dev='sdb' bus='scsi'/>
      <address type='drive' controller='0' bus='0' target='0' unit='1'/>
    </disk>
    <disk type='file' device='cdrom'>
      <target dev='hdc' bus='ide'/>
      <address type='drive' controller='0' bus='1' target='0' unit='0'/>
    </disk>
    <controller type='scsi' index='0' model='vmpvscsi'/>
    <controller type='ide' index='0'/>
    <interface type='bridge'>
      <mac address='00:50:56:bf:3e:50'/>
      <source bridge='VM Network'/>
      <model type='vmxnet3'/>
    </interface>
    <video>
      <model type='vmvga' vram='8192'/>
    </video>
  </devices>
</domain>

For the guest,the xml file can be got successfully via virsh dumpxml,so the bug is fixed and move the bug to VERIFIED.

Comment 8 errata-xmlrpc 2016-02-16 11:16:33 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/RHBA-2016-0220.html