Bug 1990298 - [CinderLib] Block cloning a vm from vm snapshot
Summary: [CinderLib] Block cloning a vm from vm snapshot
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: BLL.Storage
Version: 4.4.8.2
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ovirt-4.5.0
: 4.5.0
Assignee: shani
QA Contact: Shir Fishbain
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-08-05 08:08 UTC by sshmulev
Modified: 2022-04-20 06:33 UTC (History)
3 users (show)

Fixed In Version: ovirt-engine-4.5.0
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-04-20 06:33:59 UTC
oVirt Team: Storage
Embargoed:
pm-rhel: ovirt-4.5?
pm-rhel: planning_ack?
pm-rhel: devel_ack+
pm-rhel: testing_ack+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHV-42967 0 None None None 2022-02-09 08:27:12 UTC

Description sshmulev 2021-08-05 08:08:11 UTC
Description of problem:
Clone VM-by generated snapshot doesn't work.

Version-Release number of selected component (if applicable):
ovirt-engine-4.4.8.2-0.11.el8ev.noarch
vdsm-4.40.80.3-1.el8ev.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Create VM from a template(latest-rhel-guest-image-8.3-infra) and attach MBS disk to it.
2. Go to snapshots -> clone VM -> "auto generate snapshot for VM" should be created. (Also fails - The snapshot is created but the cloned VM is not)
3. Clone by the generated snapshot.

Actual results:
Clone VM does not work when the VM has attached MBS disk.

2021-08-05 10:16:49,524+03 ERROR [org.ovirt.engine.core.common.utils.cinderlib.CinderlibExecutor] (EE-ManagedScheduledExecutorService-engineScheduledThreadPool-Thread-28) [69db761e] cinderlib execution failed: 
2021-08-05 10:16:49,555+03 ERROR [org.ovirt.engine.core.bll.SerialChildCommandsExecutionCallback] (EE-ManagedScheduledExecutorService-engineScheduledThreadPool-Thread-28) [69db761e] Command 'CloneVm' id: '81b9f950-62b6-4741-9ebb-029d94072241' with children [92fdbfac-528e-4c68-9954-0066d2d8ea47, d4a08eae-6cd1-4299-b2e6-4d90e651a0d1] failed when attempting to perform the next operation, marking as 'ACTIVE'
2021-08-05 10:16:49,555+03 ERROR [org.ovirt.engine.core.bll.SerialChildCommandsExecutionCallback] (EE-ManagedScheduledExecutorService-engineScheduledThreadPool-Thread-28) [69db761e] null: java.lang.NullPointerException
2021-08-05 10:16:50,587+03 ERROR [org.ovirt.engine.core.bll.CloneVmCommand] (EE-ManagedScheduledExecutorService-engineScheduledThreadPool-Thread-36) [3f088147-db49-4d38-93e9-77646f5f52cb] Ending command 'org.ovirt.engine.core.bll.CloneVmCommand' with failure.
2021-08-05 10:16:50,590+03 ERROR [org.ovirt.engine.core.bll.storage.disk.image.CopyImageGroupCommand] (EE-ManagedScheduledExecutorService-engineScheduledThreadPool-Thread-36) [3f088147-db49-4d38-93e9-77646f5f52cb] Ending command 'org.ovirt.engine.core.bll.storage.disk.image.CopyImageGroupCommand' with failure.


Expected results:
Clone VM should work from a generated snapshot.

Additional info:
It also failed in 4.3 and in 4.4.7 so I guess this is not a regression.

Comment 1 Eyal Shenitzky 2021-08-05 08:23:49 UTC
Benny, do we support this flow (clone VM from snapshot) for MBS disk?

Comment 2 Benny Zlotnik 2021-08-05 08:32:37 UTC
(In reply to Eyal Shenitzky from comment #1)
> Benny, do we support this flow (clone VM from snapshot) for MBS disk?

I don't think it was implemented, only clone VM from template

Comment 3 Arik 2022-02-23 13:30:17 UTC
If it's similar to the problem that we are working as part of bz 1982083 then let's try to resolve it
But if it's a different problem that requires big effort, let's reconsider

Comment 4 sshmulev 2022-02-28 08:38:52 UTC
Clarifying this issue:

1) The initial test was to clone VM from a snapshot, but in the error of this bug the VM was cloned not from a snapshot (just a regular clone with MBD disk attached to the VM) - which is the same issue as in the bz 1982083

2) The correct flow for "cloning VM from a snapshot" which is an action that is not supported yet (this is why this bug changed to RFE):

Steps to Reproduce:
1. Create VM from a template(latest-rhel-guest-image-8.3-infra) and attach MBS disk to it.
2. Create a snapshot of the VM.
3. Choose the generated snapshot and press clone

Actual results:
Error message pops from UI:

"Cannot add VM. Managed Block Storage is not supported this operation."

Comment 5 shani 2022-02-28 13:53:25 UTC
1. The issue with cloning a VM (bz 1982083) was fixed by https://github.com/oVirt/ovirt-engine/pull/56.
2. Arik. what is the best approach here?

Comment 6 Arik 2022-03-10 09:05:05 UTC
(In reply to shani from comment #5)
> 1. The issue with cloning a VM (bz 1982083) was fixed by
> https://github.com/oVirt/ovirt-engine/pull/56.
> 2. Arik. what is the best approach here?

"Cannot add VM. Managed Block Storage is not supported this operation."

is the expected result here - because we are not able to clone the rbd volume

Comment 8 Sandro Bonazzola 2022-03-29 16:16:40 UTC
We are past 4.5.0 feature freeze, please re-target.

Comment 9 Arik 2022-03-30 14:09:42 UTC
Changing the expectation here as this operation should be blocked and moving back to QE

Comment 10 Shir Fishbain 2022-04-07 11:40:39 UTC
Verified

The operation is canceled and the following message appears :

Error while executing action:

s1_clone:
Cannot add VM. Managed Block Storage is not supported this operation.


ovirt-engine-4.5.0-0.237.el8ev.noarch
vdsm-4.50.0.10-1.el8ev.x86_64

Comment 11 Sandro Bonazzola 2022-04-20 06:33:59 UTC
This bugzilla is included in oVirt 4.5.0 release, published on April 20th 2022.

Since the problem described in this bug report should be resolved in oVirt 4.5.0 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.