替换到 中国科学技术大学开源软件镜像 命令
http://mirrors.ustc.edu.cn/help/centos.html
sudo sed -e 's|^mirrorlist=|#mirrorlist=|g' \
-e 's|^#baseurl=http://mirror.centos.org/$contentdir|baseurl=https://mirrors.ustc.edu.cn/centos|g' \
-i.bak \
/etc/yum.repos.d/CentOS-Stream-AppStream.repo \
/etc/yum.repos.d/CentOS-Stream-BaseOS.repo \
/etc/yum.repos.d/CentOS-Stream-Debuginfo.repo \
/etc/yum.repos.d/CentOS-Stream-Extras.repo \
/etc/yum.repos.d/CentOS-Stream-HighAvailability.repo \
/etc/yum.repos.d/CentOS-Stream-Media.repo \
/etc/yum.repos.d/CentOS-Stream-PowerTools.repo \
/etc/yum.repos.d/CentOS-Stream-RealTime.repo
替换之后请运行 yum makecache 更新缓存
文章评论