zoukankan      html  css  js  c++  java
  • Centos配置阿里云yum源

      一、备份原来的yum源,以防后续使用

    cd /etc/yum.repos.d/;mkdir bak/; mv *.repo bak/

      二、下载阿里云的base源

    Centos6:

    wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-6.repo

    或者:

    curl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-6.repo

    Centos7:

     wget https://mirrors.aliyun.com/repo/Centos-7.repo

    或者:

    curl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-7.repo

    Centos:8

    wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-8.repo

    或者:

    curl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-8.repo

      三、下载阿里云的epel源

     wget -O /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo

      四、清除缓存并生成新的缓存

    yum clean all && yum makecache

    #生成缓存需要时间,可以直接显示当前可用yum源

    yum clean all && yum repolist
    ------------------------------------------------------------------------------------------------------------------------- ------------------------------------------------------- 博客均为个人笔记,无所追求,仅供参考~~~ QQ--2382990774
  • 相关阅读:
    Atcoder Beginner Contest075 翻车记
    bzoj1972 猪国杀 大♂模拟
    10月9-11日连续大翻车实录
    10月8日翻车实录
    10月7日考试翻车实录
    四月は君の嘘?人生は君の嘘?
    NOIP模拟 gcd 数学
    NOIP模拟 water 最小生成树
    NOIP模拟 mine DP
    bzoj2064 分裂 状压DP
  • 原文地址:https://www.cnblogs.com/alexlv/p/15252346.html
Copyright © 2011-2022 走看看