Eli Mesika has submitted this change and it was merged. Change subject: upgrade from 3.0.7 to SI24.4 fail(#879918) ......................................................................
upgrade from 3.0.7 to SI24.4 fail(#879918) upgrade from 3.0.7 to SI24.4 fails: ERROR: insert or update on table vm_device violates foreign key constraint fk_vm_device_vm _static This bug is a result of missing FK between vmt_guid in vm_interface and vm_guid in vm_static. This cause junk interface left in vm_interface when a template that has interfaces is removed. Since in upgrade from 3.0 to 3.1 we added the vm_device table, there is an attempt to insert those junk interfaces to vm_device that fails on the FK constraint between vm_device and vm_static. This patch fix the bug by: 1) Fixing the upgrade script to cleanup those junk interfaces before an attempt to insert it to vm_device is done. 2) Adds the missing FK between vm_interface and vm_static to prevent junk data in future. Change-Id: Iaf4af7908566b5d16e39ea5167c6d6dffc5884db Signed-off-by: Eli Mesika <emes...@redhat.com> --- M backend/manager/dbscripts/upgrade/03_01_0440_vm_device_upgrade_data.sql A backend/manager/dbscripts/upgrade/03_01_1520_add_fk_vm_interface_vm_static_template.sql 2 files changed, 9 insertions(+), 0 deletions(-) Approvals: Eli Mesika: Verified; Looks good to me, approved -- To view, visit http://gerrit.ovirt.org/9462 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: Iaf4af7908566b5d16e39ea5167c6d6dffc5884db Gerrit-PatchSet: 3 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Eli Mesika <emes...@redhat.com> Gerrit-Reviewer: Allon Mureinik <amure...@redhat.com> Gerrit-Reviewer: Eli Mesika <emes...@redhat.com> Gerrit-Reviewer: Yair Zaslavsky <yzasl...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches