-bash: /usr/bin/yum: /usr/bin/python: bad interpreter: No such file or directory


造成的原因是之前对python进行了一个备份,当python出现多版本也会出现这个情况

[root@localhost bin]# yum
-bash: /usr/bin/yum: /usr/bin/python: bad interpreter: No such file or directory
[root@localhost bin]# whereis python
python: /usr/bin/python2.6 /usr/bin/python.bak /usr/lib/python2.6 /usr/lib64/python2.6 /usr/include/python2.6 /usr/share/man/man1/python.1.gz
[root@localhost bin]# whereis yum
yum: /usr/bin/yum /etc/yum /etc/yum.conf /usr/share/man/man8/yum.8.gz
[root@localhost bin]# mv python.bak python
[root@localhost bin]# whereis python
python: /usr/bin/python2.6 /usr/bin/python /usr/lib/python2.6 /usr/lib64/python2.6 /usr/include/python2.6 /usr/share/man/man1/python.1.gz
[root@localhost bin]# yum
Loaded plugins: fastestmirror, refresh-packagekit, security
You need to give some command
Usage: yum [options] COMMAND

List of Commands:

check          Check for problems in the rpmdb
check-update   Check for available package updates
clean          Remove cached data
deplist        List a package's dependencies
distribution-synchronization Synchronize installed packages to the latest available versions
downgrade      downgrade a package
erase          Remove a package or packages from your system

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM