解决CentOS 7停止更新支持后yum源失效

最近 CentOS 7 已经停止更新支持,同时官方也把 yum 源删除了,目前 CentOS 7 系统使用 yum 命令安装软件包提示“Could not resolve host: mirrorlist.centos.org; Unknown error”,因此需要更换 yum 源。

在 ssh 界面执行以下命令即可更换 yum 源为 CentOS 的 Vault 源(包括 CentOS 官方和阿里云的源):

  1. wget -O /etc/yum.repos.d/CentOS-Base.repo http://file.kangle.cccyun.cn/repo/Centos-7.repo
  2. yum makecache
一键复制

或者

  1. curl -o /etc/yum.repos.d/CentOS-Base.repo http://file.kangle.cccyun.cn/repo/Centos-7.repo
  2. yum makecache
一键复制
您的回答

回答

默认排序 时间排序
个人中心
购物车
优惠劵
今日签到
私信列表
搜索
  • 纵**下成功下载了朋友圈访客记录系统h5网站源码2025变现神器超好资源!