linux centos 网易换源
-
备份源
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak
-
下载国内源
cd /etc/yum.repos.d/
wget http://mirrors.163.com/.help/CentOS7-Base-163.repo
-
将
CentOS7-Base-163.repo
改名为CentOS-Base.repo
mv CentOS7-Base-163.repo CentOS-Base.repo
-
清除缓存
yum clean all
-
更新本地yum源缓存
yum makecache