Bug 505280
Summary: | package-cleanup --cleandupes doesn't work correctly | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Gerhard Wiesinger <redhat> |
Component: | yum-utils | Assignee: | Seth Vidal <skvidal> |
Status: | CLOSED UPSTREAM | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | medium | Docs Contact: | |
Priority: | low | ||
Version: | rawhide | CC: | awilliam, bugs.michael, ffesti, james.antill, kyrian, pmatilai, tim.lauridsen |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2009-10-12 16:00:21 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Gerhard Wiesinger
2009-06-11 10:33:20 UTC
* Yum (or RPM to be accurate) didn't remove the old packages, because your transaction which you had started from Yum Shell was interrupted with a fatal exception. Mind you, it didn't find the additional packages in $pwd, and yum-complete-transaction couldn't continue either. * Does "package-cleanup --dupes" list the remaining duplicates? If it does, what do you get for "rpm --erase --justdb --noscripts ant-javadoc-1.7.1-7.2.fc10.x86_64"? * Ad1) Yes, that's true. As discussed privately transaction has been aborted. But as far as I remember I've seen the behavior on correct updates that there were some dupes left. (Although I don't have hard facts for that issue). * Ad2) package-cleanup --dupes => No package output Then it's obvious that it doesn't remove any. :) If after rm -f /var/lib/rpm/__db.* rpm -vv --rebuilddb nothing changes, a closer look at how package-cleanup finds dupes will be needed. Independently, you could still clean them yourself as in the example in comment 1. After rebuild of the rpm database, it finds some more packages (58), but still not all. Seems the yum algorithms is broken. It thing the --justdb leaves garbage: "rpm --erase --justdb --noscripts ant-javadoc-1.7.1-7.2.fc10.x86_64"? e.g. rpm -ql bash-3.2-30.fc10.x86_64 > file1.txt rpm -ql bash-4.0-6.fc11.x86_64 > file2.txt diff -u file1.txt file2.txt => There is a difference => garbage would be left open. --justdb is not mandatory. e.g. erasing the older bash pkg doesn't remove files which also belong into the new bash pkg Having just been through a nightmare, I think this system should also detect duplicate packages with different architectures. After having had FC11 fail to recognise insertion of a CD, I tried upgrading, that failed, and downgrading the relevant packages failed too. Thereafter realising my system had a 64-bit chip, but for various reasons (most notably lack of a 64-bit flash plugin) was still running 32-bit Fedora, I tried swapping it to x86_64 architecture. The installer seemed to insist I wipe my partitions and start again (a sensible approach, I agree, but not one I could stomach at the time), but it left me no way to clear duplicate packages, or swap packages from one architecture to another, as "rpm -Fvh" would not 'freshen' packages to a different architecture (even if it's the current one and the old package is not!) and indeed yum would do the same, I was forced to do this manually, and using "rpm -Uvh" or similar, thus resulting in lots of duplicate packages with different architectures and no realistic way apart from package-cleanup to sort it out. package-cleanup, obviously, did not help, so it would be good if it could, please. committed a patch upstream to package-cleanup to add a --noscripts option for --cleandupes that will remove older duplicates w/o running the scriptlets. this should solve the above problem. |