使用yum 安装软件 时 报
There was a problem importing one of the Python modules
required to run yum. The error leading to this problem was:
No module named yum
Please install a package which provides this module, or
verify that the module is installed correctly.
It's possible that the above module doesn't match the
current version of Python, which is:
2.7.12 (default, Oct 27 2020, 16:11:03)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-39)]
If you cannot solve this problem yourself, please go to
the yum faq at:
http://yum.baseurl.org/wiki/Faq
1、解决办法 查看 查看yum 脚本
vim /usr/bin/yum
当前yum 使用 的python 脚本
替换脚本
查看当前系统中有哪些python可供选择
还不行,只能重装yum 啦
2、重装yum
参看这位大佬写的就可以