Bug 1826875 - HE deployment gets into an endless loop when the memory is not sufficient and you choose not to continue.
Summary: HE deployment gets into an endless loop when the memory is not sufficient and...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-hosted-engine-setup
Classification: oVirt
Component: General
Version: 2.4.4
Hardware: Unspecified
OS: Unspecified
medium
unspecified
Target Milestone: ovirt-4.4.2
: 2.4.6
Assignee: Asaf Rachmani
QA Contact: Nikolai Sednev
URL:
Whiteboard:
Depends On: 1854324
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-04-22 17:00 UTC by Kobi Hakimi
Modified: 2020-09-18 09:11 UTC (History)
5 users (show)

Fixed In Version: ovirt-hosted-engine-setup-2.4.6-1.el8ev
Clone Of:
Environment:
Last Closed: 2020-09-18 07:12:49 UTC
oVirt Team: Integration
Embargoed:
sbonazzo: ovirt-4.4?
mtessun: planning_ack+
sbonazzo: devel_ack+
mavital: testing_ack+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 109895 0 master MERGED setup: Change the default value to 'Abort' for insufficient memory 2020-09-15 13:46:23 UTC

Description Kobi Hakimi 2020-04-22 17:00:08 UTC
Description of problem:
HE deployment gets into an endless loop when the memory is not sufficient and you choose not to continue.

Version-Release number of selected component (if applicable):
ovirt-hosted-engine-setup-2.4.4-1.el8ev.noarch
ovirt-ansible-hosted-engine-setup-1.1.2-1.el8ev.noarch
(build 4.4.0-31)

How reproducible:
100%

Steps to Reproduce:
1. Check the memory in your host and make sure it's not enough.
in my case only 2283 MB available:
# free -h
              total        used        free      shared  buff/cache   available
Mem:           31Gi        28Gi       545Mi       7.0Mi       2.3Gi       2.5Gi
Swap:          15Gi       3.0Mi        15Gi
2. Run the command: hosted-engine --deploy (with the default values)

Actual results:
I got the following question:
Continue with specified memory size? (Yes, No) [No]:
when I clicked Enter to use the default[No] I got into an endless loop 
as you can see below.

[ INFO  ] Stage: Initializing
[ INFO  ] Stage: Environment setup
          During customization use CTRL-D to abort.
          Continuing will configure this host for serving as hypervisor and will create a local VM with a running engine.
          The locally running engine will be used to configure a new storage domain and create a VM there.
          At the end the disk of the local VM will be moved to the shared storage.
          Are you sure you want to continue? (Yes, No)[Yes]:
          Configuration files:
...
...
          Please specify the number of virtual CPUs for the VM (Defaults to appliance OVF value): [4]:
[WARNING] Minimum requirements not met by available memory: Required: 4096 MB. Available: 2283 MB
          Please specify the memory size of the VM in MB (Defaults to maximum available): [2283]:
[WARNING] Minimum requirements for memory size not met
          Continue with specified memory size? (Yes, No) [No]:
          Please specify the memory size of the VM in MB (Defaults to maximum available): [2283]:
[WARNING] Minimum requirements for memory size not met
          Continue with specified memory size? (Yes, No) [No]:
          Please specify the memory size of the VM in MB (Defaults to maximum available): [2283]:
[WARNING] Minimum requirements for memory size not met
          Continue with specified memory size? (Yes, No) [No]:

Expected results:
when I choose no so I expected to exit from the deploy process.

Additional info:
In my case it was worse because I used answer file with:
DIALOG/autoAcceptDefault=bool:True
so it got into an endless loop for hours and the setup log file increased to 1.4G as you can see:
-rw-r--r--. 1 root root 1.4G Apr 22 14:24 ovirt-hosted-engine-setup-20200421181006-cfvva8.log

Comment 1 Nikolai Sednev 2020-08-12 10:01:13 UTC
ovirt-hosted-engine-setup-2.4.5-1.el8ev.noarch is still the latest available to QA from 2020-08-09. Can't proceed with verification yet.

Comment 2 Nikolai Sednev 2020-08-12 15:27:53 UTC
alma03 ~]# free -h
              total        used        free      shared  buff/cache   available
Mem:           31Gi        30Gi       232Mi       3.0Mi        72Mi        20Mi
Swap:         2.0Gi       425Mi       1.6Gi

ovirt-hosted-engine-ha-2.4.4-1.el8ev.noarch
ovirt-hosted-engine-setup-2.4.6-1.el8ev.noarch

"Abort" option:
[WARNING] Minimum requirements for memory size not met
          Continue with specified memory size? (Yes, No, Abort) [Abort]: 
[ ERROR ] Failed to execute stage 'Environment customization': Aborted by user
[ INFO  ] Stage: Clean up
[ INFO  ] Cleaning temporary resources

"No" option:
[WARNING] Minimum requirements not met by available memory: Required: 4096 MB. Available: -208 MB
          Please specify the memory size of the VM in MB (Defaults to maximum available): [-208]: 
[WARNING] Minimum requirements for memory size not met
          Continue with specified memory size? (Yes, No, Abort) [Abort]: No
          Please specify the memory size of the VM in MB (Defaults to maximum available): [-208]: 
[WARNING] Minimum requirements for memory size not met
          Continue with specified memory size? (Yes, No, Abort) [Abort]: No
          Please specify the memory size of the VM in MB (Defaults to maximum available): [-208]: 
[WARNING] Minimum requirements for memory size not met
          Continue with specified memory size? (Yes, No, Abort) [Abort]: 

Please make No=Abort or remove No option at all. 
Moving back to assigned as originally reported issue still happens if No option being set by user.

Comment 3 Asaf Rachmani 2020-08-13 08:28:18 UTC
'No' option allows you to change the value (in this case memory), while 'Abort' option allows you to abort the setup.
When using 'DIALOG/autoAcceptDefault=bool:True' with insufficient memory as described in comment 0, the setup will abort immediately.
In bug 1840756 we've added a limit for the number of attempts, so there shouldn't be an endless loop anymore.

Comment 4 Nikolai Sednev 2020-08-13 11:26:35 UTC
Then moving to verified as "abort" is working fine and "no" returns to previous choice option.

ovirt-hosted-engine-ha-2.4.4-1.el8ev.noarch
ovirt-hosted-engine-setup-2.4.6-1.el8ev.noarch

Comment 5 Sandro Bonazzola 2020-09-18 07:12:49 UTC
This bugzilla is included in oVirt 4.4.2 release, published on September 17th 2020.

Since the problem described in this bug report should be resolved in oVirt 4.4.2 release, it has been closed with a resolution of CURRENT RELEASE.

If the solution does not work for you, please open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.