My Oracle Support Banner

OLVM : OVA Import Fails with "ERROR: insert or update on table vm_static violates foreign key constraint" (Doc ID 2744466.1)

Last updated on MARCH 29, 2022

Applies to:

Linux OS - Version Oracle Linux 7.9 with Unbreakable Enterprise Kernel [5.4.17] and later
Linux x86-64

Symptoms

OVA import in OLVM GUI fails with following error event :

EVENT_ID: IMPORTEXPORT_IMPORT_VM_FAILED(1,153), Failed to import Vm <VM_name> to Data Center <Data_Center_name>, Cluster <Cluster_name>

Following error appears in engine.log :

2021-01-14 13:45:10,730+02 INFO [org.ovirt.engine.core.bll.exportimport.ImportVmFromOvaCommand] (default task-11) [5f759569-f4c0-45fe-9f95-3b1e99de70ed] Lock Acquired to object 'EngineLock:{exclusiveLocks='[f9f048bf-6265-498c-a648-0df3f3a3ab4b=VM, <VM_NAME>=VM_NAME]', sharedLocks=''}'
2021-01-14 13:45:10,906+02 INFO [org.ovirt.engine.core.bll.exportimport.ImportVmFromOvaCommand] (EE-ManagedThreadFactory-engine-Thread-30130) [5f759569-f4c0-45fe-9f95-3b1e99de70ed] Running command: ImportVmFromOvaCommand internal: false. Entities affected : ID: 5dabe056-aa38-11ea-9c40-00163e0e8af8 Type:ClusterAction group CREATE_VM with role type USER, ID: dc3c26af-f805-4ec6-94e1-5ba63522d710 Type: StorageAction group IMPORT_EXPORT_VM with role type ADMIN
2021-01-14 13:45:10,989+02 INFO [org.ovirt.engine.core.utils.transaction.TransactionSupport] (EE-ManagedThreadFactory-engine-Thread-30130) [5f759569-f4c0-45fe-9f95-3b1e99de70ed] transaction rolled back
2021-01-14 13:45:10,990+02 WARN [org.ovirt.engine.core.bll.network.macpool.TransactionalMacPoolDecorator] (EE-ManagedThreadFactory-engine-Thread-30130) [5f759569-f4c0-45fe-9f95-3b1e99de70ed] Trying to release MACs using empty collection as parameter.
2021-01-14 13:45:11,003+02 ERROR [org.ovirt.engine.core.bll.exportimport.ImportVmFromOvaCommand] (EE-ManagedThreadFactory-engine-Thread-30130) [5f759569-f4c0-45fe-9f95-3b1e99de70ed] Command 'org.ovirt.engine.core.bll.exportimport.ImportVmFromOvaCommand' failed: CallableStatementCallback; SQL [{call insertvmstatic(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)}ERROR: insert or update on table "vm_static" violates foreign key constraint "fk_vm_static_lease_sd_id_storage_domain_static_id"
Detail: Key (lease_sd_id)=(c875ce88-8dec-40b6-83b2-a4359eadabe9) is not present in table "storage_domain_static".

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.