What is the difference between Repo-pkgs and Repo-available-pkgs?

Solution Verified - Updated

Environment

Red Hat Enterprise Linux 8
Satellite 6

Issue

Different number of packages "Repo-available-pkgs" versus "Repo-pkgs"

Repo-id            : rhel-8-for-x86_64-appstream-rpms
Repo-name          : Red Hat Enterprise Linux 8 for x86_64 - AppStream (RPMs)
Repo-revision      : 1603477474
Repo-updated       : Fri 23 Oct 2020 06:25:50 PM UTC
Repo-pkgs          : 12,214
Repo-available-pkgs: 10,407
Repo-size          : 27 G
Repo-baseurl       : https://ktordeur-sat67.sysmgmt.lan/pulp/repos/Default_Organization/Library/content/dist/rhel8/8/x86_64/appstream/os
Repo-expire        : 1 second(s) (last: Mon 26 Oct 2020 11:27:15 AM UTC)
Repo-filename      : /etc/yum.repos.d/redhat.repo

The repository is synced and no issues are encountered on either external Capsules or on Satellite nor is there any problem in the Content View. What causes some packages to not be available for installation on the Content Host?

Resolution

Lets take python38 as an example module.

Module filtering applies to all repositories. Since the appstream repository provides python38 in a module, and that module is default:

Red Hat Enterprise Linux 8 for x86_64 - AppStream (RPMs)
Name                                 Stream                              Profiles                                     Summary
python38                             3.8 [d]                             build, common [d]                            Python programming language, version 3.8

Any packages that are not in this module stream, and have the same name, will be filtered out. From any repository.

The only way to access 3rd party packages that have the same name as a package provided by Red Hat, in a module, is to disable our module.

# yum module disable python38

This will allow you to see and install packages with the same name that are NOT in the python38 module.

You can find a more detailed step by step guide in https://access.redhat.com/solutions/5390051

For more KB articles/solutions related to Red Hat Satellite 6.x Client Subscription Issues, please refer to the Red Hat Satellite Consolidated Troubleshooting Article for Red Hat Satellite 6.x Client Subscription Issues

Root Cause

Red Hat Enterprise Linux 8 introduces modules into repositories which causes some packages to be filtered out automatically because the module is enabled so the Repo-available-pkgs is how many packages can be installed while Repo-pkgs is how many packages are in the repository and some of them are filtered out.

Package filtering
Without modules, packages with the highest version are used by default.

Module streams can distribute packages with lower versions than available in the repositories available to the operating system. To make such packages available for installs and upgrades, the non-modular packages are filtered out when they match by name with modular packages from any existing stream.

Diagnostic Steps

We can see that there is a different number of packages "Repo-available-pkgs" versus "Repo-pkgs"

# dnf repolist -vvv

Repo-id            : rhel-8-for-x86_64-appstream-rpms
Repo-name          : Red Hat Enterprise Linux 8 for x86_64 - AppStream (RPMs)
Repo-revision      : 1603477474
Repo-updated       : Fri 23 Oct 2020 06:25:50 PM UTC
Repo-pkgs          : 12,214
Repo-available-pkgs: 10,407
Repo-size          : 27 G
Repo-baseurl       : https://ktordeur-sat67.sysmgmt.lan/pulp/repos/Default_Organization/Library/content/dist/rhel8/8/x86_64/appstream/os
Repo-expire        : 1 second(s) (last: Mon 26 Oct 2020 11:27:15 AM UTC)
Repo-filename      : /etc/yum.repos.d/redhat.repo

Repo-id            : rhel-8-for-x86_64-baseos-rpms
Repo-name          : Red Hat Enterprise Linux 8 for x86_64 - BaseOS (RPMs)
Repo-revision      : 1603218346
Repo-updated       : Tue 20 Oct 2020 06:27:47 PM UTC
Repo-pkgs          : 5,079
Repo-available-pkgs: 5,076
Repo-size          : 6.9 G
Repo-baseurl       : https://ktordeur-sat67.sysmgmt.lan/pulp/repos/Default_Organization/Library/content/dist/rhel8/8/x86_64/baseos/os
Repo-expire        : 1 second(s) (last: Mon 26 Oct 2020 11:27:15 AM UTC)
Repo-filename      : /etc/yum.repos.d/redhat.repo
SBR
Product(s)
Components
Category

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.