Bug 1828025 - Export template to OVA fails on NullPointerException
Summary: Export template to OVA fails on NullPointerException
Keywords:
Status: CLOSED DUPLICATE of bug 1825638
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: BLL.Virt
Version: 4.4.0
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
: ---
Assignee: Nobody
QA Contact: meital avital
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-04-26 10:15 UTC by Tamir
Modified: 2020-04-27 04:25 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-04-27 04:25:32 UTC
oVirt Team: Virt
Embargoed:


Attachments (Terms of Use)

Description Tamir 2020-04-26 10:15:29 UTC
Created attachment 1681850 [details]
Logs and created OVA were attached

Description of problem:
When exporting a template that was created from a VM under 4.4 cluster in 4.4.0-31 engine to OVA, the action fails and in the engine.log there is a NullPointerException. But the OVA appears in the folder I chose.

2020-04-26 12:14:00,757+03 ERROR [org.ovirt.engine.core.bll.CreateOvaCommand] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] Command 'org.ovirt.engine.core.bll.CreateOvaCommand' failed: null
2020-04-26 12:14:00,757+03 ERROR [org.ovirt.engine.core.bll.CreateOvaCommand] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] Exception: java.lang.NullPointerException
        at deployment.engine.ear.bll.jar//org.ovirt.engine.core.bll.CreateOvaCommand.executeCommand(CreateOvaCommand.java:87)
....

 2020-04-26 12:14:00,759+03 ERROR [org.ovirt.engine.core.bll.exportimport.ExportVmTemplateToOvaCommand] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] Failed to create OVA file
2020-04-26 12:14:00,759+03 ERROR [org.ovirt.engine.core.bll.exportimport.ExportVmTemplateToOvaCommand] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] Command 'org.ovirt.engine.core.bll.exportimport.ExportVmTemplateToOvaCommand' failed: EngineException: ENGINE (Failed with error ENGINE and code 5001)
2020-04-26 12:14:00,765+03 ERROR [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] EVENT_ID: IMPORTEXPORT_EXPORT_TEMPLATE_TO_OVA_FAILED(1,228), Failed to export Template vm1_withoutdisk as a Virtual Appliance to path /root/vm1_withoutdisk.ova on Host host_mixed_1

Version-Release number of selected component (if applicable):
RHV 4.4.0-31, RHEL 8.2 on engine/host
RHEVM: org.ovirt.engine-root-4.4.0-33
VDSM: vdsm-4.30.44-1.el7ev

How reproducible:
100%

Steps to Reproduce:
1. Create a data center, a cluster, add a storage domain, and create a VM from the "Blank" template.
2. Create a template from the same VM
3. Export the template that was created as OVA

Actual results:
1 and 2 were successfully run. 
The export failed with the errors:

In the event log: Failed to export Template vm1_withoutdisk as a Virtual Appliance to path /root/vm1_withoutdisk.ova on Host host_mixed_1

In the engine.log: 
2020-04-26 12:14:00,757+03 ERROR [org.ovirt.engine.core.bll.CreateOvaCommand] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] Command 'org.ovirt.engine.core.bll.CreateOvaCommand' failed: null
2020-04-26 12:14:00,757+03 ERROR [org.ovirt.engine.core.bll.CreateOvaCommand] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] Exception: java.lang.NullPointerException
        at deployment.engine.ear.bll.jar//org.ovirt.engine.core.bll.CreateOvaCommand.executeCommand(CreateOvaCommand.java:87)
....

 2020-04-26 12:14:00,759+03 ERROR [org.ovirt.engine.core.bll.exportimport.ExportVmTemplateToOvaCommand] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] Failed to create OVA file
2020-04-26 12:14:00,759+03 ERROR [org.ovirt.engine.core.bll.exportimport.ExportVmTemplateToOvaCommand] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] Command 'org.ovirt.engine.core.bll.exportimport.ExportVmTemplateToOvaCommand' failed: EngineException: ENGINE (Failed with error ENGINE and code 5001)
2020-04-26 12:14:00,765+03 ERROR [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (EE-ManagedThreadFactory-engine-Thread-300) [22a225c9] EVENT_ID: IMPORTEXPORT_EXPORT_TEMPLATE_TO_OVA_FAILED(1,228), Failed to export Template vm1_withoutdisk as a Virtual Appliance to path /root/vm1_withoutdisk.ova on Host host_mixed_1

But the exported OVA exists in the folder I chose.

Expected results:
The OVA file is exported without errors.

Additional info:

Comment 1 Michal Skrivanek 2020-04-27 04:25:32 UTC

*** This bug has been marked as a duplicate of bug 1825638 ***


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