Bug 1414793
Summary: | numeric priority expected error seen for alternatives after chkconfig downgrade | |||
---|---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Deepu K S <dkochuka> | |
Component: | chkconfig | Assignee: | Lukáš Nykrýn <lnykryn> | |
Status: | CLOSED ERRATA | QA Contact: | Robin Hack <rhack> | |
Severity: | high | Docs Contact: | ||
Priority: | urgent | |||
Version: | 7.3 | CC: | dkochuka, fkrska, lnykryn, pandrade, rhack | |
Target Milestone: | rc | Keywords: | Reopened, ZStream | |
Target Release: | --- | |||
Hardware: | x86_64 | |||
OS: | Linux | |||
Whiteboard: | ||||
Fixed In Version: | chkconfig-1.7.3-1.el7 | Doc Type: | Bug Fix | |
Doc Text: |
Cause:
There was a feature in alternatives that changed the format of alternative state files. This change was not forward-compatible, which means that you can't use a state file modified with new alternatives with old alternatives binary.
Consequence:
This is a problem during the downgrade of alternatives. The new version changed the file and after downgrade the old version is not able to read them.
Fix:
During downgrade of new version we alter the state files to match the old format.
Result:
Working downgrade.
|
Story Points: | --- | |
Clone Of: | ||||
: | 1448444 (view as bug list) | Environment: | ||
Last Closed: | 2017-08-01 19:35:25 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: | 1448444 |
Description
Deepu K S
2017-01-19 13:07:50 UTC
This is not something that should be done in chkconfig package. The java packages that use the --family option should have a dependency for new chkconfig and when you removed them this alternative should be removed. My first idea of how to fix it, only in the newer java package would be to have a: %triggerin -- chkconfig < 1.7 followed by a scriptlet to rerun all alternatives commands, but not using the --family option (or a really ugly 's/@[^@]+@//' in the alternatives file). Do you have a different suggestion? I mean, to be able to downgrade in the same transaction java-1.8.0-openjdk and chkconfig. Ok so what we could do is to add this trigger in chkconfig spec file: diff --git a/chkconfig.spec b/chkconfig.spec index 4e08ff4..15eccca 100644 --- a/chkconfig.spec +++ b/chkconfig.spec @@ -79,6 +79,11 @@ rm -rf $RPM_BUILD_ROOT %{_sbindir}/ntsysv %{_mandir}/*/ntsysv.8* +%triggerin -- chkconfig < 1.7 +for i in /var/lib/alternatives/* ; do + sed -i -e 's/^@.*@\([0-9]*\)$/\1/' $i +done + %changelog * Wed Jun 29 2016 Lukáš Nykrýn <lnykryn> - 1.7.2-1 - alternatives: introduce --keep-missing Yep, devel_ack for the spec file change. 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, 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-2017:2164 |