Bug 2046689 - Creating a VM from Template (clone) does not copy/unable to set backup property
Summary: Creating a VM from Template (clone) does not copy/unable to set backup property
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: BLL.Storage
Version: 4.4.9.5
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ovirt-4.5.1
: ---
Assignee: shani
QA Contact: shani
URL:
Whiteboard:
: 2081554 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-01-27 08:59 UTC by Jean-Louis Dupond
Modified: 2022-06-23 05:57 UTC (History)
7 users (show)

Fixed In Version: ovirt-engine-4.5.1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-06-20 14:50:58 UTC
oVirt Team: Storage
Embargoed:
pm-rhel: ovirt-4.5?


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github oVirt ovirt-engine pull 398 0 None open core: allow setting the 'backup' flag while creating a VM from a temp… 2022-05-29 12:43:34 UTC
Red Hat Issue Tracker RHV-44553 0 None None None 2022-01-27 09:05:47 UTC

Description Jean-Louis Dupond 2022-01-27 08:59:33 UTC
Description of problem:
When creating an independent/cloned VM from a template. You cannot set the backup_mode to incremental on creation.
Its only possible to set it after creation.


How reproducible:
Always

Steps to Reproduce:
1. Create a VM from a Template
2. On the disk_attachment set disk.backup = virtsdk4.types.DiskBackup.INCREMENTAL


Actual results:
The VM gets created, but its not having incremental mode enabled on the disk


Additional info:
My guess is that the root cause is in the following code:
https://github.com/oVirt/ovirt-engine/blob/master/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/AddVmFromTemplateCommand.java#L121

Here you see only some parameters are copied/used, the rest is just ignored.
I think we should add all relevant parameters here?

Comment 1 RHEL Program Management 2022-01-27 13:26:31 UTC
The documentation text flag should only be set after 'doc text' field is provided. Please provide the documentation text and set the flag to '?' again.

Comment 2 Benny Zlotnik 2022-02-08 15:29:08 UTC
Nir, is there any reason not allow this setting or do this differently?

Comment 3 Nir Soffer 2022-02-08 16:36:26 UTC
I think we decided not to persist the backup mode in templates, since it is not
clear that when creating new vm from template you should magically get
backup=incremental from the template.

But when creating a vm from template using the API, when a user specify
backup=incremental, we must respect this value. If we don't respect it, there
is no way to create a new vm using qcow2 preallocated on block storage, or
thin qcow2 on file storage (would become raw-sparse).

Comment 4 Arik 2022-05-09 07:21:32 UTC
*** Bug 2081554 has been marked as a duplicate of this bug. ***

Comment 5 Avihai 2022-06-20 10:42:01 UTC
QE is on a really tight schedule in 4.5.1 with many other bugs to verify, CNACK on capacity from QE side.
As this bug changed severity to high at the last moment(yesterday) and the verification deadline is this week this will be on best effort.

Comment 6 Arik 2022-06-20 14:51:23 UTC
Closed based on DEV verification for the fix

Comment 7 Sandro Bonazzola 2022-06-23 05:57:04 UTC
This bugzilla is included in oVirt 4.5.1 release, published on June 22nd 2022.
Since the problem described in this bug report should be resolved in oVirt 4.5.1 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.


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