1,,备份系统默认文件
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo_bak
2,下载阿里源的文件
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
3,清理缓存
yum clean all
4,重新生成缓存
yum makecache
1,,备份系统默认文件
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo_bak
2,下载阿里源的文件
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
3,清理缓存
yum clean all
4,重新生成缓存
yum makecache
本文标题:Centos7修改yum源为阿里源
本文链接:https://www.haomeiwen.com/subject/sxbvpktx.html
网友评论