Bug 235977
Summary: | Can't rollback more than one transaction | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Igor Jagec <igorm5> |
Component: | rpm | Assignee: | Panu Matilainen <pmatilai> |
Status: | CLOSED WONTFIX | QA Contact: | |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 6 | ||
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: | 2008-04-01 10:49:18 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
Igor Jagec
2007-04-11 06:56:56 UTC
Yes, there are likely transactions that will not rollback, dependning on how rpm-4.4.2 is configured. FWIW, you're likelier to be happier with the --rollback option in rpm-4.4.6 or later. What has been added is explicit forward and backward links between packages so that the elements in transactions that are being rolled back can be explicitly verified. The transaction id alone is insufficient to verify that all the package elements necessary to perform a rollback are present. Consider what happens when /var/spool/repackage/*.rpm files are missing. Well, I guess rpm is well configured, I don't know. I haven't had problems when I last rollbacked (I think that was on FC4). BTW none of files aren't missing in my /var/spool/repackage directory. BTW what does it mean when you said "explicit forward and backward links between packages so that the elements in transactions that are being rolled back can be explicitly verified"? Does it mean that I can choose which package to rollback? I'd like to upgrade to rpm-4.4.6 or later, but I don't know how to do that. I even tried once to compile your rpm packages, but I got lots of errors. Do you have FC6 packages? Or is there any easy way to compile your packages on FC6? Thanks Jeff. Forward and backward links as in doubly linked list. An example is perhaps easiest to explain. Here's a query on my FC7 box (running rpm-4.4.9): $ rpm -q --blink popt popt-1.10.9-0.1.i386.rpm <= popt-1.10.8-1.i386.rpm Note: --blink as in "backward link", not eye blink). The query shows that popt-1.10.9-0.1.i386.rpm upgraded popt-1.10.8-1.i386.rpm. So when using --rollback, there better be a repackaged popt-1.10.8-1.i386.rpm which contains a forward link that can be queried like rpm -qp --flink /var/spool/repackage/popt-1.10.8-1.i386.rpm Having a doubly linked list permits rpm --rollback to explicitly check that all elements necessary to perform a rollback are found. Note that the general flink/blink relations are many-to-many, not one-to-one as in a doubly linked list. So its a graph, not a list, etc etc. The goal is to explicitly verify that all elements necessary to perform a --rollback transaction are actually present. I do most of my rpm development on FC, all my versions of rpm are known to run on FC. Feel free to ask for help on <rpm-devel.duke.edu> if you'ld like to use --rollback with rpm-4.4.2+. FWIW, I'm about to actively fix a few problems with --rollback in the next couple of weeks, would love to have someone willing to actually try the bits out. I've installed rpm-4.4.8-1 on my Fedora Rawhide system (I've got lots of errors on FC6 when I tried to 'yum localinstall' them) so I would be glad if I can help you in testing that new rollback features. See ya in rpm-devel list. Cheers! I tried to rollback 2 transactions with rpm-4.4.8-1 on my Fedora Rawhide system and it works! Thanks Jeff! Here's the output: # rpm -Uvh --rollback '10 minutes ago' Rollback goal: Thu Apr 12 11:25:46 2007 (0x461dfb1a) Rollback packages (+1/-1) to Thu Apr 12 11:35:21 2007 (0x461dfd59): Preparing... ########################################### [100%] 1:freetype ########################################### [ 50%] Cleaning up repackaged packages: Removing /var/spool/repackage/freetype-2.3.4-1.fc7.athlon.rpm: Rollback packages (+1/-0) to Thu Apr 12 11:34:25 2007 (0x461dfd21): Preparing... ########################################### [100%] 1:opera ########################################### [ 50%] Cleaning up repackaged packages: Removing /var/spool/repackage/opera-9.20-20070409.6.i386.rpm: The very first think you should check is how many packages have forward/backward links. You can doo that most easily by examining: rpm -qa --blink output. Any packages that does not have a backward link is either a freshly installed package, or was not installed by a version of rpm that added backward links. The 2nd case needs to be addressed in order to verify rollback transactions. I'm in the process of writing a utility that will retrofit the necessary forward/backward links, that utility should exist within the next month. Otherwise, install a system and/or chroot with rpm-4.4.6 or later to insure that forward/backward links are populated. Comment added so that I cind this bug easily. User pnasrat's account has been closed Reassigning to owner after bugzilla made a mess, sorry about the noise... The repackage + rollback support has been removed upstream (next major version), fixing 4.4.x would be waste of time. |