Results 1 to 5 of 5
Hi all,
I've tried to work with yum. but if I "yum install .." enter, then i get this error :
PHP Code:
error : no dbpath has been set
error : cannot open Packages database in /%{ ...
- 07-22-2009 #1Just Joined!
- Join Date
- Jul 2009
- Posts
- 5
I have a problem with Yum - Centos
Hi all,
I've tried to work with yum. but if I "yum install .." enter, then i get this error :
What do i have to do ?PHP Code:error: no dbpath has been set
error: cannot open Packages database in /%{_dbpath}
Traceback (most recent call last):
File "/usr/bin/yum", line 30, in ?
yummain.main(sys.argv[1:])
File "/usr/share/yum/yummain.py", line 163, in main
(log, errorlog, filelog, conf, cmds) = parseCmdArgs(args)
File "/usr/share/yum/yummain.py", line 75, in parseCmdArgs
conf=yumconf(configfile=yumconffile)
File "/usr/share/yum/config.py", line 155, in __init__
self.yumvar['releasever'] = self._getsysver()
File "/usr/share/yum/config.py", line 285, in _getsysver
idx = ts.dbMatch('provides', self.distroverpkg)
TypeError: rpmdb open failed
I've tried this too, but it hasn't fixed
PHP Code:rm -rf /var/lib/rpm/__db*
rpm --rebuilddb
- 07-22-2009 #2Just Joined!
- Join Date
- Jul 2009
- Posts
- 5
Hi all,
Have you no idea ?
- 07-22-2009 #3Linux Guru
- Join Date
- Apr 2009
- Location
- I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
- Posts
- 8,974
Interesting. Which version of CentOS are you running, and how did you install it? Also, did yum ever work for you? From your error messages it seems that something has nuked your yum configuration information. What do you see in /etc/yum and /etc/yum.repos.d? FYI, they are directories.
Sometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!
- 07-22-2009 #4Just Joined!
- Join Date
- Jul 2009
- Posts
- 5
- 07-22-2009 #5Linux Guru
- Join Date
- Apr 2009
- Location
- I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
- Posts
- 8,974
Yum is a python script. Did you do anything that might have messed up your python installation recently? Here is the sum total of the yum executable:
In any case, the traceback from python indicates where the error is coming from - /usr/share/yum/config.pyCode:#!/usr/bin/python import sys try: import yum except ImportError: print >> sys.stderr, """\ There was a problem importing one of the Python modules required to run yum. The error leading to this problem was: %s 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: %s If you cannot solve this problem yourself, please go to the yum faq at: http://wiki.linux.duke.edu/YumFaq """ % (sys.exc_value, sys.version) sys.exit(1) sys.path.insert(0, '/usr/share/yum-cli') try: import yummain yummain.user_main(sys.argv[1:], exit_code=True) except KeyboardInterrupt, e: print >> sys.stderr, "\n\nExiting on user cancel." sys.exit(1)
Sorry, but I don't have the time to debug this for you further than this. The only conclusion I can come to is that something has munged your yum/python configuration.Sometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!


Reply With Quote
