Bug 982527 - Disk entries remain in database after deleting the datacenter
Summary: Disk entries remain in database after deleting the datacenter
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 3.2.0
Hardware: Unspecified
OS: Unspecified
medium
high
Target Milestone: ---
: 3.3.0
Assignee: Maor
QA Contact: Aharon Canan
URL:
Whiteboard: storage
Depends On:
Blocks: 892642 1019461
TreeView+ depends on / blocked
 
Reported: 2013-07-09 08:58 UTC by Kevein Liu
Modified: 2018-12-03 19:17 UTC (History)
13 users (show)

Fixed In Version: is12
Doc Type: Bug Fix
Doc Text:
Previously, certain disks and permissions would be left in the database after forced removal of a storage domain or storage pool, resulting in partial titles remaining visible in the Permissions tab of the details pane for the User tab. With this update, the forced removal procedure has been updated to include the deletion of all disks and permissions from the database.
Clone Of:
Environment:
Last Closed: 2014-01-21 17:33:26 UTC
oVirt Team: Storage
Target Upstream Version:
Embargoed:
amureini: Triaged+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2014:0038 0 normal SHIPPED_LIVE Important: Red Hat Enterprise Virtualization Manager 3.3.0 update 2014-01-21 22:03:06 UTC
oVirt gerrit 18153 0 None None None Never

Description Kevein Liu 2013-07-09 08:58:01 UTC
Description of problem:
After deleting the datacenter, all the correlate disks, VMs, templates are all gone. But the disk entries are still in table "base_disks".

Version-Release number of selected component (if applicable):
* rhevm-3.2.0-11.33.el6ev.noarch

How reproducible:
100% reproduce.

Steps to Reproduce:
1. Create a datacenter and initialize it.
2. Create several virtual machines with disks.(no need for installing a OS on them).
3. Delete the datacenter
4. In database, we'll see the disk entries of the deleted datacenter. 
  engine# SELECT * from base_disks ; 

Actual results:
See the disk entries of the deleted datacenter are in the database(table base_disks).

Expected results:
The correlate disk entries should be deleted as well.

Additional info:

Comment 2 Kevein Liu 2013-08-05 08:28:30 UTC
Hi Team,

As it's already one month since the bug was opened, is there any update here?
Customer is looking forward on our actions.
Thanks a lot!

Cheers,
Kevein

Comment 3 Maor 2013-08-14 09:55:56 UTC
This bug reproduces on NFS and ISCSI.
to reproduce the scenario we should delete to storage pool with force remove.

The appropriate fix should be to add a foreign key with cascade delete when removing the storage pool

Comment 4 Maor 2013-08-21 08:50:03 UTC
Fixing the script of force remove.
take in notice, the fix only reference the force delete operation, if there are already orphaned entries in the DB, there should be deleted manually.

Comment 5 Aharon Canan 2013-09-09 11:45:33 UTC
verified using is12

verification steps - 
1. Create a datacenter and initialize it.
2. Create several virtual machines with disks.(no need for installing a OS on them).
3. Delete the datacenter
4. In database, we'll see the disk entries of the deleted datacenter. 
  engine# SELECT * from base_disks ;

Comment 6 Charlie 2013-11-28 00:26:01 UTC
This bug is currently attached to errata RHEA-2013:15231. If this change is not to be documented in the text for this errata please either remove it from the errata, set the requires_doc_text flag to minus (-), or leave a "Doc Text" value of "--no tech note required" if you do not have permission to alter the flag.

Otherwise to aid in the development of relevant and accurate release documentation, please fill out the "Doc Text" field above with these four (4) pieces of information:

* Cause: What actions or circumstances cause this bug to present.
* Consequence: What happens when the bug presents.
* Fix: What was done to fix the bug.
* Result: What now happens when the actions or circumstances above occur. (NB: this is not the same as 'the bug doesn't present anymore')

Once filled out, please set the "Doc Type" field to the appropriate value for the type of change made and submit your edits to the bug.

For further details on the Cause, Consequence, Fix, Result format please refer to:

https://bugzilla.redhat.com/page.cgi?id=fields.html#cf_release_notes 

Thanks in advance.

Comment 7 errata-xmlrpc 2014-01-21 17:33:26 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

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

http://rhn.redhat.com/errata/RHSA-2014-0038.html


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