zoukankan      html  css  js  c++  java
  • [转]redhat7(centos7) not registered to Red Hat Subscription Management

    [root@localhost yum.repos.d]# yum clean all
    Loaded plugins: fastestmirror, langpacks, product-id, search-disabled-repos,
                  : subscription-manager
    This system is not registered with an entitlement server. You can use subscription-manager to register.
    There are no enabled repos.
     Run "yum repolist all" to see the repos you have.
     To enable Red Hat Subscription Management repositories:
         subscription-manager repos --enable <repo>
     To enable custom repositories:
         yum-config-manager --enable <repo>

    遇到上面的问题,转载一篇解决方案:http://www.linuxidc.com/Linux/2013-10/90932.htm

    https://bbs.vpser.net/thread-7553-1-1.html

    =====================================================================================================    

    今日网上搜索了很多关于RHEL6.4更改为CentOS源的文章,都是按照一步一步去操作,但都是不行的。后来自己综合了各篇文章,修修改改,终于成功更改了yum源。

    第一步:删除默认的yum源。命令如下
    rpm-aq | grep yum|xargs rpm -e--nodeps

    第二步:下载最新的yum安装包

    http://mirrors.163.com/centos/7/os/x86_64/Packages/

    wget http://ftp.nara.wide.ad.jp/pub/Linux/centos/6.4/os/x86_64/Packages/python-iniparse-0.3.1-2.1.el6.noarch.rpm
    wget http://ftp.nara.wide.ad.jp/pub/Linux/centos/6.4/os/x86_64/Packages/yum-metadata-parser-1.1.2-16.el6.x86_64.rpm
    wget http://ftp.nara.wide.ad.jp/pub/Linux/centos/6.4/os/x86_64/Packages/yum-3.2.29-40.el6.centos.noarch.rpm
    wget http://ftp.nara.wide.ad.jp/pub/Linux/centos/6.4/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm

    第三步:安装yum相关软件。
    rpm-ivh python-iniparse-0.3.1-2.1.el6.noarch.rpm
    rpm-ivh yum-metadata-parser-1.1.2-16.el6.x86_64.rpm
    rpm-ivh yum-3.2.29-40.el6.centos.noarch.rpm yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm

    第四步:更改yum源,我们使用网易的镜像源,可以去这里http://mirrors.163.com/.help/centos.html 下载最新的CentOS-Base.repo文件,然后cp到/etc/yum.repos.d/目录下,修改把文件里面的$releasever全部替换为版本号,即6 最后保存。最后把这个文件命名为rhel-source.repo,替换掉原来该目录的同名文件。

    第五步:清理yum缓存
    yum clean all
    yum makecache
    最后显示如下,更换yum源成功。

    Loaded plugins: fastestmirror, product-id, subscription-manager
    This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
    Determining fastest mirrors
    base | 3.7 kB 00:00 
    base/group_gz | 212 kB 00:00 
    base/filelists_db | 5.9 MB 00:12 
    base/primary_db | 4.4 MB 00:09 
    base/other_db | 2.7 MB 00:05 
    extras | 3.4 kB 00:00 
    extras/filelists_db | 10 kB 00:00 
    extras/prestodelta | 905 B 00:00 
    extras/primary_db | 18 kB 00:00 
    extras/other_db | 5.7 kB 00:00 
    updates | 3.4 kB 00:00 
    updates/filelists_db | 4.0 MB 00:08 
    updates/prestodelta | 978 kB 00:02 
    updates/primary_db | 4.4 MB 00:09 
    updates/other_db | 661 kB 00:01

  • 相关阅读:
    文件读写,函数,元组和集合
    Python列表,字典和字符串操作
    linux grep程序输出 文本过滤
    prj坐标转换
    ubuntu 分卷解压中文乱码
    利用ssh 删除远程服务器文件
    git 提交
    linux 命令scp
    osgEarth编译——以VS2012为例
    GDAL2.0编译——32位和64位
  • 原文地址:https://www.cnblogs.com/hilaryqs/p/9055752.html
Copyright © 2011-2022 走看看