Bug 949229 - [engine-backend] delete_async_tasks_and_compensation_data.sql exits on KeyError
Summary: [engine-backend] delete_async_tasks_and_compensation_data.sql exits on KeyError
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 3.2.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 3.2.0
Assignee: Eli Mesika
QA Contact: Leonid Natapov
URL:
Whiteboard: infra
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-04-07 06:42 UTC by Elad
Modified: 2016-02-10 19:05 UTC (History)
10 users (show)

Fixed In Version: sf13.1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
oVirt Team: Infra
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 13739 0 None None None Never

Description Elad 2013-04-07 06:42:24 UTC
Description of problem:
delete_async_tasks_and_compensation_data.sql exits on KeyError:

[root@elad-rhevm32 dbscripts]# psql -U postgres engine -f delete_async_tasks_and_compensation_data.sql 
Password for user postgres: 
psql:delete_async_tasks_and_compensation_data.sql:1: ERROR:  cannot truncate a table referenced in a foreign key constraint
DETAIL:  Table "async_tasks_entities" references "async_tasks".
HINT:  Truncate table "async_tasks_entities" at the same time, or use TRUNCATE ... CASCADE.
  

Version-Release number of selected component (if applicable):

rhevm-dbscripts-3.2.0-10.18.beta2.el6ev.noarch
rhevm-backend-3.2.0-10.18.beta2.el6ev.noarch


How reproducible:
100%

Steps to Reproduce:
1.On engine: Run:
 psql -U postgres engine -f delete_async_tasks_and_compensation_data.sql 

  
Actual results:
delete_async_tasks_and_compensation_data.sql exits on KeyError

Expected results:
delete_async_tasks_and_compensation_data.sql should succeed

Comment 1 Barak 2013-04-07 13:16:01 UTC
Why did you execute this script in the first place ?

What was the problem scenario you were trying to solve ?

Comment 2 Eli Mesika 2013-04-07 20:04:43 UTC
(In reply to comment #1)
> Why did you execute this script in the first place ?
> 
> What was the problem scenario you were trying to solve ?

Double checked that.
This script is called via the pre-upgrade step
Bug is valid , I will handle that ASAP

Comment 3 Eli Mesika 2013-04-09 13:53:08 UTC
fixed in commit: 568d77e

Comment 5 Leonid Natapov 2013-04-14 12:39:31 UTC
sf 13.1

Comment 6 Itamar Heim 2013-06-11 08:31:56 UTC
3.2 has been released

Comment 7 Itamar Heim 2013-06-11 08:32:03 UTC
3.2 has been released

Comment 8 Itamar Heim 2013-06-11 08:33:15 UTC
3.2 has been released


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