• centos更改镜像源


    1)先安装wget
    执行命令 yum install -y wget

    [root@localhost ~]# yum install -y wget

        1

        查询国内镜像源

    打开阿里镜像http://mirrors.aliyun.com/

    这里写图片描述
    点击帮助:
    这里写图片描述
    3)下载CentOS 7的repo文件

    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

        1
        2
        3

    4)更新镜像源

    #清除缓存
    yum clean all  
    #生成缓存
    yum makecache

        1
        2
        3
        4

    [root@localhost ~]# yum clean all
    Loaded plugins: fastestmirror
    Cleaning repos: base extras updates
    Cleaning up everything
    Cleaning up list of fastest mirrors
    [root@localhost ~]# yum makecache
    Loaded plugins: fastestmirror
    base                                                                                                                                                                  | 3.6 kB  00:00:00     
    extras                                                                                                                                                                | 3.4 kB  00:00:00     
    updates                                                                                                                                                               | 3.4 kB  00:00:00     
    (1/12): base/7/x86_64/group_gz                                                                                                                                        | 155 kB  00:00:00     
    (2/12): extras/7/x86_64/filelists_db                                                                                                                                  | 770 kB  00:00:02     
    (3/12): extras/7/x86_64/primary_db                                                                                                                                    | 151 kB  00:00:00     
    (4/12): extras/7/x86_64/other_db                                                                                                                                      | 640 kB  00:00:07     
    (5/12): updates/7/x86_64/filelists_db
    .......省略

        1
        2
        3
        4
        5
        6
        7
        8
        9
        10
        11
        12
        13
        14
        15
        16

    大痴小乙
    关注


    ————————————————
    版权声明:本文为CSDN博主「大痴小乙」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
    原文链接:https://blog.csdn.net/fxbin123/article/details/80072793

  • 相关阅读:
    记录一次servlet页面无法跳转的血的教训
    1862-your password has expired. To log in you must change it using a client that supports expired passwords.问题解决
    Error starting static Resources java.lang.IllegalArgumentException: Document base D:eclipse*wtpwebapps* does not exist or is not a readable directory问题的解决
    MapReduce Shuffle过程的简单理解
    MapReduce实验03——排序
    zachman架构
    大型高并发与高可用缓存架构总结2
    金蝶SOA案例分析
    感悟:菜鸟弹性调度系统的架构设计
    大型高并发与高可用缓存架构总结
  • 原文地址:https://www.cnblogs.com/lzkalislw/p/15473852.html
Copyright © 2020-2023  润新知