Bug 1297189 - dnf history undo not possible if package is missing
Summary: dnf history undo not possible if package is missing
Keywords:
Status: CLOSED DUPLICATE of bug 1218415
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf
Version: 23
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Packaging Maintenance Team
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-01-10 11:56 UTC by František Zatloukal
Modified: 2020-01-31 20:14 UTC (History)
6 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-01-11 13:33:01 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description František Zatloukal 2016-01-10 11:56:07 UTC
Description of problem:
dnf is not able to perform history undo if some package from transaction to be undone is not installed or installed in different version.

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

How reproducible:
Always

Steps to Reproduce:
1.Do some transaction
2.Upgrade or remove a package installed by transaction in step 1
3.dnf history undo last

Actual results:
Altered package blocks undo operation

Expected results:
dnf should be able to perform incomplete undo operation.

Comment 1 Honza Silhan 2016-01-11 13:33:01 UTC
you can workaround this problem by setting `keepcache=1` in `/etc/dnf/dnf.conf`

*** This bug has been marked as a duplicate of bug 1218415 ***

Comment 2 Robin A. Meade 2020-01-31 20:14:45 UTC
It is not true that setting `keepcache=1` in `/etc/dnf/dnf.conf` is a solution to this problem.

See:

Create internal repo from packages in cache
https://bugzilla.redhat.com/show_bug.cgi?id=1397174
(my original title was: dnf history undo doesn't work even with keepcache=1)

`dnf history undo last` doesn't work after update (keepcache=True)
https://bugzilla.redhat.com/show_bug.cgi?id=1677840

The solution offered is to use the `local` plugin.

However, if you use both keepcach=1 and the local plugin, your disk space devoted to holding old packages doubles!

This problem would go away if the practice of deleting old rpms from the mirrors ceased.

But that idea was rejected:

Don't replace packages in Fedora Updates repository - keep them all
https://bugzilla.redhat.com/show_bug.cgi?id=1218415#c31

"if we kept every single rpm pushed out in the updates repos over the life of a release the mirrors would revolt and we would not be able to ship anything."

So, instead of mirrors using their disk space to keep old packages, users are expected to configure the `local` plugin and use their own disk space, so that dnf's undo and rollback functionality will work as documented.


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