暗中观察

CentOS 的yum源更换为aliyun源
1.备份$ mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos...
扫描右侧二维码阅读全文
14
2018/08

CentOS 的yum源更换为aliyun源

1.备份

$ mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup

2.下载

#CentOS 5
$ wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
###$ curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
#CentOS 6
$ wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
###$ curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo

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

3.生成缓存

$ yum clean all && yum makecache
最后修改:2018 年 08 月 14 日 11 : 04 PM
如果觉得我的文章对你有用,请随意赞赏

发表评论