Bug 999224

Summary: [upgrade] correctly detect if packages can be rollbacked
Product: Red Hat Enterprise Virtualization Manager Reporter: Chris Pelland <cpelland>
Component: ovirt-engine-setupAssignee: Yedidyah Bar David <didi>
Status: CLOSED ERRATA QA Contact: Ilanit Stein <istein>
Severity: high Docs Contact:
Priority: high    
Version: 3.2.0CC: acathrow, alonbl, bazulay, chetan, iheim, Rhev-m-bugs, scohen, yeylon
Target Milestone: ---Keywords: ZStream
Target Release: 3.2.3   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: integration
Fixed In Version: Doc Type: Enhancement
Doc Text:
Before beginning an upgrade, engine-upgrade now correctly checks if packages can be rolled back to an already-installed version, and warns users when rollback is not possible if the upgrade fails.
Story Points: ---
Clone Of: 998921 Environment:
Last Closed: 2013-09-10 19:08:11 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: 998921    
Bug Blocks:    

Comment 3 Ilanit Stein 2013-08-25 12:56:21 UTC
Verified on sf20:

flow:
1. Have two repos for 3.2.2(sf19.1) and 3.2.3(sf20)
2. Disable repo of 3.2.2 and try to upgrade sorry
3. Upgrade failed on no rollback available:
Error: Installed packages are missing from the yum repositories
Please check your yum repositories or use --no-yum-rollback
Error: Upgrade failed.
4. Enable repo of 3.2.2
5. Try to upgrade: upgrade successful, No prompt on "no rollback is available"

Comment 4 Yedidyah Bar David 2013-09-02 06:08:54 UTC
Hi Cheryn and all,

I would not like to continue the "Change Doc text game", so I'll explain in longer words what this change does, and let you decide about the phrasing for the Doc Text.

When running engine-upgrade, the script checks if there are new updated RPMs. If there are, it also checks if the existing, already-installed, packages, can still be installed from the configured yum repos. If they are not, it alerts the user, and refuses to continue, unless ran with the option '--no-yum-rollback'. All of this is done on startup, in preparation for a potential failure, and not on the failure itself - if there is a failure after updating to the new RPMs, it simply tries to downgrade.

This change fixes the above check. Without it, on certain conditions, it was possible that while checking the script would think that it will be able to downgrade to the currently-installed RPMs, while in practice it could not, and if there was a failure and it would try to downgrade, the downgrade will fail.

The current Doc Text is completely accurate if we put the parenthesis in a less natural position:

"engine-upgrade now warns users when (packages cannot be rolled back to a currently installed version if an upgrade fails)."

The natural position is:
"(engine-upgrade now warns users when packages cannot be rolled back to a currently installed version) if an upgrade fails."
and is wrong.

I am not a native English speaker and so might be wrong.

Best regards!

Comment 5 Cheryn Tan 2013-09-02 07:29:12 UTC
Thank you for your detailed corrections, Yedidyah and Alon. Spoke with Didi on IRC earlier and I think the new note now accurately describes the bug.

Comment 7 errata-xmlrpc 2013-09-10 19:08:11 UTC
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.

http://rhn.redhat.com/errata/RHSA-2013-1210.html