Bug 134388 - Upgrades between same nevr and differing content leave files around
Summary: Upgrades between same nevr and differing content leave files around
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: rpm
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Paul Nasrat
QA Contact: Mike McLean
URL: http://ep09.pld-linux.org/~mmazur/rpm...
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-10-01 21:47 UTC by Mariusz Mazur
Modified: 2007-11-30 22:10 UTC (History)
5 users (show)

(edit)
Clone Of:
(edit)
Last Closed: 2005-10-22 21:05:33 UTC


Attachments (Terms of Use)
rpm-owl-compare-digest.diff (4.17 KB, patch)
2005-10-18 15:23 UTC, Dmitry V. Levin
no flags Details | Diff

Description Mariusz Mazur 2004-10-01 21:47:58 UTC
From Bugzilla Helper: 
User-Agent: Mozilla/5.0 (compatible; Konqueror/3.3; Linux 2.6.7; X11; i686; pl) 
(KHTML, like Gecko) 
 
Description of problem: 
If I have to packages with same nevr, but package A has 'oldfile' and package 
B has 'newfile', and I upgrade (-U --force) from package A to package B, than 
'oldfile' doesn't get removed but there's no info of it's presence in rpm's 
database. 
 
Version-Release number of selected component (if applicable): 
 
 
How reproducible: 
Always 
 
Steps to Reproduce: 
 1. Download two packages from http://ep09.pld-linux.org/~mmazur/rpm-bug/ 
2. rpm -i sometestpkg-old.rpm 
3. rpm -U --force sometestpkg-new.rpm 
4. ls /bin/oldfile 
5. rpm -qf /bin/oldfile 
 
 
Actual Results:  'oldfile' is there but rpm doesn't know about it. 
 
Expected Results:  'oldfile' should get removed. 
 
Additional info:

Comment 1 Michael Schröder 2005-01-05 16:03:17 UTC
It's because rpm only does a "refresh" operation if the nevr is the 
same, i.e. only the installation phase is done and no erase phase at 
all. (There's a hack in rpm that removes the old header from the 
database.) 

Comment 2 Dmitry V. Levin 2005-10-16 23:24:19 UTC
Most non-intrusive approach to implement the 

Comment 3 Dmitry V. Levin 2005-10-16 23:25:58 UTC
Most non-intrusive approach to implement the fix is to add one more key to
distinguish packages with same NEVR.  What do you think about BUILDTIME?

Comment 4 Dmitry V. Levin 2005-10-17 21:45:47 UTC
And if BUILDTIME is not sufficient, then SHA1HEADER should be enough.

Comment 5 Dmitry V. Levin 2005-10-18 15:23:11 UTC
Created attachment 120124 [details]
rpm-owl-compare-digest.diff

Proposed implementation, backported from the patch I made for Owl's rpm-4.2.

Comment 6 Jeff Johnson 2005-10-22 21:05:33 UTC
Fixed in rpm-4.4.3-0.18. Thanks for the patch.


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