Bug 1308521

Summary: Purge taskomatic records during upgrade
Product: Red Hat Satellite 5 Reporter: Tomáš Kašpárek <tkasparek>
Component: UpgradesAssignee: Tomáš Kašpárek <tkasparek>
Status: CLOSED ERRATA QA Contact: Ales Dujicek <adujicek>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 570CC: adujicek, dyordano, pstudeni, tlestach
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: rhn-upgrade-5.7.0.32-1-sat Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-04-28 11:16:02 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Tomáš Kašpárek 2016-02-15 12:57:58 UTC
Description of problem:
In BZ#1305157 we've added additional functionality to Sat 5.6 added in BZ#1215671 to 5.7. However as these are added later in 5.7 lifecycle and not in plain 5.7 there are few problems during 5.6 -> 5.7 upgrade.
1. There are additional taskomatic related records in the DB but no Java classes -> taskomatic will be failing on plain 5.7 with ClassNotFound exceptions.
2. Applying erratum which fixed BZ#1215671 can cause troubles as there are no INSERT WHERE NOT EXISTS statements in https://github.com/spacewalkproject/spacewalk/blob/master/schema/spacewalk/upgrade/spacewalk-schema-2.3-to-spacewalk-schema-2.4/002-auto-errata-update-task.sql

Version-Release number of selected component (if applicable):
5.6 -> 5.7 upgrade

How reproducible:
always

Steps to Reproduce:
1. Apply fix for BZ#1305157 on 5.6
2. Upgrade to 5.7

Actual results:
Upgraded DB from 5.6 to 5.7 contains taskomatic records related to (at plain 5.7) non-existing Java classes. During upgrade process either duplicate records are created or schema-upgrade process fails with unique constraint violation (haven't tested this one).

Expected results:
There should be no evidence of taskomatic classes added by BZ#1305157 on upgraded 5.7 instance.

Comment 9 errata-xmlrpc 2016-04-28 11:16:02 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.

https://rhn.redhat.com/errata/RHBA-2016-0698.html