zoukankan      html  css  js  c++  java
  • 红帽配置Centos仓库[红帽Redhat7替换Centos7网络源]

    1.卸载红帽yum源
    rpm -e $(rpm -qa|grep yum) --nodeps
    
    2.删除所有repo相关文件
    rm -rf /etc/yum.conf
    rm -rf /etc/yum.repos.d/
    rm -rf /var/cache/yum
    
    3.下载centos相关yum组件
    wget https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-3.4.3-154.el7.centos.noarch.rpm
    wget https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-metadata-parser-1.1.4-10.el7.x86_64.rpm
    wget https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.31-42.el7.noarch.rpm
    wget https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-updateonboot-1.1.31-42.el7.noarch.rpm
    wget https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-utils-1.1.31-42.el7.noarch.rpm
    
    //如果没有wget命令则使用curl命令
    curl -o yum-utils-1.1.31-42.el7.noarch.rpm  https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-utils-1.1.31-42.el7.noarch.rpm
    curl -o yum-3.4.3-154.el7.centos.noarch.rpm  https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-3.4.3-154.el7.centos.noarch.rpm
    curl -o yum-metadata-parser-1.1.4-10.el7.x86_64.rpm  https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-metadata-parser-1.1.4-10.el7.x86_64.rpm
    curl -o yum-plugin-fastestmirror-1.1.31-42.el7.noarch.rpm   https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.31-42.el7.noarch.rpm
    curl -o yum-updateonboot-1.1.31-42.el7.noarch.rpm https://mirrors.aliyun.com/centos/7/os/x86_64/Packages/yum-updateonboot-1.1.31-42.el7.noarch.rpm
    
    3.安装所有相关组件
    [root@xuliangwei-node1 ~]# rpm -ivh yum-*
    
    4.下载base和epel仓库
    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
    sed -i 's#$releasever#7#g' /etc/yum.repos.d/CentOS-Base.repo
    
    wget -O /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo
    
  • 相关阅读:
    ubuntu11.04解决root不能登录的问题
    应用C预处理命令
    WINCE6.0在控制面板添加控制面板应用程序
    嵌入式系统开发
    WINCE6.0下开始菜单的“挂起(suspend)”是否可见及阻止系统进入睡眠模式
    WINCE6.0更换桌面壁纸和图标
    ubuntun_11.04安装
    WINCE开发更安全可靠设备驱动的最佳实践
    WINCE源代码配置文件
    TS2003基于触摸屏的应用
  • 原文地址:https://www.cnblogs.com/xuliangwei/p/10680639.html
Copyright © 2011-2022 走看看