Solution#1:
The error can be observed, when the Red Hat entitlement certificate is either invalid or revoked.
Thus try re-download the Red Hat entitlement certificates as suggested in the Creating a patch catalog for Red Hat Enterprise Linux - downloading certificates from the Red Hat Customer Portal, update the Patch Global Configuration to point to the new certificates and rerun the Catalog Update Job
When re-configuring in Patch Global Configuration, make sure to hit red X mark to delete the existing and re-specify the new cert location.
If the issue persists after above, another probable cause might be corrupt RPM.
Therefore identify and remove those bad RPM based on the "No more mirror to try" error in the log as below:
1) Go to the repository location on the repository server
2) Run 'cat yum_metadata_generator.log' and see the error in it, if the error is seen as "[Errno 256] No more mirrors to try" , then proceed with the next steps
E.g. kernel-3.10.0-123.4.2.el7.x86_64: [Errno 256] No more mirrors to try.
3) find the corrupt rpms on the repo server -
find ./ -name *rpm_name*
E.g. find ./ -name *kernel-3.10.0-123.4.2.el7.x86_64*
4) Remove the corrupt rpms-
find ./ -name *rpm_name* -exec rm {} \;
5) Get the channel name and architecture of the channel from the repo file for the impacted filter: cat yum_redhat_catalog.repo
6) Run the below reposync command to check if the rpms are downloading for all the channels listed in the above repo file
reposync -c ./yum.conf -r <channelname> -a <arch>
E.g. - reposync -c ./yum.conf -r rhel-7-server-rpms -a x86_64
NOTE: If the reposync command fails to download the RPMs, check with the network team for any intermittent network issues
Also if 'reposync' command fails for any specific patch, then you can try execute command "yum update --downloadonly" on the same repository server , which will only download the patches (without applying them) by default on '/var/cache/yum/'.
After downloading all patches, you can confirm the size and MD5sum of the downloaded patches from the location '/var/cache/yum/' against the errroed RPMs
7) Rerun the Catalog Update Job
Solution#2a and b:
Possible issue with channel subscription. Perform the following steps:
1) Login to repository server
2) cd to the repository location
3) Run the command to manually sync the certificates, where <channel_label_in_the_error> is the repository name from the yum_redhat_catalog.repo file in the same directory and <architecture> is the architecture of the channel which is being downloaded - eg x86_64.
reposync -c ./yum.conf -r <channel_label_in_the_error> -a <architecture>
For example, if the error was "Error occurred in reposync for repo rhel-x86_64-server-sap-hana-6", you would run the following:
reposync -c ./yum.conf -r rhel-x86_64-server-sap-hana-6 -a x86_64
4) The resposync command will likely fail with something like below:
Config time: 0.023
repo time: 2.399
Setting up Package Sacks
rhel-x86_64-server-sap-hana-6/primary_db FAILED
Error setting up repositories: failure: repodata/b22cde5d5542207f97f65c81cab34762d9596544-primary.sqlite.bz2 from rhel-x86_64-server-sap-hana-6: [Errno 256] No more mirrors to try. 0 B --:--:-- ETA
https://cdn.redhat.com/content/dist/rhel/server/6/6Server/x86_64/sap-hana/os/repodata/b22cde5d5542207f97f65c81cab34762d9596544-primary.sqlite.bz2: [Errno 14] HTTPS Error 403 - Forbidden
5) Raise a case with RedHat mentioning the error in reposync
Solution#3:
Most likely DNS issue (could not resolve proxy server hostname)
The 'Couldn't resolve proxy' error indicates that the RedHat repo server could not resolve the proxy name to an IP address.
Thus ensure that the repository server can resolve the proxy hostname.
If you require further assistance, raise a case with BMC Support with the following details:
- Catalog Update Job run logs
- Application Server logs covering the time of the error
- 'yum_metadata_generator.log' from the repository path
Solution#4:
Most likely issue with the proxy/firewall blocking the access to the Redhat server to download the rpms.
Thus make sure to allow the required hostnames and ports on the outgoing network firewall/proxy to enable yum and subscription- manager access to the Red Hat Content Delivery Server
Also refer to the RedHat article: "https://access.redhat.com/solutions/3160471"
Solution#5:
Probably Issue with the registration or the login credential.
Check the credential of registering the RHEL-X repository server and try unregister and re-register the server with correct user-id and password.
Solution#6:
There may be invalid channel data in the configured RHEL channel filter list file.
Thus validate for invalid RedHat Channel Filters List file configured in 'Basic Options' sub-tab under 'Red Hat' tab in PGC (Patch Global Configuration) menu from 'Configuration' menu in RCP console