CentOS fix yum install latest tools
1. Delete the built-in yum
# Rpm-aq | grep yum | xargs rpm-e -- nodeps
2. Extract the rpm package from the CentOS system image. Here we use centos6.3 _ x64 as an example.
The following rpm package is extracted from the Packages directory of the image package:
3. Install the rpm package
Note: I put all extracted packages on my VPS for you to download.
# 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-30.el6.centos.noarch.rpm yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm
Note: This step must be installed together, or the following error may occur:
----------------------------------------------
# Rpm-ivh yum-3.2.29-30.el6.centos.noarch.rpm
Warning: yum-3.2.29-30.el6.centos.noarch.rpm: Header V3 DSA signature: NOKEY, key ID e8562897
Error: Failed dependencies:
Yum-fastestmirror is needed by yum-3.2.29-30.el6.centos.noarch
# Rpm-ivh yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm
Warning: yum-plugin-fastestmirror-1.1.30-14.el6.noarch.rpm: Header V3 DSA signature: NOKEY, key ID e8562897
Error: Failed dependencies:
Yum> = 3.0 is needed by yum-plugin-fastestmirror-1.1.30-14.el6.noarch
-----------------------------------------------
# Rpm-ivh PackageKit-yum-0.5.8-20.el6.x86_64.rpm
# Rpm-ivh PackageKit-yum-plugin-0.5.8-20.el6.x86_64.rpm
4. Download the configuration Source:
# Cd/etc/yum. repos. d/
# Wgethttp: // docs.linuxtone.org/soft/lemp/CentOS-Base.repo
5. Test
# Yum version
---------------------------------------------
Loaded plugins: fastestmirror, refresh-packagekit
Warning: RPMDB altered outside of yum.
Installed: 6/x86_64 1285: a2a18f0b8c3ca036a361579f6b22014aadfd680e
Group-Installed: yum 14: 45bb88c01e2108ba8fe7ac401a053cfd42bda739
Version
----------------------------------------------
Installed successfully