Problem description
The following error was encountered when executing yum update after booting an EC2 instance from MarketPlace with RHEL 7.6’s AMI:
[ec2-user@ip-172-31-43-28 ~]$ sudo yum update
Loaded plugins: amazon-id, rhui-lb, search-disabled-repos
Could not contact any CDS load balancers: https://rhui3.cn-northwest-1.aws.ce.redhat.com/pulp/content/.
Cause of the problem
According to the official RHEL lifecycle statement: Red Hat Enterprise Linux Life Cycle RHEL 7.6 Extended Update Support Add-on all ended on May 31, 2021, while the RedHat official website states: RHUI 3 Takes Over in AWS, Bringing New DNS Data
Since RHEL 7.6 still uses the rh-amazon-rhui-client
with version 2 by default, checking the repo configuration files starting with /etc/yum.repo.d/redhat-rhui
, you can see that they all start with the address: https://rhui2-cds01.REGION.aws.ce.redhat.com.
After upgrading to RHUI 3 in July 2020, the hostname and IP address were changed, which means that the original repo cannot be used anymore.
With the transition to RHUI 3, new host names and IP addresses are used. If you have firewall rules, proxy settings etc. that worked with the original RHUI 2 host names or their original IP addresses, you are likely affected, and will need to change these rules or settings to allow the new host names or IP addresses.
Solution:
-
-
- Start a new instance using the last major release of RHEL 7, I’m using RHEL-7.9_HVM-20211005-x86_64-0-Hourly2-GP2 – ami-0196d703168979cc6
-
-
-
- SSH to this instance, use the following command to download the latest version of the rh-amazon-rhui-client.noarch package
-
sudo yum install --downloadonly --downloaddir=/home/ec2-user/ rh-amazon-rhui-client.noarch
Disconnect the SSH connection, use the SCP command on the local computer to download the installation package locally, and then transfer it to the problematic 7.6 instance
scp -i .\xxx.pem ec2-user@[RHEL 7.9的IP]:/home/ec2-user/rh-amazon-rhui-client-3.0.45-1.el7.noarch.rpm ./Desktop/
scp -i .\xxx.pem .\Desktop\rh-amazon-rhui-client-3.0.45-1.el7.noarch.rpm ec2-user@[RHEL 7.6的IP]:/home/ec2-user/
Connect SSH to the 7.6 instance and execute the following command to update RH Amazon rhui client
# Uninstall the old client and beta versions that came with 7.6
sudo yum remove -y rh-amazon-rhui-client rh-amazon-rhui-client-beta
# Manually install the downloaded new version of the rpm package
sudo rpm -ivh --nodeps ~/rh-amazon-rhui-client-3.0.45-1.el7.noarch.rpm
# Resolve the package dependencies by reinstalling them again via yum
sudo yum reinstall -y rh-amazon-rhui-client
# Refresh the cache and repo information
sudo yum clean all
sudo yum repolist
sudo yum list
Read More:
- [ubuntu14.04]Tensorflow: Could not find any downloads that satisfy the requirement
- [Errno 14] curl#6 – “Could not resolve host: yum.dockerproject.org; Unknown error“
- error: src refspec master does not match any. [How to Solve]
- [Solved] Error: SRC refspec master doors not match any
- [Solved] Could not resolve host: yum.dockerproject.org; Unknown error
- error: src refspec master does not match any [How to Solve]
- error: src refspec master does not match any [How to Solve]
- Gulp compression error: Error [ERR_REQUIRE_ESM]: Must use import to load ES Module…
- [Solved] Eureka related services Start Error: cannot execute request on any known server
- [Solved] Git Common Error: error: src refspec xxx does not match any/error: failed to push some refs to
- [Solved] CentOS 6 yum update Error: Cannot find a valid baseurl for repo: base
- error: could not install *smartsocket* listener: Address already in use PM8:49 ADB server didn’t AC…
- [Solved] Multiple Yum update error: Failed to set locale, defaulting to C
- Postgis Install Error: could not load library “C:\……“:The specified module could not be found.
- Go declares that the local variable does not use command line arguments. Main. Go: 4:6: a declared but not used
- [Solved] cannot find package “go.opentelemetry.io/otel/api/trace“ in any of
- [Solved] harbor Error: because it doesn‘t contain any IP SANs
- [Solved] MindSpore Error: Should not use Python in runtime
- Taro Use React Hooks Error: TypeError: Object(…) is not a function