Bug 189474 - rpm can't rollback twice
rpm can't rollback twice
Status: CLOSED WONTFIX
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: rpm (Show other bugs)
4.0
All Linux
medium Severity medium
: ---
: ---
Assigned To: Panu Matilainen
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-04-20 08:24 EDT by Bastien Nocera
Modified: 2010-02-04 04:01 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-02-04 04:01:01 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Bastien Nocera 2006-04-20 08:24:48 EDT
+++ This bug was initially created as a clone of Bug #189472 +++

rpm-4.3.3-13_nonptl

rpm will fail to rollback to the original package if 2 upgrades with rollback
have been done. Same problem exists on RHEL4.

# ls -1
ksh-20040229-6.x86_64.rpm
ksh-20040229-7.x86_64.rpm
ksh-20040229-8.x86_64.rpm

# date
Thu Apr 13 16:43:44 BST 2006
# rpm -Uvh --oldpackage ksh-20040229-6.x86_64.rpm
Preparing...                ########################################### [100%]
  1:ksh                    ########################################### [100%]
# date
Thu Apr 13 16:44:07 BST 2006
# rpm -Uvh --repackage ksh-20040229-7.x86_64.rpm
Preparing...                ########################################### [100%]
Repackaging...
  1:ksh                    ########################################### [100%]
Upgrading...
  1:ksh                    ########################################### [100%]
# date
Thu Apr 13 16:44:19 BST 2006
# rpm -Uvh --repackage ksh-20040229-8.x86_64.rpm
Preparing...                ########################################### [100%]
Repackaging...
  1:ksh                    ########################################### [100%]
Upgrading...
  1:ksh                    ########################################### [100%]
# rpm -Uvh --rollback "Thu Apr 13 16:44:19 BST 2006"
Rollback packages (+1/-1) to Thu Apr 13 16:44:46 2006 (0x443e71ee):
Preparing...                ########################################### [100%]
  1:ksh                    ########################################### [ 50%]
# rpm -q ksh
ksh-20040229-7
# rpm -Uvh --rollback "Thu Apr 13 16:44:07 BST 2006"
# ls /var/spool/repackage/
total 713kB
713kB ksh-20040229-6.x86_64.rpm
# up2date --list-rollbacks install time: Thu Apr 13 16:44:17 2006   tid:1144943057
               [-] ksh-20040229-6:


# rpm -Uvh --rollback "Thu Apr 13 16:43:44 BST 2006"
# up2date --list-rollbacks
install time: Thu Apr 13 16:44:17 2006   tid:1144943057
               [-] ksh-20040229-6:
Comment 2 Bastien Nocera 2006-04-20 09:48:09 EDT
Problem doesn't exist with RPM 4.4.3 from upstream
Comment 3 James Olin Oden 2006-04-20 10:18:39 EDT
There was an issue early on in rollbacks, though I don't think I ever reported 
it, that when it would rollback it did not remove the repackaged packages it 
just installed, so if you tried to rollback again without installing any new 
packages, it would get rather confused because it would find those repackaged 
packages, but see that they were already installed and things just wouldn't 
happened the way you expected.

I fixed this in the head of rpm about a year ago, to have it loop over the 
repackaged packages it had re-installed and remove them.   I don't know if this 
is the same problem (mainly because its been so long my memory fails me), but 
it certainly smells like it.   The code was in lib/rpminstall.c::rpmRollback() 
IIRC correctly.
Comment 4 Igor Jagec 2007-04-11 01:45:44 EDT
I have almost the same problem on FC6. It can't rollback more than 1
transaction. What ever I do, it rollbacks only 1 transaction.
Comment 5 Panu Matilainen 2010-02-04 04:01:01 EST
WONTFIX for the same reason as bug 189472: rpm's rollback is not supported. Use up2date for rollbacks if you need them.

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