第一步:备份原有镜像源

mv /etc/yum.repo.d/Centos-Base.repo /etc/yum.repo.d/Centos-Base.repo.bak 

第二步:下载阿里云的镜像源

wget -O /etc/yum.repo.d/Centos-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
//如果是cento 5的系统就将文件名改为Centos-5.repo

第三步 :重新设置缓存

yum clean all
yum makecache

Linux将yum源设置为阿里云的镜像源的更多相关文章

  1. Centos将yum源设置为阿里云的镜像源

    第一步:备份原有镜像源 mv /etc/yum.repo.d/Centos-Base.repo /etc/yum.repo.d/Centos-Base.repo.bak 第二步:下载阿里云的镜像源 w ...

  2. MAC OS系统替换homebrew使用阿里云的镜像源

    MAC OS系统替换homebrew使用阿里云的镜像源 2019-03-03 15:13:42 南通SEO 阅读数 2024更多 分类专栏: 解决方案   MAC OS系统替换homebrew使用阿里 ...

  3. zabbix官方源替换为阿里云的zabbix源,一键脚本。(安装zabbix报错curl#18 - "transfer closed with 2988713 bytes remaining to read":15 ETA Trying other mirro)

    最近突然安装zabbix总是报错,比如 (24/27): t1lib-5.1.2-14.el7.x86_64.rpm | 166 kB 00:00:00 zabbix-web-4.4.6-1.el7. ...

  4. Centos yum的源 设置为阿里云源

    在 阿里巴巴镜像站页面,在centos 操作的帮助,有介绍 wget和curl 2种方式来下载CentOS-Base.repo 备份 mv /etc/yum.repos.d/CentOS-Base.r ...

  5. MAC OS系统替换brew.npm, pip 使用阿里云的镜像源

    替换brew.git:cd "$(brew --repo)"git remote set-url origin https://mirrors.aliyun.com/homebre ...

  6. CentOS 7配置网卡信息,并设置yum为阿里云的镜像源

    一.问题场景 使用virtualbox创建的centos 7版本的linux虚拟机,使用ping mirrors.aliyun.com有返回,但是wget -O /etc/yum.repos.d/ep ...

  7. 更改CentOS 7更新源为国内阿里云提供的源

    1.备份 mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup 2.下载新的CentOS-Base ...

  8. 教你优化yum源。配置阿里云的yum镜像源(base和epel)

    一.Centos7的base源配置阿里云的yum源: 1.备份旧的yum源目录下的所有文件 [root@ELK-chaofeng07 yum.repos.d]# mkdir ../yum.repos. ...

  9. 更改CentOS 6.3 yum源为国内 阿里云源

    将CentOS的 yum源 更换为 阿里云源 1.备份 mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.b ...

随机推荐

  1. shell 自加

    Linux Shell中写循环时,常常要用到变量的自增,现在总结一下整型变量自增的方法.我所知道的,bash中,目前有五种方法:1. i=`expr $i + 1`;2. let i+=1;3. (( ...

  2. 记录Ubuntu & Windows下安装PyV8

    https://blog.csdn.net/hanshileiai/article/details/51628173

  3. POJ2386----Lake Counting

    /* 利用宽搜将每块积水填满,添加一个计数器,记下填满几块积水即答案 */ #include<iostream> using namespace std; ][]; ][] = {{-,- ...

  4. Redis自学笔记:3.4入门-列表类型

    3.4列表类型 3.4.1介绍 列表类型可以存储一个有序的字符串列表,常用的操作是向列表两端添加元素,或者 获得列表的某一片段. 优点:内部使用的是双向链表,所以向列表两端添加元素的时间复杂度为O(1 ...

  5. c#取数据库数据 ---两种方法

    通常有以下两种方式 SqlDataReader 和SqlDataAdapter|DataSet方式 SqlDataReader 方式使用方式如下: using System; using System ...

  6. Good Bye 2018 (A~F, H)

    目录 Codeforces 1091 A.New Year and the Christmas Ornament B.New Year and the Treasure Geolocation C.N ...

  7. [P2671][NOIP2015]求和 (数论)

    [题目链接] 这位大神讲得很详细:点我 本蒟蒻只会抄抄题解了 #include<bits/stdc++.h> #define max(a,b) (a>b?a:b) #define m ...

  8. Spring使用原生JDBC

    Spring使用原生JDBC 为加深对Spring解耦的理解,本次实验学习用Spring连接JDBC 一.POM配置文件 pom.xml <project xmlns="http:// ...

  9. GDB快速入门

    GDB快速入门 GDB(GNU DeBugger)是Linux下强大的C/C++调试器,纯命令行操作 启动 以下为测试代码 #include <stdio.h> int nGlobalVa ...

  10. 重新看待Jar包冲突问题及解决方案

    Jar包冲突是老生常谈的问题,几乎每一个Java程序猿都不可避免地遇到过,并且也都能想到通常的原因一般是同一个Jar包由于maven传递依赖等原因被引进了多个不同的版本而导致,可采用依赖排除.依赖管理 ...