Recently, I need to perform operations under RedHat6.1, but I have no choice but to register and cannot use yuminstall. This has caused great changes to my installation journey, so I will write an article here. First install the yum package, and then modify the configuration file. 1. Install the yum package. 1. Download the installation package # wgethttp: // tel.mirrors.163.com/centos/6/ OS /x86_64/packages/yum-3.2.2
Recently, I need to perform operations under RedHat6.1, but I have no choice but to register and cannot use yum install. This has caused a lot of changes to my installation journey, so I will write an article here.
First, install the yum package, and then modify the configuration file.
1. Install the yum package
1. Download the installation package
# Wget http://tel.mirrors.163.com/CentOS/6/ OS /x86_64/Packages/yum-3.2.27-14.el6.centos.noarch.rpm
# Wget http://tel.mirrors.163.com/centos/6/ OS /x86_64/Packages/yum-metadata-parser-1.1.2-14.1.el6.x86_64.rpm
# Wget http://tel.mirrors.163.com/centos/6/ OS /x86_64/Packages/yum-plugin-fastestmirror-1.1.26-11.el6.noarch.rpm
# Wget http://tel.mirrors.163.com/centos/6/ OS /x86_64/Packages/python-iniparse-0.3.1-2.1.el6.noarch.rpm
Note: The download path is available in the near future. If it takes a long time, the address may be changed.
2. Uninstall the original rpm package
# Rpm-qa | grep yum
# Rpm-e -- nodeps yum-* (name of the detected package)
3. install a new 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
Ii. Configuration File
1. Download CentOS6-Base-163.repo
# Cd/etc/yum. repos. d
# Mv CentOS6-Base-163.repo CentOS6-Base-163.repo.bak
# Wget http://mirrors.163.com/.help/centos.html? 1304848825/CentOS6-Base-163.repo
2. Configuration
# Vi CentOS6-Base-163.repo
Modify the following:
[Base]
Base url = http://tel.mirrors.163.com/centos/6/ OS /x86_64/
[Updates]
Base url = http://tel.mirrors.163.com/centos/6/ OS /x86_64/
[Extras]
Base url = http://tel.mirrors.163.com/centos/6/ OS /x86_64/
[Centosplus]
Base url = http://tel.mirrors.163.com/centos/6/ OS /x86_64/
[Contrib]
Base url = http://tel.mirrors.163.com/centos/6/ OS /x86_64/
3. Check
# Rpm list | grep vim
Vim-common.x86_64. 2.411-1.8.el6 @ base
Vim-enhanced.x86_64. 2.411-1.8.el6 @ base
Vim-minimal.x86_64. 2.411-1.6.el6 @ anaconda-RedHatEnterpriseLinux-201105101844.x86_64/6.1
Vim-X11.x86_64 2: 7. 2.411-1.8.el6 base
Vim-minimal.x86_64 2: 7. 2.411-1.8.el6 base
This indicates that the installation is successful. If you want to operate the yum command, run the following command to test the php installation operation:
Click y to continue. I will not go into details here. The yum installation is complete.
Iii. Problems
Error: Cannot retrieve repository metadata (repomd. xml) for repository: base. Please verify its path and try again
The solution is to modify the CentOS6-Base-163.repo configuration, because when using yum, download the installation package online cannot find the path, according to the change
For more information about RedHat, see RedHat topic page http://www.linuxidc.com/topicnews.aspx? Tid = 10