Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1584874 - When upgrading from 6.2 to 6.3 content_source_id value is not migrated
Summary: When upgrading from 6.2 to 6.3 content_source_id value is not migrated
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Upgrades
Version: 6.3.1
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: Unspecified
Assignee: Stephen Benjamin
QA Contact: Harshad More
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-05-31 20:34 UTC by Paul Dudley
Modified: 2021-09-09 14:21 UTC (History)
6 users (show)

Fixed In Version: tfm-rubygem-katello-3.4.5.73-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-06-19 20:17:05 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 23781 0 None None None 2018-06-01 15:51:17 UTC
Red Hat Product Errata RHBA-2018:1950 0 None None None 2018-06-19 20:17:12 UTC

Description Paul Dudley 2018-05-31 20:34:54 UTC
Description of problem:
When upgrading from 6.2 to 6.3 the content_source_id parameter from hosts is moved from the hosts table to the katello_content_facets table. As seen in the satellite.log form an upgrade here:

---
 -- add_column(:katello_content_facets, :content_source_id, :integer)
 -- add_index(:katello_content_facets, :content_source_id)
 -- add_foreign_key(:katello_content_facets, :smart_proxies, {:name=>"katello_content_facets_content_source_id_fk", :column=>"content_source_id"})
 -- remove_foreign_key(:hosts, {:name=>"hosts_content_source_id_fk"})
 -- remove_index(:hosts, :content_source_id)
 -- remove_column(:hosts, :content_source_id)
---

The problem here is that it doesn't appear that the value set for the content_source_id parameter in the hosts table is migrated to the katello_content_facets table when the new column is created. All values in the new column are blank.

For example:
===
6.2.14 (before upgrade)
foreman=# select count(id) from hosts where content_source_id is null;
 count 
-------
    24
(1 row)

foreman=# select count(id) from hosts where content_source_id is not null;
 count 
-------
   105
(1 row)
===
6.3.1 (after upgrade)
foreman=# select count(id) from katello_content_facets where content_source_id is null;
 count 
-------
   117
(1 row)

foreman=# select count(id) from katello_content_facets where content_source_id is not null;
 count 
-------
     0
(1 row)
===

Actual results:
Table values are not migrated

Expected results:
Table values are migrated and kept

Comment 3 Stephen Benjamin 2018-06-01 15:51:14 UTC
Created redmine issue http://projects.theforeman.org/issues/23781 from this bug

Comment 7 Satellite Program 2018-06-01 18:06:18 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/23781 has been resolved.

Comment 11 errata-xmlrpc 2018-06-19 20:17:05 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://access.redhat.com/errata/RHBA-2018:1950


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