Uploaded image for project: 'RHEL Conversions'
  1. RHEL Conversions
  2. RHELC-1677 yum makecache fails on Alma and Rocky 9
  3. RHELC-1681

yum makecache fails on Alma and Rocky 9 - Integration tests

XMLWordPrintable

    • Icon: Sub-task Sub-task
    • Resolution: Done
    • Icon: Undefined Undefined
    • 2.2.0
    • None
    • None
    • False
    • False
    • Hide

      None

      Show
      None
    • Testable

      The parent issue RHELC-1677 has the label that triggered autocreation of this subtask to track the relative story point estimation for the integration test part of the issue.

      The parent issue description at the time of creation of this issue was:
      With system registered to the Satellite just to consume RHEL content and no other repositories (repofiles) present in the /etc/yum.repos.d/ dir the yum makecache call fails with Unknown repo: 'rhel-9-for-x86_64-baseos-rpms'

      [2024-08-02T11:48:10+0000] DEBUG - Calling command 'yum makecache --releasever=9.4 --setopt=*.skip_if_unavailable=False --setopt=module_platform_id=platform:el9 --disablerepo=* --enablerepo rhel-9-for-x86_64-baseos-rpms --enablerepo rhel-9-for-x86_64-appstream-rpms'
      ERROR - (ERROR) ENSURE_KERNEL_MODULES_COMPATIBILITY::PROBLEM_WITH_PACKAGE_REPO - Could not download package metadata
       Description: There was an error retrieving the package metadata to verify kernel modules are available in RHEL.
       Diagnosis: We were unable to download the repository metadata for (rhel-9-for-x86_64-baseos-rpms, rhel-9-for-x86_64-appstream-rpms) to determine packages containing kernel modules.  Can be caused by not enough disk space in /var/cache or too little memory.  The yum output below may have a clue for what went wrong in this case:
      
      Updating Subscription Management repositories.
      
      Error: Unknown repo: 'rhel-9-for-x86_64-baseos-rpms'
      

      Reproducer

      • register the system to the Satellite to consume only RHEL content
      • remove all repofiles
      • run convert2rhel --debug

      Minimal reproducer outside of the utility

      • register the system to the Satellite to consume only RHEL content
      • remove all repofiles
      • remove the respective <system>-release package
      • rpm -e --nodeps almalinux-release
      • run yum makecache trying to enable either of RHEL repositories
      • yum makecache --releasever=9.4 --setopt=.skip_if_unavailable=False --setopt=module_platform_id=platform:el9 --disablerepo= --enablerepo rhel-9-for-x86_64-baseos-rpms --enablerepo rhel-9-for-x86_64-appstream-rpms

      The issue is with the <system>-release package taking ownership of both /etc/yum.repos.d/ dir as whole and /etc/yum.repos.d/redhat.repo
      Removing the release package causes the whole dir to be erased, which prohibits subscription-manager to refresh the redhat.repo file.
      Therefore no repository definition can be found to be enabled.

      LOGS https://artifacts.osci.redhat.com/testing-farm/efd3b665-555e-4d90-a6ad-c0fa0715b9fb/work-non-destructiveao5xkn1r/plans/tier0/core/non-destructive/execute/data/guest/default-0/tests/integration/tier0/non-destructive/system-release-backup/os_release_restored/override_inhibitor_os_release_restored-32/output.txt

              ddiblik@redhat.com Daniel Diblik
              rhel-process-autobot RHEL Jira bot
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: