Modify Yum configuration to use the 163 Source

Source: Internet
Author: User

Today, we need to use dbt2 to test the database. When installing some environment software, Sohu's source performance is very poor, and the old man's resources are not accessible. So I want to change the yum source to 163. Here is the first line of the article (http://xiaotanglinux.blog.51cto.com/694236/639423), copy it.

#! /Bin/sh
#*************************************** *************************#
# Scriptname: yum_update.sh
# Author: baoqing. guobq
# Create Date: 2011-07-21
# Modify Author:
# Modify Date: 2011-07-21
# Function:
#*************************************** ************************#
MV/etc/yum. Repos. d/rhel-debuginfo.repo/etc/yum. Repos. d/rhel-debuginfo.repo.bak
Rpm-e -- nodeps yum-security-1.1.16-13.el5
Rpm-e -- nodeps yum-metadata-parser-1.1.2-2.el5
Rpm-e -- nodeps yum
Rpm-e -- nodeps yum-updatesd-0.9-2.el5
Rpm-e -- nodeps yum-rhn-plugin-0.5.3-30.el5
Rpm-IVH http://mirrors.163.com/centos/5/ OS /x86_64/CentOS/python-iniparse-0.2.3-4.el5.noarch.rpm &&
Rpm-IVH http://mirrors.163.com/centos/5/ OS /x86_64/CentOS/yum-fastestmirror-1.1.16-14.el5.centos.1.noarch.rpm -- nodeps &&
Rpm-IVH http://mirrors.163.com/centos/5/ OS /x86_64/CentOS/yum-metadata-parser-1.1.2-3.el5.centos.x86_64.rpm &&
Rpm-IVH http://mirrors.163.com/centos/5/ OS /x86_64/CentOS/yum-3.2.22-33.el5.centos.noarch.rpm &&
CD/etc/yum. Repos. d/
Wget http://mirrors.163.com/centos/5/ OS /x86_64/RPM-GPG-KEY-CentOS-5
Rpm -- import RPM-GPG-KEY-CentOS-5 &&
Wget http://mirrors.163.com/.help/CentOS-Base-163.repo-O/etc/yum. Repos. d/CentOS-Base.repo &&
Sed-I's/\ $ releasever/5/G'/etc/yum. Repos. d/CentOS-Base.repo
# Yum update


 

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.