Leif160519的blog Leif160519的blog

——————

目录
Centos 7换源
/  

Centos 7换源

首先安装wget组件:

yum install -y wget

国外地址yum源下载慢,下到一半就断了,就这个原因就修改它为国内yum源地址

国内也就是ali 与 网易

以centos7为例 ,以 修改为阿里的yum源

  1. 备份本地yum源
 mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo_bak 

2.获取阿里yum源配置文件

 wget -O /etc/yum.repos.d/CentOS-Base.repo  http://mirrors.aliyun.com/repo/Centos-7.repo 

3.更新cache

 yum makecache 

4.查看

 yum -y update

“The first 90% of the code accounts for the first 90% of the development time. The remaining 10% of the code accounts for the other 90% of the development time.” – Tom Cargill

标  题Centos 7换源
作  者Leif160519
出  处https://github.icu/articles/2019/08/22/1566471743557.html
关于博主:坐标南京,运维工程师,如有问题探讨可以直接下方留言。
声援博主:如果您觉得文章对您有帮助,可以评论、订阅、收藏。您的鼓励是博主的最大动力!