LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 09-05-2006, 10:56 AM   #1
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Rep: Reputation: 15
Python problems with FC5


I have been getting error messages when I use the command
yum-y update.

Quote:
[root@usaidwot saywot]# yum -y update
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
'import site' failed; use -v for traceback
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.4.1 (#2, Nov 11 2005, 12:26:27)
[GCC 4.0.1 (4.0.1-5mdk for Mandriva Linux release 2006.0)]
which is odd as I seem to have installed a Mandriva Linux component and this is FC5.

Also when I download and have run rpm -ivh Python-2.4.x.x.x.FC5.i386.rpm
I get you have already installed this

and the same applies to installing YUM

How can I get rid of the Mandriva components and replace with the appropriate Fedora Core equivalents
 
Old 09-05-2006, 09:53 PM   #2
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
Here's the message I get when I try and install a later (FC5) version of Python

Quote:
[root@usaidwot saywot]# rpm -ivh python-2.4.3-8.FC5.i386.rpm
Preparing... ########################################### [100%]
package python-2.4.3-8.FC5 is already installed
 
Old 09-05-2006, 09:58 PM   #3
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
Thumbs down

and, of course, the same applies to YUM

Quote:
[root@usaidwot saywot]# rpm -ivh yum-2.6.1-0.fc5.noarch.rpm
Preparing... ########################################### [100%]
package yum-2.6.1-0.fc5 is already installed
So while I can blame myself for doing things to my computer waaaay past my bedtime I would have thought a simple

Quote:
rpm -e [package-name]
should remove all of python - but NO !

Last edited by saywot; 09-06-2006 at 05:46 AM.
 
Old 09-06-2006, 05:50 AM   #4
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
Latest news

Quote:
# rpm -e python2.4.1
error: package python2.4.1 is not installed
# rpm -e Python2.4.1
error: package Python2.4.1 is not installed
#
But when I do (as the super user)
rpm -ivh python-2.4.3-8.FC5.i386.rpm

Quote:
# rpm -ivh python-2.4.3-8.FC5.i386.rpm
Preparing... ########################################### [100%]
package python-2.4.3-8.FC5 is already installed
So V 2.4.1 is not installed
but V 2.4.3 is

YUM needs python to work and the command I use to update all the packages is
yum -y update
so when I use this (again as su) I get


Quote:
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
'import site' failed; use -v for traceback
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.4.1 (#2, Nov 11 2005, 12:26:27)
[GCC 4.0.1 (4.0.1-5mdk for Mandriva Linux release 2006.0)]

So that which doesn't exist does indeed but that which shouldn't does
The package I'm trying to remove isn't there
the package I'm trying to install is already installed

Last edited by saywot; 09-06-2006 at 05:51 AM.
 
Old 09-07-2006, 01:31 AM   #5
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
I'm starting to think that my only solution is to do a complete re-install of Core 5.

I have looked through all of /etc and found nothing called (or resembling) python 2.4.1 there
have looked through /usr with the same result

Where else should I be looking as (apart from this) I have the machine running everything I wanted above my expectations ?

 
Old 09-07-2006, 04:04 AM   #6
decrepit
Member
 
Registered: May 2006
Distribution: Ubuntu10.04, < fedora12
Posts: 347

Rep: Reputation: 34
Have you tried yum clean all
It's a long shot, but may help, before you try a reinstall.
 
Old 09-07-2006, 09:14 AM   #7
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
Well if

yum -y update

returns an error message of "Yum is not installed"

Quote:
yum clean all
will probably return the same message won't it ?

something like


Quote:
# yum clean all
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
'import site' failed; use -v for traceback
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.4.1 (#2, Nov 11 2005, 12:26:27)
[GCC 4.0.1 (4.0.1-5mdk for Mandriva Linux release 2006.0)]
 
Old 09-07-2006, 10:19 AM   #8
decrepit
Member
 
Registered: May 2006
Distribution: Ubuntu10.04, < fedora12
Posts: 347

Rep: Reputation: 34
woops, sorry didn't mean to increase your frustration, guess i should have read a bit more carefully.
 
Old 09-11-2006, 01:51 AM   #9
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
Latest --

#updatedb --(wait a few minutes)
#locate python

this gives me the location of the file I don't want
remove the file
replace with Python 2.4.3 FC5
installs like a charm !! - (briefly happy and hopeful)

This all started because I was unable to update anything because of the incorrect version of Python now this has been solved I expected the problem to have cleared up

But

Quote:
]# yum -y update
There was a problem importing one of the Python modules
required to run yum. The error leading to this problem was:

No module named rpm

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.4.3 (#1, Jun 13 2006, 11:46:08)
[GCC 4.1.1 20060525 (Red Hat 4.1.1-1)]
So now rpm has gone and I'm no better off (except I do have python 2.4.3 FC5 installed)
 
Old 09-11-2006, 03:56 AM   #10
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
You hosed python, yum and rpm by installing Mandriva packages on Fedora Core. Whilst Mandriva and Fedora Core share the same basic package management system, their packages are not compatible. Since rpm is hosed and there is not way to reinstall yum, python and rpm a complete OS reinstall maybe necessary.
 
Old 09-11-2006, 10:41 AM   #11
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
Quote:
]# rpm -ivh rpm-4.4.2-15.2.i386.rpm
Preparing... ########################################### [100%]
package rpm-4.4.2-15.2 is already installed
Which leads me ...
with the greatest reluctance to accept this as sage advice

Quote:
You hosed python, yum and rpm by installing Mandriva packages on Fedora Core. Whilst Mandriva and Fedora Core share the same basic package management system, their packages are not compatible. Since rpm is hosed and there is not way to reinstall yum, python and rpm a complete OS reinstall maybe necessary.

but
Since I have re-installed the correct python package, the correct yum package what's the impediment to fixing rpm ?
 
Old 09-11-2006, 04:22 PM   #12
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Since rpm seems to be somehow working, try doing
Code:
# rpm -Uvh --nodeps --force rpm-4.4.2-15.2.i386.rpm
Make sure you use the latest rpm available from the updates section in the Fedora Core mirrors. Also make sure your reinstall the rpm-python package.
 
Old 09-11-2006, 09:10 PM   #13
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
This looked good so I tried it

Quote:
# rpm -Uvh --nodeps --force rpm-4.4.2-15.2.i386.rpm
Preparing... ########################################### [100%]
1:rpm ########################################### [100%]
# yum -y update
There was a problem importing one of the Python modules
required to run yum. The error leading to this problem was:

No module named rpm

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.4.3 (#1, Jun 13 2006, 11:46:08)
[GCC 4.1.1 20060525 (Red Hat 4.1.1-1)]
OK so rpm forced itself

Now to the latest python from the fedora core repository
so python forced itself

But to no avail the report is still

"no module named rpm"

So I'm still at a loss
 
Old 09-12-2006, 03:12 AM   #14
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Did you read the last bit of the post that talks about rpm-python?
 
Old 09-12-2006, 09:54 PM   #15
saywot
Member
 
Registered: Apr 2006
Location: Australia
Distribution: Fedora 13 + Ubuntu
Posts: 49

Original Poster
Rep: Reputation: 15
Quote:
# rpm -ivh python-2.3.4-13.1.i386.rpm
error: Failed dependencies:
libdb-4.2.so is needed by python-2.3.4-13.1.i386
libreadline.so.4 is needed by python-2.3.4-13.1.i386
So should I install the dependencies OR do the "nodeps" thing
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
problems with Python dratix Ubuntu 3 06-15-2005 09:33 PM
problems with python: what else is new??? mrchaos Linux - Software 4 05-13-2005 02:43 PM
Python ftplib problems p-static Programming 0 08-08-2004 10:42 AM
Problems with Python 2-3.3 during ./configure mindfestival Linux - Newbie 1 03-30-2004 06:44 AM
GNUCash/Python Problems odavis Linux - General 1 02-01-2002 01:48 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 02:44 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration