Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 11-12-2007, 01:41 PM   #1
LQ Newbie
Registered: Nov 2007
Posts: 3

Rep: Reputation: 0

I recently installed Fedora Core 8, everything was fine and then I decided to update the system to install more rpms. After the install, pirut crashed, and gave an error message:

Component: pirut
Summary: TBc0c9275d rpmdb open failed

Traceback (most recent call last):
File "/usr/sbin/pirut", line 476, in <module>
File "/usr/sbin/pirut", line 469, in main
pm = PackageManager(options.config, options.onlyrepo)
File "/usr/sbin/pirut", line 63, in __init__
GraphicalYumBase.__init__(self, False, config)
File "/usr/lib/python2.5/site-packages/pirut/", line 129, in __init__
File "/usr/lib/python2.5/site-packages/yum/", line 113, in doConfigSetup
File "/usr/lib/python2.5/site-packages/yum/", line 159, in _getConfig
self._conf = config.readMainConfig(startupconf)
File "/usr/lib/python2.5/site-packages/yum/", line 613, in readMainConfig
yumvars['releasever'] = _getsysver(startupconf.installroot, startupconf.distroverpkg)
File "/usr/lib/python2.5/site-packages/yum/", line 680, in _getsysver
idx = ts.dbMatch('provides', distroverpkg)
TypeError: rpmdb open failed

Local variables in innermost frame:
installroot: /
ts: <rpmUtils.transaction.TransactionWrapper instance at 0x9a37eac>
distroverpkg: redhat-release

I tried to run rpm, and rpm gave me the following error:

rpmdb: /var/lib/rpm/Packages: file size not a multiple of the pagesize
error: cannot open Packages index using db3 - Invalid argument (22)
error: cannot open Packages database in /var/lib/rpm

I thought then that rpm database became corrupted. So I tried removing the Packages database file ( renamed it to different file name ) and ran rpmdb --initdb, rpmdb --rebuilddb ( I am guessing here, and trying to avoid a re-install. )

I tried running yum clean all and got the following error:

Traceback (most recent call last):
File "/usr/bin/yum", line 29, in <module>
File "/usr/share/yum-cli/", line 85, in main
File "/usr/share/yum-cli/", line 154, in getOptionsConfig
File "/usr/lib/python2.5/site-packages/yum/", line 159, in _getConfig
self._conf = config.readMainConfig(startupconf)
File "/usr/lib/python2.5/site-packages/yum/", line 613, in readMainConfig
yumvars['releasever'] = _getsysver(startupconf.installroot, startupconf.distroverpkg)
File "/usr/lib/python2.5/site-packages/yum/", line 686, in _getsysver
hdr =

So is there hope of recovering from this, or should I go ahead and re-install ?
Old 11-12-2007, 02:00 PM   #2
LQ Newbie
Registered: Nov 2007
Posts: 3

Original Poster
Rep: Reputation: 0
I recently tried changing the code in: /usr/lib/python2.5/site-packages/yum/ (line 686)
hdr =
releasever = hdr['version']
del hdr

#hdr =
#releasever = hdr['version']
#del hdr
i.e., commented out the line that was causing the python script to crash,
and then hardcoding the releasever to be 8.
I can now run yum and did a "clean all".
This now allows me to run pirut, but the thing is, it doesn't
know about any of the installed packages. I guess the rpm Package database is unusable at this point.

So is there a way for recovering information regarding all software
packages actually installed on the system ?

Last edited by HopefulStock; 11-12-2007 at 02:11 PM. Reason: Update status since submission.


fc8, pirut, yum

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Pirut will not prompt for next cd doublejoon Red Hat 0 09-18-2007 11:50 AM
Can I remove Pirut? Chargh Fedora 1 08-11-2007 04:57 AM
Pirut or Yumex? linexnal Linux - Newbie 1 07-14-2007 08:56 PM
pirut problem eugen.serban Fedora 2 04-27-2007 03:16 AM
problem with pirut the_gripmaster Fedora 1 02-24-2007 08:28 PM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:43 PM.

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