新闻公告

文章详情

了解最新动态和产品更新
获取帮助文档和使用指南

返回新闻列表

CentOS Stream 8 更换源的方法解决软件安装问题

2024/11/11 15:13:49 帮助中心

CentOS Stream 8 因官方停止支持,所以对应的源也失效了。

首先备份/etc/yum.repos.d/下的所有文件,然后清空这个文件夹。

然后在这个目录新建一个文件,如采用阿里的源,将以下代码保存,命名为:Aliyun-Centos-Stream-8.repo。



[BaseOS]
name=BaseOS
baseurl=https://mirrors.aliyun.com/centos/8-stream/BaseOS/x86_64/os/
enabled=1
gpgcheck=0
[Appstream]
name=Appstream
baseurl=https://mirrors.aliyun.com/centos/8-stream/AppStream/x86_64/os/
enabled=1
gpgcheck=0
[Extras]
name=Extras
baseurl=https://mirrors.aliyun.com/centos/8-stream/extras/x86_64/os/
enabled=1
gpgcheck=0
[PowerTools]
name=PowerTools
baseurl=https://mirrors.aliyun.com/centos/8-stream/PowerTools/x86_64/os/
enabled=1
gpgcheck=0

继续执行 清理

yum clean all

更新

yum makecache


工单