- Check out what Redhat's original Yum packages are:
[Email protected] ~]# Rpm-qa|grep Yumyum-utils-1.1.31-24.el7.noarchyum-langpacks-0.4.2-3.el7.noarchyum-metadata-parser-1.1.4-10.el7.x86_ 64yum-rhn-plugin-2.0.1-4.el7.noarchpackagekit-yum-0.8.9-11.el7.x86_64yum-3.4.3-118.el7.noarch
- Try to use Xargs to remove these packages
[[email protected] ~]# rpm-qa|grep Yum|xargs rmp-e--nodepsxargs:rmp: no file or directory
[Email protected] ~]# rpm-qa|grep xargs[[email protected] ~]# rpm-e--nodeps yum-utils-1.1.31-24.el7.noarch[[email Prot Ected] ~]# rpm-e--nodeps yum-langpacks-0.4.2-3.el7.noarch[[email protected] ~]# rpm-e--nodeps yum-metadata-parser-1.1 .4-10.el7.x86_64[[email protected] ~]# rpm-e--nodeps yum-rhn-plugin-2.0.1-4.el7.noarch[[email protected] ~]# rpm-e--n Odeps Packagekit-yum-0.8.9-11.el7.x86_64[[email protected] ~]# rpm-e--nodeps rpm-e--nodeps yum-3.4.3-118.el7.noarch[ [Email protected] ~]# Rpm-qa|grep Yum
- View current operating system version
[Email protected] ~]# Cd/etc[[email protected] etc]# cat redhat-release Red Hat Enterprise Linux Server Release 7.0 (Mai Po
[[Email protected] ~] #wget http://mirrors.163.com/centos/7/os/x86_64/Packages/ yum-metadata-parser-1.1.4-10.el7.x86_64.rpm [[email protected] ~] #wget http://mirrors.163.com/centos/7/os/x86_64/ packages/yum-3.4.3-150.el7.centos.noarch.rpm [[email protected] ~] #wget http://mirrors.163.com/centos/7/os/x86_64/ packages/yum-plugin-fastestmirror-1.1.31-40.el7.noarch.rpm
- Installing CentOS during the Yum installation process found that relying on python-urlgrabber and downloading and installing it python-urlgrabber must first remove the old version
[[email protected] ~]# rpm-e--nodeps python-urlgrabber-3.10-4.el7.noarch[[email protected] ~] #wget http://mirrors.163 . com/centos/7/os/x86_64/packages/python-urlgrabber-3.10-8.el7.noarch.rpm [[email protected] ~] #rpm-IVH python-urlgrabber-3.10-8.el7.noarch.rpm [[email protected] ~] #rpm-IVH yum-metadata-parser-1.1.4-10.el7.x86_64.rpm
- The last two interdependent so put it together to execute
[[Email protected] ~] #rpm-IVH yum-3.4.3-150.el7.centos.noarch.rpm yum-plugin-fastestmirror-1.1.31-40.el7.noarch.rpm
[[Email protected] ~] #cd/etc/yum.repos.d/[[email protected] ~] #wget http://mirrors.163.com/.help/ Centos7-base-163.repo Note: You need to replace all $releasever in Centos7-base-163.repo with 7
[[Email protected] ~] #yum clean All[[email protected] ~] #yum Makecache Follow the online steps of the flower, the last step there is a "Yum update", will be all the RPM update to the latest state, For the time being, I feel no need to do it. Final Test yum install succeeded.
Replace the red Hat Enterprise Linux 7 64-bit Yum for CentOS version