Reputation: 163
when I use yum in the shell,the error message is no module named yum, so I edit the /usr/bin/yum change the first line to another version of python, but nothing changes,and when I user different python to import yum, it brings out different error
and when i use yum ,the message is like this:
the yum is ok before i use "rpm -e --nodeps pycurl" to remove pycurl...i need some help:(
Upvotes: 8
Views: 49277
Reputation: 1
when "no module named yum" happen, you should re-install the proper python & yum rpm package manually, for instance :
rpm -i python*.rpm
rpm -i yum*.rpm
Upvotes: 0
Reputation: 31
download this rpm
python-2.4.3-46.el5_8.2.i386.rpm
python-devel-2.4.3-46.el5_8.2.i386.rpm
python-libs-2.4.3-46.el5_8.2.i386.rpm
python-tools-2.4.3-46.el5_8.2.i386.rpm
tix-8.4.0-11.fc6.i386.rpm
tix-devel-8.4.0-11.fc6.i386.rpm
tkinter-2.4.3-46.el5_8.2.i386.rpm
yum-3.2.22-39.el5.centos.noarch.rpm
http://mirror.centos.org/centos/5/os/i386/CentOS/
[root@localhost x]# ls
python-2.4.3-46.el5_8.2.i386.rpm tix-8.4.0-11.fc6.i386.rpm
python-devel-2.4.3-46.el5_8.2.i386.rpm tix-devel-8.4.0-11.fc6.i386.rpm
python-libs-2.4.3-46.el5_8.2.i386.rpm tkinter-2.4.3-46.el5_8.2.i386.rpm
python-tools-2.4.3-46.el5_8.2.i386.rpm yum-3.2.22-39.el5.centos.noarch.rpm
[root@localhost x]# rpm -Uvh --replacepkgs *.rpm
Preparing... ########################################### [100%]
1:tix ########################################### [ 13%]
2:tix-devel ########################################### [ 25%]
3:python ########################################### [ 38%]
4:tkinter ########################################### [ 50%]
5:python-devel ########################################### [ 63%]
6:python-libs ########################################### [ 75%]
7:python-tools ########################################### [ 88%]
8:yum ########################################### [100%]
[root@localhost x]# yum update
Upvotes: 3
Reputation: 527
Changing the first line of /usr/bin/yum
to the default version of python may help.
eg.change #!/usr/bin/python
to #!/usr/bin/python2.4
Upvotes: 28
Reputation: 1
You created problem for yourself by removing pycurl with --nodeps flag. To get this error above resolved, please re-install pycurl package into your system manually.
Upvotes: 0