Bug 1378322

Summary: The base RHEL repo can be included in an entitlement certificate even though it was never added
Product: Red Hat Update Infrastructure for Cloud Providers Reporter: Radek Bíba <rbiba>
Component: ToolsAssignee: bizhang
Status: CLOSED ERRATA QA Contact: Radek Bíba <rbiba>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0.0CC: bizhang, pcreech
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-03-01 22:13:21 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:

Description Radek Bíba 2016-09-22 06:56:58 UTC
Description of problem:
I've only added the following repositories in my RHUA environment:

====
Red Hat Repositories
  Red Hat Enterprise Linux High Availability (for RHEL 6 Server) (RPMs) from RHUI (6Server-x86_64)
  Red Hat Enterprise Linux High Availability (for RHEL 7 Server) (RPMs) from RHUI (7Server-x86_64)
====

Still, when I try to generate an entitlement certificate, I'm also offered the base RHEL repos for both major versions:

====
rhui (client) => e

Select one or more repositories to include in the entitlement certificate:

  Custom Repositories

  Red Hat Repositories
    -  1 : Red Hat Enterprise Linux 6 Server from RHUI (RPMs)
    -  2 : Red Hat Enterprise Linux 7 Server from RHUI (RPMs)
    -  3 : Red Hat Enterprise Linux High Availability (for RHEL 6 Server) (RPMs) from RHUI
    -  4 : Red Hat Enterprise Linux High Availability (for RHEL 7 Server) (RPMs) from RHUI

Enter value (1-4) to toggle selection, 'c' to confirm selections, or '?' for more commands:
====

Why? The base repositories aren't available on the CDSes, and if I do generate the certificate, create a client configuration RPM, and install the RPM on a client machine, I run into issues:

====
# yum repolist enabled
Loaded plugins: search-disabled-repos
https://cds.example.com/pulp/repos/content/dist/rhel/rhui/server/7/7Server/x86_64/os/repodata/repomd.xml: [Errno 14] HTTPS Error 404 - Not Found
Trying other mirror.
To address this issue please refer to the below knowledge base article 

https://access.redhat.com/articles/1320623

If above article doesn't help to resolve this issue please open a ticket with Red Hat Support.

https://cds.example.com/pulp/repos/content/dist/rhel/rhui/server/7/7Server/x86_64/os/repodata/repomd.xml: [Errno 14] HTTPS Error 404 - Not Found
Trying other mirror.
repo id                                                 repo name         status
rhui-rhel-7-server-rhui-rpms/7Server/x86_64             Red Hat Enterpris   0
rhui-rhel-ha-for-rhel-7-server-rhui-rpms/7Server/x86_64 Red Hat Enterpris 225
repolist: 225
====

Version-Release number of selected component (if applicable):
RHUI-3.0-RHEL-{6,7}-20160830.n.0

How reproducible:
Always.

Steps to Reproduce:
1. Add an add-on repository, such as "Red Hat Enterprise Linux High Availability (for RHEL 7 Server) (RPMs) from RHUI". Sync it.
2. Launch the "generate an entitlement certificate" wizard. Note that you're offered the base repository in addition to the repository you've intentionally added.
3. Generate a configuration RPM with the certificate, selecting both the base and the add-on repository.
4. Install the RPM on a client machine.
5. Make sure cds.example.com on the client machine resolves as your HA Proxy instance.
6. Run "yum repolist enabled" on the client machine.

Actual results:
Error. The repodata for the base repository can't be found.

Expected results:
The base repository can't be added to the certificate in the first place. Unless this is a hidden feature, in which case the base repo must be synced, too.

Comment 2 Radek Bíba 2016-12-07 14:10:29 UTC
Verified in 20161206. Only the imported add-on repo is offerd when selecting which repos to include in an entitlement cert.

Comment 3 errata-xmlrpc 2017-03-01 22:13:21 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-2017:0367