• redhat 7安装CentOS 7 yum源 风行天下


    http://www.bubuko.com/infodetail-2004218.html

    http://www.bubuko.com/infodetail-2004218.html

     ****************************************

    1报错信息:    参考:https://www.centos.org/forums/viewtopic.php?t=36563

    [root@LinuxS04 site-packages]# yum
    There was a problem importing one of the Python modules
    required to run yum. The error leading to this problem was:

       No module named urlgrabber

    Please install a package which provides this module, or
    verify that the module is installed correctly.

    It's possible that the above module doesn't match the
    current version of Python, which is:
    2.7.5 (default, Feb 11 2014, 07:46:25)
    [GCC 4.8.2 20140120 (Red Hat 4.8.2-13)]

    If you cannot solve this problem yourself, please go to
    the yum faq at:
      http://yum.baseurl.org/wiki/Faq
      解决办法:
    [root@LinuxS04 site-packages]# rpm -qa | grep urlgrabber
    python-urlgrabber-3.10-4.el7.noarch
    [root@LinuxS04 site-packages]# rpm -qa python-urlgrabber-3.10-4.el7.noarch
    [root@LinuxS04 site-packages]# rpm -e --nodeps  python-urlgrabber-3.10-4.el7.noarch
    然后安装:
    [root@LinuxS04 yum.repos.d]# rpm -ivh python-urlgrabber-3.10-8.el7.noarch.rpm
    警告:python-urlgrabber-3.10-8.el7.noarch.rpm: 头V3 RSA/SHA256 Signature, 密钥 ID f4a80eb5: NOKEY
    准备中...                          ################################# [100%]
    正在升级/安装...
       1:python-urlgrabber-3.10-8.el7     ################################# [100%]
    再运行yum即可,没有报错了。!!!!

     *********************************************************************************************************************************************

    2,红帽7安装图形桌面报错

    yum groupinstall "GNOME Desktop"

    报错信息      :

    错误:unbound-libs conflicts with redhat-release-server-7.0-1.el7.x86_64
    错误:initscripts conflicts with redhat-release-server-7.0-1.el7.x86_64
    您可以尝试添加 --skip-broken 选项来解决该问题
    ** 发现 1 个已存在的 RPM 数据库问题, 'yum check' 输出如下:
    rhn-check-2.0.2-21.el7.noarch 有缺少的需求 yum-rhn-plugin >= ('0', '1.6.4', '1')

    后经搜索:https://access.redhat.com/solutions/3423391

     必须参加红帽订阅才可以安装

    *********************************************************************************************************************************************

    https://www.cnblogs.com/haoyufeng/p/4393005.html    自己测过了,可以使用的。

    1、[root@localhost ~]# rpm -qa|grep yum|xargs rpm -e --nodeps(不检查依赖,直接删除rpm包)

    2、下载新的yum包

    在以下下载地址为 一个个搜 ...........

    http://rpm.pbone.net/

    3、  下载地址都不能用了

    [root@localhost ~]# wget http://mirrors.163.com/centos/7.1.1503/os/x86_64/Packages/yum-3.4.3-125.el7.centos.noarch.rpm

    [root@localhost ~]# wget http://mirrors.163.com/centos/7.1.1503/os/x86_64/Packages/yum-metadata-parser-1.1.4-10.el7.x86_64.rpm

    [root@localhost ~]# wget http://mirrors.163.com/centos/7.1.1503/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.31-29.el7.noarch.rpm

    [root@localhost ~]# wget http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-7

    4、安装这些包

    [root@localhost ~]# rpm -ivh yum-*

    5、配置repo文件     配置阿里源  https://blog.csdn.net/CChenheng/article/details/79863888

    [base]
    name=CentOS-$7 - Base - aliyun.com
    #mirrorlist=http://mirrorlist.centos.org/?release=$7&arch=$basearch&repo=os
    baseurl=https://mirrors.aliyun.com/centos/7/os/$basearch/
    gpgcheck=1
    gpgkey=https://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7

    #released updates
    [updates]
    name=CentOS-$7 - Updates - aliyun.com
    #mirrorlist=http://mirrorlist.centos.org/?release=$7&arch=$basearch&repo=updates
    baseurl=https://mirrors.aliyun.com/centos/7/updates/$basearch/
    gpgcheck=1
    gpgkey=https://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7

    #additional packages that may be useful
    [extras]
    name=CentOS-$7 - Extras - aliyun.com
    #mirrorlist=http://mirrorlist.centos.org/?release=$7&arch=$basearch&repo=extras
    baseurl=https://mirrors.aliyun.com/centos/7/extras/$basearch/
    gpgcheck=1
    gpgkey=https://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7

    #additional packages that extend functionality of existing packages
    [centosplus]
    name=CentOS-$7 - Plus - aliyun.com
    baseurl=https://mirrors.aliyun.com/centos/7/centosplus/$basearch/
    gpgcheck=1
    enabled=0

    gpgkey=https://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7

  • 相关阅读:
    Mysql推荐使用规范
    程序员应该经常浏览的技术网站
    百度,腾讯,阿里等互联网公司年终奖发多少
    JNI技术详解,让程序有飞一般的感觉
    日志:分布式系统的核心
    Spring Boot七:Spring boot集成MyBatis
    通俗理解TCP的三次握手
    JDBC添加数据
    JDBC概念
    今天是阳光明媚的一天
  • 原文地址:https://www.cnblogs.com/yaok430/p/9103872.html
Copyright © 2020-2023  润新知