Bug 1199081

Summary: preupgrade script should detect whether proper upgrade target
Product: Red Hat Enterprise Linux 6 Reporter: Petr Hracek <phracek>
Component: preupgrade-assistant-contentsAssignee: Frantisek Kluknavsky <fkluknav>
Status: CLOSED NOTABUG QA Contact: Alois Mahdal <amahdal>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.7CC: ovasik, phracek, ttomecek
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-03-05 12:56:34 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:

Description Petr Hracek 2015-03-05 12:55:11 UTC
Description of problem:
Before alone upgrade done be redhat-upgrade-tool. preupgrade script should detect if redhat-upgrade-tool is executed with proper target version.
If not then upgrade should fail.

Question is if this can be done directly in redhat-upgrade-tool so that we will save time before downloading packages.
I think that redhat-upgrade-tool can detect if version file (generated by preupgrade-assistant-contents) exits and then compare them with command line arguments.
Use cases:

1) If version file doesn't exist then upgrade will stop and doesn't continue.
2) If version file contains version 7.1 then redhat-upgrade-tool should have arguments with 7.1 version too and upgrade continues.
3) If version file contains version 7.1 and redhat-upgrade-tool arguments are  with 7.0 version then it have to stop as well.
4) If version file contains version 7.0 and redhat-upgrade-tool contains 7.1 then upgrade won't be possible too.

I think that this is a good part for redhat-upgrade-tool.

What do you think?

Comment 1 Petr Hracek 2015-03-05 12:56:34 UTC
I will generate a new bug.
Huge typos from.