最近安裝centos8.3 按照百度配置阿里雲出錯如下:
Errors during downloading metadata for repository 'baseos':
- Status code: 404 for https://mirrors.aliyun.com/centos/8/BaseOS/x86_64/os/repodata/repomd.xml (IP: 39.96.118.192)
Error: Failed to download metadata for repo 'baseos': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried
之后安裝yum配置里地址上去 發現centos8終止支持之后將之前yum源中的文件刪除了 需要去 http://mirrors.aliyun.com/centos-vault/找到對應的yum文件
具體配置如下
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[base]
name=CentOS-$releasever - Base - mirrors.aliyun.com
#failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/8.3.2011/BaseOS/x86_64/os/
gpgcheck=0
#additional packages that may be useful
[extras]
name=CentOS-$releasever - Extras - mirrors.aliyun.com
#failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/8.3.2011/extras/x86_64/os/
gpgcheck=0
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-$releasever - Plus - mirrors.aliyun.com
#failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/8.3.2011/centosplus/x86_64/os/
gpgcheck=0
enabled=1
[PowerTools]
name=CentOS-$releasever - PowerTools - mirrors.aliyun.com
#failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/8.3.2011/PowerTools/x86_64/os/
gpgcheck=0
enabled=1
[AppStream]
name=CentOS-$releasever - AppStream - mirrors.aliyun.com
#failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/8.3.2011/AppStream/x86_64/os/
gpgcheck=0
之后就可以正常更新軟件、安裝軟件了。