Bug 1792874

Summary: Hide partial engine-cleanup option [RHV clone - 4.3.9]
Product: Red Hat Enterprise Virtualization Manager Reporter: RHV bug bot <rhv-bugzilla-bot>
Component: ovirt-engineAssignee: Yedidyah Bar David <didi>
Status: CLOSED ERRATA QA Contact: Petr Matyáš <pmatyas>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: bugs, didi, lsvaty, mtessun, rdlugyhe, Rhev-m-bugs, sbonazzo
Target Milestone: ovirt-4.3.9Keywords: ZStream
Target Release: 4.3.9   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ovirt-engine-4.3.9.1 Doc Type: Bug Fix
Doc Text:
Partial cleanups are not supported. Previously, when the user ran engine-cleanup, it asked whether to remove everything. If the user replied 'No' and selected specific components to remove, the result was a broken system. The current release fixes this issue by eliminating the question. When you run engine-cleanup, the only option is to remove everything.
Story Points: ---
Clone Of: 1781095 Environment:
Last Closed: 2020-04-02 16:32:17 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Integration RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1781095    
Bug Blocks:    

Description RHV bug bot 2020-01-20 09:58:17 UTC
+++ This bug is an upstream to downstream clone. The original bug is: +++
+++   bug 1781095 +++
======================================================================

Description of problem:

When running engine-cleanup, it asks:

    Do you want to remove all components? (Yes, No) [Yes]: 

If you reply No, it asks you what components to remove, but nevertheless removes also other stuff, leaving the system partially broken. We had in the past bug 1060529 for doing this, but it was eventually closed due to lack of interest.

We should somehow make it clear that 'No' is not supported. Perhaps add a warning, confirm, or require setting some env key to enable this.

(Originally by didi)

Comment 1 RHV bug bot 2020-01-20 09:58:21 UTC
Sandro, I think we want this fixed also in 4.3. What do you think?

(Originally by didi)

Comment 2 RHV bug bot 2020-01-20 09:58:24 UTC
See also bug 1773704.

(Originally by didi)

Comment 3 RHV bug bot 2020-01-20 09:58:27 UTC
I would prefer not changing too much UX especially so late in 4.3 life. Martin?

(Originally by Sandro Bonazzola)

Comment 4 RHV bug bot 2020-01-20 09:58:30 UTC
(In reply to Sandro Bonazzola from comment #3)
> I would prefer not changing too much UX especially so late in 4.3 life.
> Martin?

Well ... 4.3 will be around for quite some time. We should at least document that partial cleanup is not supported and may break your installation in the docs.

(Originally by Martin Tessun)

Comment 6 Lukas Svaty 2020-01-21 08:15:24 UTC
Looking at the patch:

'Removing only some components is not supported. If you reply '
'No, you will be prompted for components to be removed, '
'but regardless of which ones you choose, the engine will '
'not be functional. Some parts of the configuration are '
'removed unconditionally. If unsure, stop this utility, e.g. '
'by pressing Ctrl-C.'

This does not seem to me like good UX to ask for answers and potentially ignore them, can we rather disable partial cleanup questions?

Comment 7 Yedidyah Bar David 2020-01-21 08:27:47 UTC
(In reply to Lukas Svaty from comment #6)
> Looking at the patch:
> 
> 'Removing only some components is not supported. If you reply '
> 'No, you will be prompted for components to be removed, '
> 'but regardless of which ones you choose, the engine will '
> 'not be functional. Some parts of the configuration are '
> 'removed unconditionally. If unsure, stop this utility, e.g. '
> 'by pressing Ctrl-C.'
> 
> This does not seem to me like good UX to ask for answers and potentially
> ignore them, can we rather disable partial cleanup questions?

Not sure what you mean. Did you try this?

Copying my own verification steps from the patch on master, https://gerrit.ovirt.org/105847 :

Verified:

1. engine-cleanup

does not ask anymore, defaults to remove all.

2. engine-cleanup --otopi-environment=OVESETUP_REMOVE/removeAll=none:None

Prompts, warns both before the prompt and after it

3. engine-cleanup --otopi-environment=OVESETUP_REMOVE/removeAll=bool:False

Warns once and does not prompt. User should still notice, because it then prompts for the first component to remove.

See also bug 1773704 and bug 1060529.

Comment 8 Lukas Svaty 2020-01-22 08:23:47 UTC
Did not try, just checked patch, sounds good!

Comment 15 Petr Matyáš 2020-03-05 12:37:03 UTC
Verified on ovirt-engine-4.3.9.1-0.1.el7.noarch

Comment 19 errata-xmlrpc 2020-04-02 16:32:17 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.

https://access.redhat.com/errata/RHSA-2020:1308