Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use CentOS's yum Source in RHEL system

2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces "how to use the yum source of CentOS in the RHEL system". In the daily operation, I believe that many people have doubts about how to use the yum source of CentOS in the RHEL system. The editor consulted all kinds of materials and sorted out a simple and easy-to-use method of operation. I hope it will be helpful to answer the question of "how to use the yum source of CentOS in the RHEL system". Next, please follow the editor to study!

In RHEL6

1. Uninstall your own yum

The code is as follows:

# rpm-aq | grep yum | xargs rpm-e-nodeps

2. Download centos6-related packages

The code is as follows:

# wget http://mirrors.163.com/centos/6.0/os/x86_64/Packages/python-iniparse-0.3.1-2.1.el6.noarch.rpm

# wget http://mirrors.163.com/centos/6.0/os/x86_64/Packages/yum-metadata-parser-1.1.2-14.1.el6.x86_64.rpm

# wget http://mirrors.163.com/centos/6.0/os/x86_64/Packages/yum-3.2.27-14.el6.centos.noarch.rpm

# wget http://mirrors.163.com/centos/6.0/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.26-11.el6.noarch.rpm

3. Installation

The code is as follows:

# rpm-ivh python-iniparse-0.3.1-2.1.el6.noarch.rpm

# rpm-ivh yum-metadata-parser-1.1.2-14.1.el6.x86_64.rpm

# rpm-ivh yum-3.2.27-14.el6.centos.noarch.rpm yum-plugin-fastestmirror-1.1.26-11.el6.noarch.rpm

4. Copy repo in centos6 to RHEL6

The code is as follows:

Centos6#scp / etc/yum.repos.d/CentOS-Base.repo rhel6:/etc/yum.repos.d/CentOS-Base.repo

Rhel6# vi / etc/yum.repos.d/CentOS-Base.repo

Edit:

The code is as follows:

:% s/$releasever/6.0/

5. Import the key of centos6

The code is as follows:

Centos6#scp / media/CentOS/RPM-GPG-KEY-CentOS-6 rhel6:/tmp

Rhel6#rpm-import / tmp/RPM-GPG-KEY-CentOS-6

6. Use

The code is as follows:

# yum clean all

# yum list

There is no wrong report.

At this point, the study on "how to use CentOS's yum source in RHEL system" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report