Bug 573039 - RFE: Yum could handle broken rpmdb's better (tracebacks with "not found pkgtup")
Summary: RFE: Yum could handle broken rpmdb's better (tracebacks with "not found pkgtup")
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: yum
Version: 11
Hardware: i386
OS: Linux
low
medium
Target Milestone: ---
Assignee: Seth Vidal
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-03-12 16:46 UTC by RexM
Modified: 2014-01-21 23:13 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-04-28 13:51:53 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description RexM 2010-03-12 16:46:25 UTC
Description of problem:
Go through process to run a periodic yum update, to keep system current. 
1st I run: # yum -yv clean all
Loaded plugins: refresh-packagekit
Cleaning up Everything


Then run: 
 yum -yv update
Loaded plugins: refresh-packagekit
fedora/metalink                                          |  19 kB     00:00     
fedora                                                   | 3.8 kB     00:00     
fedora/primary_db                                        | 8.4 MB     00:14     
updates/metalink                                         |  17 kB     00:00     
updates                                                  | 4.4 kB     00:00     
updates/primary_db                                       | 5.4 MB     00:02     
Setting up Update Process

YUM dies at this point: 

Error: Package tuple (u'kde-settings', 'noarch', '0', '4.2', '16.1') could not be found in rpmdb


Version-Release number of selected component (if applicable):

FC11 

How reproducible:

it will always occur now. Change occured to repo within the last month.. 

Steps to Reproduce:
1.yum -yv clean all
2.yum -yv update
3.
  
Actual results:
Error: Package tuple (u'kde-settings', 'noarch', '0', '4.2', '16.1') could not be found in rpmdb

Expected results:

Successful connection to REPO and update or notification of NO updates available. 



Additional info:

yum -v
Not loading "blacklist" plugin, as it is disabled
Loading "refresh-packagekit" plugin
Not loading "whiteout" plugin, as it is disabled
Config time: 0.040
Yum Version: 3.2.24

Comment 1 James Antill 2010-03-12 19:00:32 UTC
Can you provide the full output?

One "interesting" thing is that the updateinfo for F11 updates has:

http://download.fedoraproject.org/pub/fedora/linux/updates/1/i386/kde-settings-4.2-16.1.noarch.rpm

http://download.fedoraproject.org/pub/fedora/linux/updates/1/i386/kde-settings-4.2-17.noarch.rpm

...but you aren't running update-minimal according to the above.

 Also would it be possible for you to try yum from rawhide?

Comment 2 RexM 2010-03-12 19:58:39 UTC
James 
Full output of the yum update is shown.. 

I am not sure what you mean running yum from Rawhide or "update-minimal"?  

Looks as if /var/log/yum.log has last good run Feb 23. 

Tried running yum to update the package:
 yum -vy update kde-settings*
Loaded plugins: refresh-packagekit
Setting up Update Process
Traceback (most recent call last):
  File "/usr/bin/yum", line 29, in <module>
    yummain.user_main(sys.argv[1:], exit_code=True)
  File "/usr/share/yum-cli/yummain.py", line 311, in user_main
    errcode = main(args)
  File "/usr/share/yum-cli/yummain.py", line 180, in main
    result, resultmsgs = base.doCommands()
  File "/usr/share/yum-cli/cli.py", line 353, in doCommands
    return self.yum_cli_commands[self.basecmd].doCommand(self, self.basecmd, self.extcmds)
  File "/usr/share/yum-cli/yumcommands.py", line 201, in doCommand
    return base.updatePkgs(extcmds)
  File "/usr/share/yum-cli/cli.py", line 636, in updatePkgs
    if not self.update(pattern=arg):
  File "/usr/lib/python2.6/site-packages/yum/__init__.py", line 2959, in update
    (e, m, u) = self.rpmdb.matchPackageNames([kwargs['pattern']])
  File "/usr/lib/python2.6/site-packages/yum/packageSack.py", line 282, in matchPackageNames
    matched.append(self.searchPkgTuple(pkgtup)[0])
IndexError: list index out of range

Comment 3 James Antill 2010-03-12 21:41:27 UTC
 Weird, that makes no sense.

 You could try running: package-cleanup --problems
                        package-cleanup --dupes
                        rpm -Va --nofiles --nodigest

Comment 4 RexM 2010-03-15 13:31:28 UTC
James


package-cleanup --problems
package-cleanup --dupes

Came with this output: 
Setting up yum
Loaded plugins: refresh-packagekit
Traceback (most recent call last):
  File "/usr/bin/package-cleanup", line 499, in <module>
    main()
  File "/usr/bin/package-cleanup", line 480, in main
    printDupes(my, opts.qf)
  File "/usr/bin/package-cleanup", line 185, in printDupes
    po = my.getInstalledPackageObject((n,a,e,v,r))
  File "/usr/lib/python2.6/site-packages/yum/__init__.py", line 2354, in getInstalledPackageObject
    raise Errors.RpmDBError, _('Package tuple %s could not be found in rpmdb') % str(pkgtup)
yum.Errors.RpmDBError: Package tuple ('coreutils', 'i586', '0', '7.2', '7.fc11') could not be found in rpmdb


rpm -Va --nofiles --nodigest 

Showed a bunch of unsatisfied dependencies, but it appeared to complete

Comment 5 James Antill 2010-03-15 15:44:31 UTC
It's pretyt much guaranteed that if you fix your rpmdb, by installing the missing deps. ... yum will work again.

Comment 6 RexM 2010-03-17 13:26:24 UTC
Please explain " if you fix rpmdb ..... " ? 

I am not sure what to fix or how..

Comment 7 James Antill 2010-03-17 15:36:52 UTC
> > rpm -Va --nofiles --nodigest 
> > Showed a bunch of unsatisfied dependencies, but it appeared to complete  
> Please explain " if you fix rpmdb ..... "

By "fix the rpmdb" I mean you need to fix all the unsatisfied dependencies, so that the above command completes without saying anything.

Comment 8 RexM 2010-03-17 18:21:03 UTC
Line by line? oy!! 

Thanks James, is take a closer look and report back.. Thanks.

Comment 9 Bug Zapper 2010-04-28 11:57:26 UTC
This message is a reminder that Fedora 11 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 11.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '11'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 11's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 11 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 10 James Antill 2010-04-28 13:51:53 UTC
 We work a quite a bit harder now, and have a "yum check" command ... which we even partially run at times (to make it more obvious what the problem is to the user).
 We probably aren't perfect, but it's def. better so closing this.


Note You need to log in before you can comment on or make changes to this bug.