Bug 2016070
Summary: | dnf rollback of a transaction with a group upgrade in it causes errors when trying to downgrade group | |||
---|---|---|---|---|
Product: | Red Hat Enterprise Linux 8 | Reporter: | Alena <alrodrig> | |
Component: | dnf | Assignee: | Jan Kolarik <jkolarik> | |
Status: | CLOSED ERRATA | QA Contact: | Eva Mrakova <emrakova> | |
Severity: | medium | Docs Contact: | Mariya Pershina <mpershin> | |
Priority: | medium | |||
Version: | 8.4 | CC: | james.antill, jkolarik, mbanas, mpershin, nsella, swm-qe | |
Target Milestone: | rc | Keywords: | Triaged | |
Target Release: | --- | |||
Hardware: | All | |||
OS: | Linux | |||
Whiteboard: | ||||
Fixed In Version: | dnf-4.7.0-13.el8 | Doc Type: | Bug Fix | |
Doc Text: |
.Reverting a YUM upgrade transaction is now possible for a package group or environment
Previously, the `yum history rollback` command failed when attempting to revert an upgrade transaction for a package group or an environment.
With this update, the issue has been fixed, and you can now revert the YUM upgrade transaction for a package group or environment.
|
Story Points: | --- | |
Clone Of: | ||||
: | 2122626 (view as bug list) | Environment: | ||
Last Closed: | 2023-05-16 09:06:59 UTC | Type: | Bug | |
Regression: | --- | Mount Type: | --- | |
Documentation: | --- | CRM: | ||
Verified Versions: | Category: | --- | ||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
Cloudforms Team: | --- | Target Upstream Version: | ||
Embargoed: | ||||
Bug Depends On: | ||||
Bug Blocks: | 2122626 |
Description
Alena
2021-10-20 17:57:47 UTC
We consider the bug as a valid but because the issue has limited impact (medium priority) we postpone the issue in favor of other issues. I have seen in the bug that a possible solution for undo group upgrade would be implement group downgrade functionality. But I am not sure whether is it a good idea. Let me explain what group upgrade does and then we will see what will be a good solution. DNF upgrade 1. upgrade packages defined in group 2. install packages that were not define in group at time of the last operation with the group 3. Reason change - for new packages in the group that are already installed as a dep there can be a reason change to group (not sure whether it is there or not or whether reason change is also covered by undo operation) 4. Update a definition of the group in history DB and update what is installed from the group During `undo`, first two points are already covered by rpm transaction elements and they are reverted. The point 3 is not reported by the issue therefore let's skip it. Then there is point 4. To revert point 4 100% correctly I am supposed to revert definition of the group to the state like the operation was never performed. I guess it is doable if we undo an operation that is the last that modified the group but if the situation in history db is like that: 1. group install core -x sssd (installs dnf, systemd, (sssd is define in group but excluded from transaction)) 2. group upgrade core (at that time additional package (nodejs) was defined in the group) => upgrade dnf, systemd, install nodejs 3. group upgrade core - new set of packages defined in metadata Then when I perform - `dnf history undo 2` => then it is quite difficult to detect into which state the definition of the group it should be reverted. I was checking the history DB state and after each group operation new definition of group is created, so it is easy to rollback previous state. Following PRs were queued to fix this: fix: https://github.com/rpm-software-management/dnf/pull/1844 tests: https://github.com/rpm-software-management/ci-dnf-stack/pull/1149 Cloned into RHEL9 ticket https://bugzilla.redhat.com/show_bug.cgi?id=2122626. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (dnf bug fix and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2023:2980 |