Bug 901531 - Deleting one gluster volume from gluster cli triggers deletion of all volumes in engine
Deleting one gluster volume from gluster cli triggers deletion of all volumes...
Product: oVirt
Classification: Community
Component: ovirt-engine-core (Show other bugs)
Unspecified Unspecified
urgent Severity urgent
: ---
: 3.2
Assigned To: Shubhendu Tripathi
Depends On:
Blocks: ovirt-3.2-release 901465 903084
  Show dependency treegraph
Reported: 2013-01-18 07:09 EST by Shireesh
Modified: 2013-07-25 16:47 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 903084 (view as bug list)
Last Closed: 2013-07-25 16:47:55 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
oVirt gerrit 11799 None None None Never

  None (edit)
Description Shireesh 2013-01-18 07:09:22 EST
Root cause:

Patch http://gerrit.ovirt.org/9825 changed the definition of the SP fnSplitterUuid in such a way that the older call to this SP, that looked like:

select ID from fnSplitterUuid(v_ids)

no longer works, and now needs to be changed to something like:

select * from fnSplitterUuid(v_ids)

While this change was done in most of the *_sp.sql scripts, it was missed out in gluster_volumes_sp.sql

This results in particular severe consequences if you are trying to delete few entries, like it's done in DeleteGlusterVolumesByGuids:

DELETE FROM gluster_volumes 
WHERE id in (select ID from fnSplitterUuid(v_volume_ids));

One may think that this query should fail, but it actually results in deleting all the records from the table!!


Modify all calls to fnSplitterUuid present in gluster_volumes_sp.sql to use "*" instead of "ID"

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