CentOS 6 reached end-of-life (EOL) on November 30, 2020, and is no longer maintained by the Linux community. Therefore, the CentOS 6 source is unavailable in http://mirror.centos.org/centos-6/
and third-party image sites. Tencent Cloud sites, http://mirrors.cloud.tencent.com/
and http://mirrors.tencentyun.com/
, cannot obtain CentOS 6 source. If you continue to use the default CentOS 6 source configured in Tencent Cloud, an error may occur.
Note:Upgrading your operating system to CentOS 7 or a later version is recommended. If you still need to use the CentOS 6 dependencies, switch the CentOS 6 source as instructed below.
cat /etc/centos-release
As shown in the following figure, the operating system version is CentOS 6.9.
3. Run the following command to edit the CentOS-Base.repo
file.
vim /etc/yum.repos.d/CentOS-Base.repo
baseurl
according to the CentOS version and network environment.
Note:
Determine the source required for your instance as instructed in Private Network Access and Internet Access
- Source for private network access:
http://mirrors.tencentyun.com/centos-vault/6.x/
- Source for public network access:
https://mirrors.cloud.tencent.com/centos-vault/6.x/
This document uses a CentOS 6.9-based instance that requires private network access as an example. The modified CentOS-Base.repo
file is as follows:
5. Press ESC, enter :wq, and press Enter to save the modification.
6. Run the following command to modify the CentOS-Epel.repo
file.
vim /etc/yum.repos.d/CentOS-Epel.repo
baseurl
based on the network environment.baseurl=http://mirrors.tencentyun.com/epel/$releasever/$basearch/
to baseurl=http://mirrors.tencentyun.com/epel-archive/6/$basearch/
. The result should be as follows:yum install
command to install the required software.
Was this page helpful?