Satellite installer command failed with error Could not prefetch package provider 'dnfmodule'.

Solution Verified - Updated

Environment

  • Red Hat Satellite 6

Issue

  • While running the Red Hat Satellite installer command, it failed with the below error:

    [ERROR ] [configure] Could not prefetch package provider 'dnfmodule': Execution of '/usr/bin/dnf module list -d 0 -e 1' returned 1: Error: Failed to download metadata for repo 'rhel-8-for-x86_64-baseos-rpms': Cannot download repomd.xml: Curl error (77): Problem with the SSL CA cert (path? access rights?) for https://cdn.redhat.com/content/dist/rhel8/8/x86_64/baseos/os/repodata/repomd.xml [error setting certificate verify locations:
    [ERROR ] [configure] CAfile: %(ca_cert_dir)sredhat-uep.pem
    [ERROR ] [configure] CApath: none]
    

Resolution

  • Rename rhsm.con file name to rhsm.conf on the Red Hat Satellite server:

    # mv /etc/rhsm/rhsm.con /etc/rhsm/rhsm.conf
    
  • Rerun the satellite installer command:

    # satellite-installer -S satellite
    

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

Root Cause

  • The rhsm.conf file has been renamed to rhsm.con. As a result, the subscription-manager command is unable to access the configuration file, preventing it from retrieving the necessary details.

Diagnostic Steps

  • Check for the file rhsm.conf on the server:

    # ls -l /etc/rhsm/rhsm.*
    /etc/rhsm/rhsm.con                                         <<<========== Incorrect name
    /etc/rhsm/rhsm.conf.bak
    /etc/rhsm/rhsm.conf.rpmnew
    /etc/rhsm/rhsm.conf.rpmsave
    
  • Check and ensure that the certificate options are as follows in the rhsm.conf file:

    # cat /etc/rhsm/rhsm.conf | grep -iE "ca_cert_dir|repo_ca_cert"
    ca_cert_dir = /etc/rhsm/ca/
    repo_ca_cert = %(ca_cert_dir)sredhat-uep.pem	
    
  • Following logs are observed in the satellite.log file:

        [NOTICE] [configure] Starting system configuration.
        [ERROR ] [configure] Could not prefetch package provider 'dnfmodule': Execution of '/usr/bin/dnf module list -d 0 -e 1' returned 1: Error: Failed to download metadata for repo 'rhel-8-for-x86_64-baseos-rpms': Cannot download repomd.xml: Curl error (77): Problem with the SSL CA cert (path? access rights?) for https://cdn.redhat.com/content/dist/rhel8/8/x86_64/baseos/os/repodata/repomd.xml [error setting certificate verify locations:
        [ERROR ] [configure] CAfile: %(ca_cert_dir)sredhat-uep.pem
        [ERROR ] [configure] CApath: none]
        [NOTICE] [configure] 250 configuration steps out of 1594 steps complete.
        [NOTICE] [configure] 500 configuration steps out of 1595 steps complete.
        [NOTICE] [configure] 750 configuration steps out of 1598 steps complete.
        [NOTICE] [configure] 1000 configuration steps out of 1605 steps complete.
        [NOTICE] [configure] 1250 configuration steps out of 1605 steps complete.
        [NOTICE] [configure] 1500 configuration steps out of 1605 steps complete.
        [NOTICE] [configure] System configuration has finished.
    
        Error 1: Puppet Package resource 'redis dnf module' failed. Logs:
          /Package[redis dnf module]
            Starting to evaluate the resource (129 of 1594)
            Skipping because provider prefetch failed
            Resource is being skipped, unscheduling all events
            Evaluated in 0.00 seconds
        Error 2: Puppet Package resource 'postgresql dnf module' failed. Logs:
          /Stage[main]/Postgresql::Dnfmodule/Package[postgresql dnf module]/before
            before to Package[postgresql-client]
            before to Package[postgresql-server]
            before to Package[postgresql-contrib]
          /Package[postgresql dnf module]
            Starting to evaluate the resource (175 of 1594)
            Skipping because provider prefetch failed
            Resource is being skipped, unscheduling all events
            Evaluated in 0.00 seconds
        Error 3: Puppet Package resource 'pki-core' failed. Logs:
          /Stage[main]/Candlepin::Install/Package[pki-core]/before
            before to Package[candlepin]
            before to Package[candlepin-selinux]
          /Package[pki-core]
            Starting to evaluate the resource (210 of 1594)
            Skipping because provider prefetch failed
            Resource is being skipped, unscheduling all events
            Evaluated in 0.00 seconds
    
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.