Description of problem: Cannot import any VM from my KVM server. I keep hitting the following error: 2018-09-24 13:20:06,559+10 WARN [org.ovirt.engine.core.bll.exportimport.ImportVmFromExternalProviderCommand] (default task-4) [] Validation of action 'ImportVmFromExternalProvider' failed for user admin@internal-authz. Reasons: VAR__ACTION__IMPORT,VAR__TYPE__VM,ERROR_CANNOT_FIND_ISO_IMAGE_PATH But: 1 - The guest being imported has no CD on its drive, its empty 2 - Even deleting the CD drive from the VM definition is still hits the same error. Version-Release number of selected component (if applicable): ovirt-engine-4.2.6.4-1.el7.noarch How reproducible: 100% Steps to Reproduce: 1. Import VM from KVM Additional info: This is from ImportVmFromExternalProviderCommand.java: if (getParameters().getVirtioIsoName() != null && getActiveIsoDomainId() == null) { return failValidation(EngineMessage.ERROR_CANNOT_FIND_ISO_IMAGE_PATH); } The workaround was to add an ISO Domain. But still, seems like getVirtioIsoName() does not return null if the CD is empty or non-existent. Guest XML: <domain type='kvm'> <name>centos7.0</name> <uuid>dc23b487-4c42-4098-a5f3-1247f0114cde</uuid> <memory unit='KiB'>786432</memory> <currentMemory unit='KiB'>786432</currentMemory> <vcpu placement='static'>1</vcpu> <os> <type arch='x86_64' machine='pc-i440fx-2.11'>hvm</type> <boot dev='hd'/> </os> <features> <acpi/> <apic/> <vmport state='off'/> </features> <cpu mode='custom' match='exact' check='partial'> <model fallback='allow'>Haswell-noTSX-IBRS</model> </cpu> <clock offset='utc'> <timer name='rtc' tickpolicy='catchup'/> <timer name='pit' tickpolicy='delay'/> <timer name='hpet' present='no'/> </clock> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>destroy</on_crash> <pm> <suspend-to-mem enabled='no'/> <suspend-to-disk enabled='no'/> </pm> <devices> <emulator>/usr/bin/qemu-kvm</emulator> <disk type='file' device='disk'> <driver name='qemu' type='qcow2'/> <source file='/var/lib/libvirt/images/centos7.0.qcow2'/> <target dev='vda' bus='virtio'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/> </disk> <controller type='usb' index='0' model='ich9-ehci1'> <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x7'/> </controller> <controller type='usb' index='0' model='ich9-uhci1'> <master startport='0'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0' multifunction='on'/> </controller> <controller type='usb' index='0' model='ich9-uhci2'> <master startport='2'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x1'/> </controller> <controller type='usb' index='0' model='ich9-uhci3'> <master startport='4'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x2'/> </controller> <controller type='pci' index='0' model='pci-root'/> <controller type='ide' index='0'> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/> </controller> <controller type='virtio-serial' index='0'> <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/> </controller> <serial type='pty'> <target type='isa-serial' port='0'> <model name='isa-serial'/> </target> </serial> <console type='pty'> <target type='serial' port='0'/> </console> <channel type='unix'> <target type='virtio' name='org.qemu.guest_agent.0'/> <address type='virtio-serial' controller='0' bus='0' port='1'/> </channel> <channel type='spicevmc'> <target type='virtio' name='com.redhat.spice.0'/> <address type='virtio-serial' controller='0' bus='0' port='2'/> </channel> <input type='mouse' bus='ps2'/> <input type='keyboard' bus='ps2'/> <graphics type='spice' autoport='yes'> <listen type='address'/> <image compression='off'/> </graphics> <video> <model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1' primary='yes'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/> </video> <memballoon model='virtio'> <address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/> </memballoon> </devices> </domain>
Likely to be fixed as a side effect of the ISO domain -> data domain changes
Still happening on ovirt-engine-4.3.6.7-1.el7.noarch. It's annoying to have to add an ISO domain to import VMs from KVM.
We should not require virtio at all when importing from libvirt as we don't modify the VM but only copy its disks.
I was able to import a KVM on a clean install without an ISO Domain on 4.4. Maybe we can retest this with the current version? 4.2 is no longer supported.
(In reply to Steven Rosenberg from comment #4) > I was able to import a KVM on a clean install without an ISO Domain on 4.4. > Maybe we can retest this with the current version? 4.2 is no longer > supported. Sorry for the delay, I was on leave. If you say it is working on 4.4 then the bug can be closed after passing QE. But do you know what fixed it? The code triggering the error still seems to be in 4.4: https://github.com/oVirt/ovirt-engine/blob/14967178f54e1017f379a07587d7c27b228eeaf1/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/exportimport/ImportVmFromExternalProviderCommand.java#L182 Would be nice to know what fixed it to attach to the BZ.
Steven, could it be that you didn't have the virtio ISO at all on your data center? To make sure it doesn't happen anymore we need to import from KVM in an environment that has the virtio ISO on some data domain and no ISO domain defined.
It's working for me on 4.4 Beta refresh, so the initial problem described in comment #0 is now fixed. But I did not test with virtio ISO on data domain (4.4 guest tools iso not found on the customer portal)
(In reply to Arik from comment #6) > Steven, could it be that you didn't have the virtio ISO at all on your data > center? > To make sure it doesn't happen anymore we need to import from KVM in an > environment that has the virtio ISO on some data domain and no ISO domain > defined. Right, and this fails easily on first try for me. In a simple minimal setup with: * No ISO Domain on the DC * virtio-win-1.9.12.iso uploaded to Data Domain Importing from KVM fails: 2020-07-23 11:01:28,070+10 WARN [org.ovirt.engine.core.bll.exportimport.ImportVmFromExternalProviderCommand] (default task-15) [] Validation of action 'ImportVmFromExternalProvider' failed for user admin@internal-authz. Reasons: VAR__ACTION__IMPORT,VAR__TYPE__VM,ERROR_CANNOT_FIND_ISO_IMAGE_PATH
Verified: ovirt-engine-4.4.3.5-0.5.el8ev vdsm-4.40.32-1.el8ev.x86_64 libvirt-daemon-6.6.0-6.module+el8.3.0+8125+aefcf088.x86_64 qemu-kvm-5.1.0-10.module+el8.3.0+8254+568ca30d.x86_64 KVM server: RHEL 7.9 qemu-kvm-1.5.3-175.el7.x86_64 Verification scenario: 1. Import KVM VM: with CD HW and CD media selected to RHV: without ISO domain and without virtio ISO drivers in data domain 2. Import KVM VM: With CD HW and CD media selected to RHV: without ISO domain and with virtio ISO drivers in data domain 3. Repeat steps 1-2, this time without CD media in KVM VM. 4. Import KVM VM: With CD HW and without media selected to RHV: with ISO domain 5. Import KVM VM: With CD HW and with media selected to RHV: with ISO domain 6. Run all imported VMs and verify VMs are running properly.
This bugzilla is included in oVirt 4.4.3 release, published on November 10th 2020. Since the problem described in this bug report should be resolved in oVirt 4.4.3 release, it has been closed with a resolution of CURRENT RELEASE. If the solution does not work for you, please open a new bug report.