Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1511598 - Bound repositories can become mismatched between katello and pulp and will never correct itself
Summary: Bound repositories can become mismatched between katello and pulp and will ne...
Status: NEW
Alias: None
Product: Red Hat Satellite 6
Classification: Red Hat
Component: Content Management
Version: 6.2.12
Hardware: Unspecified
OS: Unspecified
medium vote
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact: Lai
Depends On:
TreeView+ depends on / blocked
Reported: 2017-11-09 16:39 UTC by Justin Sherrill
Modified: 2019-04-04 03:28 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed:
Target Upstream Version:

Attachments (Terms of Use)

Description Justin Sherrill 2017-11-09 16:39:35 UTC
Description of problem:

A customer recently reported a case where errata were not showing up.  While running some debug commands we noticed this:

Host.find_by(:name => "HOSTNAME").content_facet.bound_repositories.pluck(:name)
=> ["Red Hat Satellite Tools 6.2 for RHEL 6 Server RPMs x86_64", "Red Hat Enterprise Linux 6 Server - Supplementary RPMs x86_64 6Server", "Red Hat Enterprise Linux 6 Server - Optional RPMs x86_64 6Server", "Red Hat Enterprise Linux 6 Server RPMs x86_64 6Server"] => "HOSTNAME").content_facet.uuid).bound_yum_repositories.count 

=> 0

Something must have happened between when we saved the bound repos in katello and when they are saved in pulp (such as a pulp error was thrown).  

In addition, if a client gets in this state and katello-upload-package --force is run, the server will never actually update pulp because its 'optimized' to not generate applicability too often.

How reproducible:
not easily

Some ideas:

Get rid of the 'optimization' and always update pulp and generate applicability for 6.3, since the client is now caching it locally

Add a transaction to the db update, so that if pulp throws an error on save, the katello db save is rolled back and an exception is thrown.

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