About Redhat Enterprise Linux 6.4 using the CentOS 6 yum source

Source: Internet
Author: User
Tags gpg

Idea: Uninstall Redhat with yum, then download the CentOS yum, install and modify the configuration file

1 , first to Http://mirrors.163.com/centos Download Package

x86 Address: http://mirrors.163.com/centos/6/os/i386/Packages/

x86_64 Address: http://mirrors.163.com/centos/6/os/x86_64/Packages/

The necessary packages to download are (for example, 64-bit systems):

A python-iniparse-0.3.1-2.1.el6.noarch.rpm

b yum-3.2.29-40.el6.centos.noarch.rpm

C yum-metadata-parser-1.1.2-16.el6.x86_64.rpm

D yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm

Download command:

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

wget http://mirrors.163.com/centos/6/os/x86_64/Packages/yum-metadata-parser-1.1.2-16.el6.x86_64.rpm

wget http://mirrors.163.com/centos/6/os/x86_64/Packages/yum-3.2.29-40.el6.centos.noarch.rpm

wget http://mirrors.163.com/centos/6/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm

[Note]: The version is not necessarily up to date

2 , uninstall RedHat Bring your own Yum

Rpm-qa | grep Yum | Xargs rpm-e--nodeps

Note: A, xargs is a common command for UNIX and UNIX-like operating systems. It does this by converting the argument list to small pieces to pass to other commands to avoid the problem of too long argument lists

b 、--nodeps forced unloading, regardless of dependencies

3 , install the downloaded CentOS of the Yum Package:

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

[note]: The last 2 need to be installed together, or there will be a dependency error

4 , to http://mirrors.163.com To download the centos6-base-163.repo file in the centos Help document and store it in in /etc/yum.repo.d

wget Http://mirrors.163.com/.help/CentOS6-Base-163.repo

5 , edit Centos6-base-163.repo file that will be one of the $releasever Change to CentOS the version number

Here are the modifications:

# Centos-base.repo

#

# The Mirror system uses the connecting IP address of the client and the

# Update status of each mirror to pick mirrors that is updated to and

# Geographically close to the client. You should the use of this for CentOS updates

# Unless you is manually picking other mirrors.

#

# If The mirrorlist= does not work for you, as a fall back to you can try the

# remarked out Baseurl= line instead.

#

#

[Base]

Name=centos-6-base-163.com

baseurl=http://mirrors.163.com/centos/6/os/$basearch/

#mirrorlist =http://mirrorlist.centos.org/?release=6&arch= $basearch &repo=os

Gpgcheck=1

Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

#released Updates

[Updates]

Name=centos-6-updates-163.com

baseurl=http://mirrors.163.com/centos/6/updates/$basearch/

#mirrorlist =http://mirrorlist.centos.org/?release=6&arch= $basearch &repo=updates

Gpgcheck=1

Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

#additional packages that could be useful

[Extras]

Name=centos-6-extras-163.com

baseurl=http://mirrors.163.com/centos/6/extras/$basearch/

#mirrorlist =http://mirrorlist.centos.org/?release=6&arch= $basearch &repo=extras

Gpgcheck=1

Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

#additional packages that extend functionality of existing packages

[Centosplus]

Name=centos-6-plus-163.com

baseurl=http://mirrors.163.com/centos/6/centosplus/$basearch/

#mirrorlist =http://mirrorlist.centos.org/?release=6&arch= $basearch &repo=centosplus

Gpgcheck=1

Enabled=0

Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

#contrib-packages by Centos Users

[Contrib]

Name=centos-6-contrib-163.com

baseurl=http://mirrors.163.com/centos/6/contrib/$basearch/

#mirrorlist =http://mirrorlist.centos.org/?release=6&arch= $basearch &repo=contrib

Gpgcheck=1

Enabled=0

Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

6 , Yum Clean All Clear Old Cache

7 , Yum Makecache Get Yum List

The following prompt indicates that the Yum change is complete:

Metadata Cache Created

About Redhat Enterprise Linux 6.4 using the CentOS 6 yum source

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.