#先执行备份,然后将下面的配置文件替换之即可

mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak


#再修改文件内容:

#适用于aarch64构架的阿里云镜像源配置文件
#其实无非就是批量替换版本以及构架而已
# CentOS-Base.repo

[base]
name=CentOS-7.7.1908 - Base - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-altarch/7.7.1908/os/aarch64/
        http://mirrors.aliyuncs.com/centos-altarch/7.7.1908/os/aarch64/
        http://mirrors.cloud.aliyuncs.com/centos-altarch/7.7.1908/os/aarch64/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos-altarch/RPM-GPG-KEY-CentOS-7
 
#released updates 
[updates]
name=CentOS-7.7.1908 - Updates - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-altarch/7.7.1908/updates/aarch64/
        http://mirrors.aliyuncs.com/centos-altarch/7.7.1908/updates/aarch64/
        http://mirrors.cloud.aliyuncs.com/centos-altarch/7.7.1908/updates/aarch64/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos-altarch/RPM-GPG-KEY-CentOS-7
 
#additional packages that may be useful
[extras]
name=CentOS-7.7.1908 - Extras - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-altarch/7.7.1908/extras/aarch64/
        http://mirrors.aliyuncs.com/centos-altarch/7.7.1908/extras/aarch64/
        http://mirrors.cloud.aliyuncs.com/centos-altarch/7.7.1908/extras/aarch64/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos-altarch/RPM-GPG-KEY-CentOS-7
 
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-7.7.1908 - Plus - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-altarch/7.7.1908/centosplus/aarch64/
        http://mirrors.aliyuncs.com/centos-altarch/7.7.1908/centosplus/aarch64/
        http://mirrors.cloud.aliyuncs.com/centos-altarch/7.7.1908/centosplus/aarch64/
gpgcheck=1
enabled=0
gpgkey=http://mirrors.aliyun.com/centos-altarch/RPM-GPG-KEY-CentOS-7
 
#contrib - packages by Centos Users
[contrib]
name=CentOS-7.7.1908 - Contrib - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-altarch/7.7.1908/contrib/aarch64/
        http://mirrors.aliyuncs.com/centos-altarch/7.7.1908/contrib/aarch64/
        http://mirrors.cloud.aliyuncs.com/centos-altarch/7.7.1908/contrib/aarch64/
gpgcheck=1
enabled=0
gpgkey=http://mirrors.aliyun.com/centos-altarch/RPM-GPG-KEY-CentOS-7