首页 > 系统服务 > 详细

01_Linux软件源配置

时间:2018-01-20 20:21:42      阅读:200      评论:0      收藏:0      [点我收藏+]

 

一、国内软件源

  1. 阿里源:https://mirrors.aliyun.com/
  2. 清华大学:https://mirrors.tuna.tsinghua.edu.cn/
  3. 中科大 : https://mirrors.ustc.edu.cn/

有很多,大家可以百度。

二、以Centos 6.7为例配置

1.备份系统默认的源配置

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

技术分享图片

2.进入阿里源官网

技术分享图片

 

3.下载新的CentOS-Base.repo到/etc/yum.repos.d/

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

 

 三、生成yum缓存

yum makecache

 

01_Linux软件源配置

原文:https://www.cnblogs.com/weihengblog/p/8321672.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!