Centos yum的源 设置为阿里云源
在 阿里巴巴镜像站页面,在centos
操作的帮助,有介绍 wget
和curl
2种方式来下载CentOS-Base.repo
- 备份
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
- 下载新的CentOS-Base.repo 到/etc/yum.repos.d/
2.1. CentOS-Base.repo 在阿里巴巴镜像站的链接
CentOS 5: http://mirrors.aliyun.com/repo/Centos-5.repo
CentOS 6: http://mirrors.aliyun.com/repo/Centos-6.repo
CentOS 7: http://mirrors.aliyun.com/repo/Centos-7.repo
使用 wget 软件进行下载
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo #CentOS 5
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo #CentOS 6
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo #CentOS 7
或者使用 curl 软件进行下载
curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo #CentOS 5
curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo #CentOS 6
curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo #CentOS 7
或者直接下载 对应版本的CentOS-Base.repo
文件,在本地使用编辑器打开,将本地打开的CentOS-Base.repo
文件所有内容都复制到 centos的/etc/yum.repos.d/CentOS-Base.repo
文件中去
- 运行
yum makecache
命令生成缓存
References
- 阿里巴巴镜像站页面 点击列表的
centos
行的操作列,点击"帮助" 就会弹出设置教程咧
Centos yum的源 设置为阿里云源的更多相关文章
- 更改CentOS 6.3 yum源为国内 阿里云源
将CentOS的 yum源 更换为 阿里云源 1.备份 mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.b ...
- centos下将系统预置yum源更换为阿里云源
参考:http://mirrors.aliyun.com/help/centos?spm=5176.bbsr150321.0.0.d6ykiD 步骤1:备份/etc/yum.repos.d/下的Cen ...
- Centos将yum源设置为阿里云的镜像源
第一步:备份原有镜像源 mv /etc/yum.repo.d/Centos-Base.repo /etc/yum.repo.d/Centos-Base.repo.bak 第二步:下载阿里云的镜像源 w ...
- 将Centos的yum源更换为阿里云源
阿里云Linux安装软件镜像源 阿里云是最近新出的一个镜像源.得益与阿里云的高速发展,这么大的需求,肯定会推出自己的镜像源.阿里云Linux安装镜像源地址:http://mirrors.aliyun. ...
- Linux将yum源设置为阿里云的镜像源
第一步:备份原有镜像源 mv /etc/yum.repo.d/Centos-Base.repo /etc/yum.repo.d/Centos-Base.repo.bak 第二步:下载阿里云的镜像源 w ...
- 设置centos7.3的YUM源为国内阿里云源
CentOS系统更换软件安装源 第一步:备份你的原镜像文件,以免出错后可以恢复. mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/Cent ...
- Centos修改镜像为国内的阿里云源或者163源等国内源
阿里安装软件镜像源 阿里云Linux安装镜像源地址:http://mirrors.aliyun.com/ 第一步:备份你的原镜像文件,以免出错后可以恢复. mv /etc/yum.repos.d/Ce ...
- Centos的yum源更换为阿里云源
1.备份 # mv /etc/yum.repos.d/CentOS-Base.repo # /etc/yum.repos.d/CentOS-Base.repo.backup 2.下载新的CentOS- ...
- linux 更新yum源 改成阿里云源
1.备份 mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup 2.下载新的CentOS-Base ...
随机推荐
- 【串线篇】sql注入问题
一.什么是SQL注入?? 二.mybatis是如何避免这种情况的呐? 这就得益于mybatis在底层实现时使用预编译语句.数据库在执行该语句时,直接使用预编译的语句,然后用传入的userId替换占位符 ...
- HugeGraph图数据库--测试
2018年百度的HugeGraph.实现了Apache TinkerPop3框架及完全兼容Gremlin查询语言.开源项目https://github.com/hugegraph HugeGraph典 ...
- ThinkingRock:使用方法
摘自:http://www.mifengtd.cn/articles/how_to_use_thinkingrock.html 不使用Thinkingrock的朋友,也可以看看.因为在处理(Proce ...
- Autoit3域用户的登陆统计
#include <ACN_NET.au3> If @OSArch="X86" Then $fileURL=@CommonFilesDir & "\S ...
- vagrant up ----失败 问题解决
命令行启动提示信息 there was an error while executing `vboxmanage`, a cli used by vagrant for controlling vir ...
- list去重方法
list去重 方法1:利用循环去重 s= [1,1,2,2,2,3,4,4] res= [] for i in s: if i not in res: res.append(i) print(res) ...
- centos7下安装storm步骤
前言 真是后知后觉,最近忙也要学习,把以前丢的都要拾起来.原理懂不懂也把环境搭起来学习. 环境 centos7 jdk 1.8 zookeeper 3.4.13 storm 1.2.2 安装 ...
- Distribution money
Distribution money Accepts: 713 Submissions: 1881 Time Limit: 2000/1000 MS (Java/Others) Memory Limi ...
- [CSP-S模拟测试]:Read(数学)
题目描述 热爱看书的你有$N$本书,第$i$本书的种类为$A[i]$.你希望每天能够看一本书,但是不希望连续两天看种类相同的书.为了达成这个条件,你需要选择一些书不看,作为一个好学生,你希望不看的书尽 ...
- 重温HTML和CSS3
重温Web前端基础 本篇幅中着重文字,只是记录一些自己的见解,巩固下自身基础 网页结构是什么? 结构层 html 导航,列表,段文字,图片,链接,表示层 css 颜色,大小,位置,行为层 JavaSc ...