[Satellite6] How to regenerate applicability of a repository?

Solution Verified - Updated

Environment

Red Hat Satellite 6.1 - 6.9

Issue

  • Actions::Pulp::Repository::RegenerateApplicability dynflow task failed due to whatever reason during a repository sync
  • repository itself has been synchronized properly, though
  • as a consequence, WebUI does not list all applicable errata/packages for the repository
  • how to regenerate applicability of the repository?

Resolution

The easiest way is to synchronize the repository once more. If contents changed (i.e. new package/errata fetched), the RegenerateApplicability task will be triggered automatically and it will calculate all packages and erratas received during whatever synchronization.

If no new content is fetched during a synchronization attempt, the RegenerateApplicability task won't be triggered due to optimization reasons. In case one can't wait until new content is available, there is a procedure how to forcefully trigger the task.

To forcefully trigger RegenerateApplicability task:

  1. In satellite 6.2.9 or newer, you can use hammer:
#  hammer repository synchronize --organization ORG_NAME --product PRODUCT_NAME --name REPOSITORY_NAME --skip-metadata-check=true
  1. In Satellite 6.1 or Satellite 6.2.8 and older

a) Navigate to Administer > Settings > Katello
b) Locate the setting "force_post_sync_actions". Set this setting to true.
c) Re-sync the repository as you normally would, and monitor the task to completion.
d) To prevent repository syncs from taking too long in the future, reset that setting back to 'false.

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

SBR
Product(s)
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.