Bug 1342783 - Remove snapshot with its disk attached to other VM should be blocked
Summary: Remove snapshot with its disk attached to other VM should be blocked
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: BLL.Storage
Version: 4.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ovirt-4.0.1
: 4.0.1.1
Assignee: Liron Aravot
QA Contact: Raz Tamir
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-06-05 08:54 UTC by Raz Tamir
Modified: 2016-07-19 06:25 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-07-19 06:25:18 UTC
oVirt Team: Storage
Embargoed:
rule-engine: ovirt-4.0.z+
ylavi: blocker-
rule-engine: planning_ack+
amureini: devel_ack+
acanan: testing_ack+


Attachments (Terms of Use)
engine and vdsm logs (2.40 MB, application/x-gzip)
2016-06-05 08:54 UTC, Raz Tamir
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 59305 0 master MERGED core: RemovesSnapshot - Disk snapshots attached to other vms validation 2016-06-19 09:15:39 UTC
oVirt gerrit 59428 0 ovirt-engine-4.0 MERGED core: RemovesSnapshot - Disk snapshots attached to other vms validation 2016-06-20 07:20:05 UTC

Description Raz Tamir 2016-06-05 08:54:07 UTC
Created attachment 1164863 [details]
engine and vdsm logs

Description of problem:
As part of our impl of backup/restore api feature, we are attaching a snapshot's disk from vm 1 to vm 2.
The removal of the snapshot should be blocked (in 3.X) when the the snapshot's disk is attached to 2nd vm.


Version-Release number of selected component (if applicable):
ovirt-engine-4.0.0-0.7.master.el7ev.noarch
vdsm-4.18.0-0.el7ev.x86_64

How reproducible:
100%

Steps to Reproduce:
Setup:
- 2 vm with 1 disk per vm (with OS)
- 1st vm with snapshot containing the boot disk
1. Attach the snapshot's disk of 1st vm to 2nd vm:
send POST request to /api/vms/<backup_vm_id>/disks :
<disk id='<source_vm_snapshot's_disk_id>'>
  <snapshot id='<source_vm_snapshot_id>'>
</disk>
2. Try to remove the snapshot
3.

Actual results:
The snapshot will remove successfully

Expected results:
The operation should be blocked with CDA

Additional info:

Comment 1 Red Hat Bugzilla Rules Engine 2016-06-05 09:33:37 UTC
This bug report has Keywords: Regression or TestBlocker.
Since no regressions or test blockers are allowed between releases, it is also being identified as a blocker for this release. Please resolve ASAP.

Comment 2 Raz Tamir 2016-07-03 21:12:08 UTC
Verified on rhevm-4.0.2-0.2.rc1.el7ev.noarch

Comment 3 Sandro Bonazzola 2016-07-19 06:25:18 UTC
Since the problem described in this bug report should be
resolved in oVirt 4.0.1 released on July 19th 2016, it has been closed with a
resolution of CURRENT RELEASE.

For information on the release, and how to update to this release, follow the link below.

If the solution does not work for you, open a new bug report.

http://www.ovirt.org/release/4.0.1/


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