zoukankan      html  css  js  c++  java
  • CentOS7系统配置国内yum源和epel源

    1.首先进入/etc/yum.repos.d/目录下,新建一个repo_bak目录,用于保存系统中原来的repo文件

    [root@node01 ~]# cd /etc/yum.repos.d/
    [root@node01 yum.repos.d]# yum -y install wget
    [root@node01 yum.repos.d]# mkdir repo_bak
    [root@node01 yum.repos.d]# mv *.repo repo_bak/

    2.在CentOS中配置使用网易和阿里的开源镜像
    到网易和阿里开源镜像站点下载系统对应版本的repo文件

    [root@node01 yum.repos.d]# wget http://mirrors.aliyun.com/repo/Centos-7.repo
    [root@node01 yum.repos.d]# wget http://mirrors.163.com/.help/CentOS7-Base-163.repo
    [root@node01 yum.repos.d]# ls
    CentOS7-Base-163.repo  Centos-7.repo  repo_bak
    [root@node01 yum.repos.d]# yum clean all 
    [root@node01 yum.repos.d]# yum makecache

    查看系统可用的yum源和所有的yum源

    [root@node01 yum.repos.d]# yum repolist enabled 
    已加载插件:fastestmirror
    Repository base is listed more than once in the configuration
    Repository updates is listed more than once in the configuration
    Repository extras is listed more than once in the configuration
    Repository centosplus is listed more than once in the configuration
    Loading mirror speeds from cached hostfile
    源标识                                                                    源名称                                                                                 状态
    base/7/x86_64                                                             CentOS-7 - Base - 163.com                                                              10,097
    extras/7/x86_64                                                           CentOS-7 - Extras - 163.com                                                               323
    updates/7/x86_64                                                          CentOS-7 - Updates - 163.com                                                            1,117
    repolist: 11,537
  • 相关阅读:
    docker删除常见命令
    测试网中用户添加docker yum源
    kafka 重新分配partition
    docker-compose常用命令
    docker 常用命令
    docker-compose部署ELK
    ELK全Dokcer 部署
    Harbor修改/data目录位置
    单机多es容器服务部署的网络模式
    C++使用模板类时出现LNK2019 unresolved external symbol错误.
  • 原文地址:https://www.cnblogs.com/liujunjun/p/12260198.html
Copyright © 2011-2022 走看看