Bug 1118360

Summary: engine-cleanup should refuse removing a different version
Product: [Retired] oVirt Reporter: Yedidyah Bar David <didi>
Component: ovirt-engine-installerAssignee: Simone Tiraboschi <stirabos>
Status: CLOSED CURRENTRELEASE QA Contact: Pavel Stehlik <pstehlik>
Severity: high Docs Contact:
Priority: high    
Version: 3.5CC: bugs, gklein, iheim, info, mtayer, ogofen, rbalakri, sbonazzo, stirabos, yeylon
Target Milestone: ---Keywords: AutomationBlocker
Target Release: 3.5.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: integration
Fixed In Version: ovirt-3.5.0_rc1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-10-17 12:28:32 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 Yedidyah Bar David 2014-07-10 14:03:52 UTC
Description of problem:

Currently, it's possible to:
1. install and setup version X
2. yum update ovirt-engine-setup
3. engine-cleanup

This might fail in unexpected/unintended ways, or worse, not fail but cause unexpected consequences.

We have code (currently in packaging/setup/plugins/ovirt-engine-remove/base/core/misc.py) that was intended to (also) prevent that with 3.2->3.3, but it won't prevent 3.3+ against later versions.

Comment 1 Yedidyah Bar David 2014-08-04 14:01:19 UTC
This fails on master with:

[ ERROR ] Cleanup utility and installed version mismatch
          Please use a version of cleanup utility that matches the engine installed version (now engine-cleanup 3.6.0, engine 3.6.0_master)
[ ERROR ] Failed to execute stage 'Environment setup': Cleanup utility version mismatch

Not moving the bug back because this probably affects only master (and the bug is on 3.5).

Worked around by setting:
RPM_VERSION = '3.6.0_master'
in /usr/share/ovirt-engine/setup/ovirt_engine_setup/config.py .

Simone - please have a look. Thanks!

Comment 2 Simone Tiraboschi 2014-08-05 13:13:18 UTC
Thanks Didi,
I added an additional patch to check just just the x.y.z part of version number ignoring any suffix (_pre, _master, _custom...)

Comment 3 Yedidyah Bar David 2014-08-10 09:35:31 UTC
*** Bug 1128413 has been marked as a duplicate of this bug. ***

Comment 4 Yedidyah Bar David 2014-08-17 12:37:51 UTC
*** Bug 1130137 has been marked as a duplicate of this bug. ***

Comment 5 Mooli Tayer 2014-10-02 11:09:49 UTC
Possibly an implication of the bug  described here?

Trying to run engine cleanup I get:
"***L:ERROR Internal error: No module named paramiko"

Only after "yum install python-paramiko"
I get "Cleanup utility and installed version mismatch"

Comment 6 Simone Tiraboschi 2014-10-02 11:25:39 UTC
No,
paramiko was required just from here but it's a different feature and the dependencies look ok.
http://gerrit.ovirt.org/#/c/33231/


Can you please post the list of rpm you are using?

Comment 7 Sandro Bonazzola 2014-10-17 12:28:32 UTC
oVirt 3.5 has been released and should include the fix for this issue.

Comment 8 Mooli Tayer 2014-10-20 12:18:34 UTC
Missed this by mistake,

I do not have the relevant env anymore.
Please ignore if this does not reproduce.