Bug 1332927

Summary: The hosted engine deploy via appliance failed on the engine-setup stage
Product: [oVirt] ovirt-hosted-engine-setup Reporter: Artyom <alukiano>
Component: GeneralAssignee: Simone Tiraboschi <stirabos>
Status: CLOSED CURRENTRELEASE QA Contact: Artyom <alukiano>
Severity: urgent Docs Contact:
Priority: high    
Version: 2.0.0CC: alukiano, bugs, cshao, didi, fdeutsch, knarra, leiwang, sbonazzo, ycui, ylavi
Target Milestone: ovirt-4.0.0-rcKeywords: AutomationBlocker, Regression, Triaged
Target Release: ---Flags: rule-engine: ovirt-4.0.0+
rule-engine: blocker+
ylavi: planning_ack+
fdeutsch: devel_ack+
mavital: testing_ack+
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
undefined
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-07-05 07:39:56 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Node RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
hosted engine setup log
none
new hosted engine setup log none

Description Artyom 2016-05-04 11:36:59 UTC
Created attachment 1153812 [details]
hosted engine setup log

Description of problem:
The hosted engine deploy via appliance failed on the engine-setup stage because missed answer in the answer file:
          |-           Please note: Data Warehouse is required for the engine. If you choose to not configure it on this host, you have to configure it on a remote host, and then configure the engine on this host so that it can access the database of the remote Data Warehouse host.
          |-           Configure Data Warehouse on this host (Yes, No) [Yes]: [ ERROR ] Failed to execute stage 'Environment customization': End of file
          |- [ INFO  ] Stage: Clean up
          |-           Log file is located at /var/log/ovirt-engine/setup/ovirt-engine-setup-20160504100132-7a1att.log
          |- [ INFO  ] Generating answer file '/var/lib/ovirt-engine/setup/answers/20160504100133-setup.conf'

Version-Release number of selected component (if applicable):
ovirt-engine-appliance-4.0-20160503.1.el7.centos.noarch

How reproducible:
Always

Steps to Reproduce:
1. Start hosted engine deployment via appliance
2. Continue until engine-setup stage
3.

Actual results:
Deployment failed on engine-setup stage

Expected results:
Deployment succeeds without any errors

Additional info:

Comment 1 Fabian Deutsch 2016-05-04 12:31:28 UTC
Didi, can't this be fixed by using https://gerrit.ovirt.org/#/c/55479/ and just providing the answers which differ from the defaults?

Comment 2 Yedidyah Bar David 2016-05-04 12:43:11 UTC
(In reply to Fabian Deutsch from comment #1)
> Didi, can't this be fixed by using https://gerrit.ovirt.org/#/c/55479/ and
> just providing the answers which differ from the defaults?

Yes, that was the exact intention of this patch.

Comment 3 Yaniv Lavi 2016-05-05 12:57:48 UTC
(In reply to Yedidyah Bar David from comment #2)
> (In reply to Fabian Deutsch from comment #1)
> > Didi, can't this be fixed by using https://gerrit.ovirt.org/#/c/55479/ and
> > just providing the answers which differ from the defaults?
> 
> Yes, that was the exact intention of this patch.

We need to ask questions on dwh, therefore I think it's good we hit this issue.

Comment 4 Yedidyah Bar David 2016-05-05 14:12:27 UTC
(In reply to Yaniv Dary from comment #3)
> (In reply to Yedidyah Bar David from comment #2)
> > (In reply to Fabian Deutsch from comment #1)
> > > Didi, can't this be fixed by using https://gerrit.ovirt.org/#/c/55479/ and
> > > just providing the answers which differ from the defaults?
> > 
> > Yes, that was the exact intention of this patch.
> 
> We need to ask questions on dwh, therefore I think it's good we hit this
> issue.

Do you mean that you object to using this "accept defaults" option, so that in the future, if we ask questions, it will fail again?

I do not think I agree.

IMO most users do not thoroughly read our questions, especially not after the first time they run setup. So if we think a question is important enough to require a conscious decision, we should not provide a default. If we do provide a default, it should be good enough for both uses that do not read our questions _and_ for an automated appliance setup inside hosted-engine-setup of ovirt-node.

Comment 5 Yedidyah Bar David 2016-05-05 14:13:20 UTC
s/ask questions/add questions/

Comment 6 Yaniv Lavi 2016-05-05 14:19:19 UTC
We do not add questions in the setup to ignore them in the HE setup without good cause. The questions should be much the same for both.

Comment 7 Fabian Deutsch 2016-05-06 08:54:02 UTC
The goal of the appliance is to have everything preconfigured and only ask the absolutely necessary questions.
That is the reason why we maintain a file with answers to common questions.

If DWH can be set up after the HE deployment, then just use the default (thus this new otopi key).

Comment 8 Yaniv Lavi 2016-05-08 06:04:37 UTC
(In reply to Fabian Deutsch from comment #7)
> The goal of the appliance is to have everything preconfigured and only ask
> the absolutely necessary questions.
> That is the reason why we maintain a file with answers to common questions.
> 
> If DWH can be set up after the HE deployment, then just use the default
> (thus this new otopi key).

It can not be setuped after, it is need for dashboards after installation. Don't we ask the engine db location, application mode and so on in appliance deployment?

Comment 9 Anatoly Litovsky 2016-05-09 07:21:46 UTC
This looks like the vaslu is missing in the answer file generated by hosted engine setup.
I dont think it will be wise to force local warehouse generation in case of appliance.

Comment 10 Sandro Bonazzola 2016-05-09 07:27:21 UTC
Moving to hosted engine

Comment 11 Yedidyah Bar David 2016-05-09 07:28:39 UTC
(In reply to Yaniv Dary from comment #8)
> (In reply to Fabian Deutsch from comment #7)
> > The goal of the appliance is to have everything preconfigured and only ask
> > the absolutely necessary questions.
> > That is the reason why we maintain a file with answers to common questions.
> > 
> > If DWH can be set up after the HE deployment, then just use the default
> > (thus this new otopi key).
> 
> It can not be setuped after, it is need for dashboards after installation.
> Don't we ask the engine db location, application mode and so on in appliance
> deployment?

Of course not. If user runs hosted-engine --deploy with the appliance, and asks to automatically run engine-setup, we ask nothing in engine-setup itself. hosted-engine --deploy asks a few questions (such as admin password) and generates an answer file, which together with the answer file supplied inside the appliance, should run engine-setup unattended.

(In reply to Anatoly Litovsky from comment #9)
> This looks like the vaslu is missing in the answer file generated by hosted
> engine setup.
> I dont think it will be wise to force local warehouse generation in case of
> appliance.

Why not? It's mandatory now.

If you care about this due to extra load, note bug 1328805. I hope to finish with it today or tomorrow, and default to "Minimal" (decided to call it "Basic" for now, in case someone later on wants to add real "Minimal") if running on same machine as engine.

Comment 12 Artyom 2016-05-22 12:19:45 UTC
Verified on ovirt-engine-appliance-4.0-20160521.1.el7.centos.noarch

Comment 13 Artyom 2016-05-30 16:33:20 UTC
I can see problem returned under package ovirt-engine-appliance-4.0-20160529.1.el7.centos.noarch

Comment 14 Red Hat Bugzilla Rules Engine 2016-05-30 16:33:26 UTC
Target release should be placed once a package build is known to fix a issue. Since this bug is not modified, the target version has been reset. Please use target milestone to plan a fix for a oVirt release.

Comment 15 Simone Tiraboschi 2016-05-30 16:52:50 UTC
Artyom, do you have the hosted-engine-setup logs?

Comment 16 Artyom 2016-05-31 08:48:24 UTC
Created attachment 1163085 [details]
new hosted engine setup log

Comment 17 Simone Tiraboschi 2016-06-01 12:38:48 UTC
Unable to reprodice with oVirt Engine Appliance image (OVA) - 4.0-20160529.1.el7.centos

Comment 18 Simone Tiraboschi 2016-06-01 12:47:28 UTC
Artyom,
I saw that you have:

2016-05-30 19:16:31 DEBUG otopi.context context.dumpEnvironment:770 ENV OVEHOSTED_VM/cloudInitISO=str:'existing'

2016-05-30 19:16:31 DEBUG otopi.context context.dumpEnvironment:770 ENV OVEHOSTED_VM/vmCDRom=str:'/tmp/cloud-init/hosted-engine-automation.iso'

So you are not using the cloud-init ISO image generated by hosted-engine-setup but a custom one.
Are you sure that you have all the required answers there?

More precisely, you need to pass something like
 [environment:init]
 DIALOG/autoAcceptDefault=bool:True
are you?

Comment 19 Artyom 2016-06-02 14:51:41 UTC
Yes you are correct it was something that I missed in my code.

Comment 20 Sandro Bonazzola 2016-07-05 07:39:56 UTC
oVirt 4.0.0 has been released, closing current release.