Skip to content

解决CentOS 8无法通过yum下载软件的问题 #1

@huangxiaocheng93

Description

@huangxiaocheng93

原因是CentOS 8已于2021年12月31日停止维护,在2022年1月31日,CentOS团队终于从官方镜像中移除CentOS 8的所有包。

可以把源替换为阿里云的源解决此问题:

sed -i -e "s|mirrorlist=|#mirrorlist=|g" /etc/yum.repos.d/CentOS-*
sed -i -e "s|#baseurl=http://mirror.centos.org|baseurl=http://mirrors.aliyun.com|g" /etc/yum.repos.d/CentOS-*

如果yum update以后又报错,就需要再次执行上面的命令。

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions