Bug 1484379

Summary: Import VM fails with libvirtError: this function is not supported by the connection driver: virDomainGetBlockInfo
Product: Red Hat Enterprise Linux 7 Reporter: Jaroslav Spanko <jspanko>
Component: libvirtAssignee: Libvirt Maintainers <libvirt-maint>
Status: CLOSED NOTABUG QA Contact: Han Han <hhan>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.3CC: dyuan, hhan, jdenemar, jliberma, jsuchane, kuwei, lmen, michal.skrivanek, mxie, rbalakri, rjones, tzheng, xuzhang
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-08-28 10:20:24 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:
Embargoed:
Bug Depends On:    
Bug Blocks: 1485807    
Attachments:
Description Flags
worked VM
none
not worked none

Description Jaroslav Spanko 2017-08-23 12:08:52 UTC
Description of problem:

When trying to select VM for the import it fails with message
~~~
All chosen VMs couldn't be retrieved by the external system and therefore have been filtered. Please see log for details.
~~~
engine.log
~~~
2017-08-22 08:09:03,750-04 INFO  [org.ovirt.engine.core.vdsbroker.vdsbroker.GetVmsFullInfoFromExternalProviderVDSCommand] (default task-130) [65ff9fb2-25e4-44a2-90fd-cb5a55e17e02] START, GetVmsFullInfoFromExternalProviderVDSCommand(HostName = rhvhsrv03, GetVmsFromExternalProviderParameters:{runAsync='true', hostId='3c4e0144-c1be-4bad-8737-dfa749a86f1f', 
url='vpx://XXXXXX?no_verify=1', username='root', originType='VMWARE', namesOfVms='[rh73-clone]'}), log id: 6ab41bac
2017-08-22 08:09:05,315-04 INFO  [org.ovirt.engine.core.vdsbroker.vdsbroker.GetVmsFullInfoFromExternalProviderVDSCommand] (default task-130) [65ff9fb2-25e4-44
a2-90fd-cb5a55e17e02] FINISH, GetVmsFullInfoFromExternalProviderVDSCommand, return: [], log id: 6ab41bac
~~~
vdsm.log 
~~~
2017-08-22 08:10:23,255-0400 ERROR (jsonrpc/5) [root] Error getting disk size (v2v:1089)
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/vdsm/v2v.py", line 1081, in _get_disk_info
    vol = vm.blockInfo(disk['alias'])
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 694, in blockInfo
    if ret is None: raise libvirtError ('virDomainGetBlockInfo() failed', dom=self)
libvirtError: this function is not supported by the connection driver: virDomainGetBlockInfo
2017-08-22 08:10:23,255-0400 WARN  (jsonrpc/5) [root] Cannot add VM rh73-clone due to disk storage error (v2v:1020)
~~~

Version-Release number of selected component (if applicable):
libvirt-3.2.0-14.el7_4.2.x86_64
RHV 4.1.4
ESX 6.0

Steps to Reproduce:
1. Import VM - select 
2. All chosen VMs couldn't be retrieved 


Actual results:
libvirtError: this function is not supported by the connection driver: virDomainGetBlockInfo

Expected results:
The VM passed the test

Comment 2 Jiri Denemark 2017-08-23 15:12:54 UTC
This looks like a bug in RHV's v2v code. The virDomainGetBlockInfo is only implemented in qemu driver. Calling it on a vpx:// connection will always return "this function is not supported" error.

Comment 3 Jaroslav Spanko 2017-08-24 15:47:45 UTC
Created attachment 1317806 [details]
worked VM

Comment 4 Jaroslav Spanko 2017-08-24 15:49:03 UTC
Created attachment 1317807 [details]
not worked

Comment 5 Michal Skrivanek 2017-08-28 08:47:03 UTC
currently doesn't seem to be worth fixing, the only case we encountered so far was with CD-ROM block device which is addressed on RHV side by bug 1485807

Comment 6 Jaroslav Suchanek 2017-08-28 10:20:24 UTC
Per comment 5 closing as notabug.