RedHat 6.2 Linux Modified Yum source free use of CentOS source

Source: Internet
Author: User
Tags gpg

In the absence of a CD-ROM, you need to install the package, you will use a common network of Yum source to install.

RedHat Linux is installed by default, Yum software, but because of the reason for the activation of the authentication RedHat can not directly do yum install some software, if we need to install the software under the RedHat yum, we only use the source of Yum to change to CentOS is good, Then change all the variables in the source to the actual values so that you can use Yum to install the software we need directly.

Instructions for use

1. Download the Centos6-base-163.repo file in the http://mirrors.163.com CentOS Help document and store it in/ETC/YUM.REPO.D

Centos 5 wget Http://mirrors.163.com/.help/CentOS5-Base-163.repo

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

The operation is as follows:

2, first backup/etc/yum.repos.d/centos-base.repo

3, edit the Centos6-base-163.repo file, change the $releasever to the CentOS version number, if Redhat 6.2 x86_64 as an example "baseurl=http://mirrors.163.com/ centos/6.2/os/x86_64/", this document is written in Redhat 6.2 32-bit as an example!

[Base]

Name=centos-6.2-base-163.com

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

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

Gpgcheck=1

gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6.2

#released Updates

[Updates]

Name=centos-6.2-updates-163.com

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

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

Gpgcheck=1

gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6.2

#additional packages that could be useful

[Extras]

Name=centos-6.2-extras-163.com

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

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

Gpgcheck=1

gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6.2

#additional packages that extend functionality of existing packages

[Centosplus]

Name=centos-6.2-plus-163.com

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

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

Gpgcheck=1

Enabled=0

gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6.2

#contrib-packages by Centos Users

[Contrib]

Name=centos-6.2-contrib-163.com

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

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

Gpgcheck=1

Enabled=0

gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6.2

Save after editing, run:

Yum Clean all clears the original cache

Yum Makecache get Yum list

RedHat 6.2 Linux Modified Yum source free use of CentOS 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.