美文网首页
更换阿里源

更换阿里源

作者: 小白net | 来源:发表于2019-11-10 16:21 被阅读0次

# file: CentOS-AppStream.repo

[AppStream]

name=CentOS-$releasever - AppStream

baseurl=http://mirrors.aliyun.com/centos/$releasever/AppStream/$basearch/os/

gpgcheck=1

enabled=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial

# file: CentOS-Base.repo

[BaseOS]

name=CentOS-$releasever - Base

baseurl=http://mirrors.aliyun.com/centos/$releasever/BaseOS/$basearch/os/

gpgcheck=1

enabled=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial

# file: CentOS-Epel.repo

[epel]

name=CentOS-$releasever - Epel

baseurl=http://mirrors.aliyun.com/epel/8/Everything/$basearch

enabled=1

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-8

# file: CentOS-Media.repo

[c8-media-BaseOS]

name=CentOS-BaseOS-$releasever - Media

baseurl=file:///media/CentOS/BaseOS/

gpgcheck=1

enabled=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial

[c8-media-AppStream]

name=CentOS-AppStream-$releasever - Media

baseurl=file:///media/CentOS/AppStream/

gpgcheck=1

enabled=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial

注:CentOS-Media 配置全需要将光盘挂载至/media/CentOS路径,否则在使用时会报错。

然后执行如下命令:

dnf clean all

dnf makecache


原文链接:https://www.bbsmax.com/A/x9J2PbkZd6/

相关文章

网友评论

      本文标题:更换阿里源

      本文链接:https://www.haomeiwen.com/subject/vmjabctx.html