Bug 1339593 - Failed to deploy additional RHEL7 3.6 host under HE 3.5 environment
Summary: Failed to deploy additional RHEL7 3.6 host under HE 3.5 environment
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-hosted-engine-setup
Classification: oVirt
Component: General
Version: 1.3.6.1
Hardware: x86_64
OS: Linux
urgent
urgent
Target Milestone: ovirt-3.6.7
: 1.3.7.2
Assignee: Simone Tiraboschi
QA Contact: Artyom
URL:
Whiteboard:
: 1338540 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-05-25 12:11 UTC by Artyom
Modified: 2017-05-11 09:25 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
hosted-engine-setup was failing with an unclear error (AttributeError: 'NoneType' object has no attribute 'startswith') trying to add a 3.6 host to a 3.5 hosted-engine cluster. Fixing the error message.
Clone Of:
Environment:
Last Closed: 2016-07-04 12:30:54 UTC
oVirt Team: Integration
Embargoed:
rule-engine: ovirt-3.6.z+
ylavi: planning_ack+
dfediuck: devel_ack+
mavital: testing_ack+


Attachments (Terms of Use)
he setup log (170.86 KB, text/plain)
2016-05-25 12:11 UTC, Artyom
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 58081 0 master MERGED storage: clear error message when it couldn't find the conf volume 2016-06-02 08:53:17 UTC
oVirt gerrit 58087 0 ovirt-hosted-engine-setup-1.3 MERGED storage: clear error message when it couldn't find the conf volume 2016-06-02 08:53:28 UTC

Description Artyom 2016-05-25 12:11:25 UTC
Created attachment 1161395 [details]
he setup log

Description of problem:
I have HE 3.5 environment, and when I try to deploy additional RHEL7 3.6 host I receive error:
[ INFO  ] Installing on additional host
          Please specify the Host ID [Must be integer, default: 2]: 
         
          --== SYSTEM CONFIGURATION ==--
         
[WARNING] A configuration file must be supplied to deploy Hosted Engine on an additional host.
[ ERROR ] Failed to execute stage 'Environment customization': 'NoneType' object has no attribute 'startswith'

Version-Release number of selected component (if applicable):
3.5 - ovirt-hosted-engine-setup-1.2.2-3.el6ev.noarch
3.6 - ovirt-hosted-engine-setup-1.3.6.1-1.el7ev.noarch

How reproducible:
Always

Steps to Reproduce:
1. Deploy HE 3.5 environment on one host
2. Try to deploy additional RHEL7 3.6 host 
3.

Actual results:
HE deployment failed with:
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/otopi/context.py", line 146, in _executeMethod
    method['method']()
  File "/usr/share/ovirt-hosted-engine-setup/scripts/../plugins/ovirt-hosted-engine-setup/core/remote_answerfile.py", line 168, in _customization
    self._fetch_answer_file()
  File "/usr/share/ovirt-hosted-engine-setup/scripts/../plugins/ovirt-hosted-engine-setup/core/remote_answerfile.py", line 67, in _fetch_answer_file
    self.environment[ohostedcons.StorageEnv.CONF_VOL_UUID],
  File "/usr/lib/python2.7/site-packages/ovirt_hosted_engine_ha/lib/heconflib.py", line 266, in get_volume_path
    vol_uuid,
  File "/usr/lib64/python2.7/posixpath.py", line 75, in join
    if b.startswith('/'):
AttributeError: 'NoneType' object has no attribute 'startswith'

Expected results:
Deployment succeeds without any troubles

Additional info:

Comment 1 Simone Tiraboschi 2016-06-01 13:10:07 UTC
*** Bug 1338540 has been marked as a duplicate of this bug. ***

Comment 2 Artyom 2016-06-07 08:45:37 UTC
Checked on ovirt-hosted-engine-setup-1.3.7.1-1.el7ev.noarch
I still can see the old error:
[ INFO  ] Installing on additional host
          Please specify the Host ID [Must be integer, default: 2]: 
         
          --== SYSTEM CONFIGURATION ==--
         
[WARNING] A configuration file must be supplied to deploy Hosted Engine on an additional host.
[ ERROR ] Failed to execute stage 'Environment customization': 'NoneType' object has no attribute 'startswith'
[ INFO  ] Stage: Clean up
[ INFO  ] Generating answer file '/var/lib/ovirt-hosted-engine-setup/answers/answers-20160607114353.conf'
[ INFO  ] Stage: Pre-termination
[ INFO  ] Stage: Termination
[ ERROR ] Hosted Engine deployment failed: this system is not reliable, please check the issue, fix and redeploy
          Log file is located at /var/log/ovirt-hosted-engine-setup/ovirt-hosted-engine-setup-20160607113728-ko9tks.log

Comment 3 Red Hat Bugzilla Rules Engine 2016-06-07 08:45:41 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 4 Simone Tiraboschi 2016-06-07 08:53:38 UTC
Yes, it wasn't in ovirt-hosted-engine-setup-1.3.7.1-1.el7ev.noarch

Comment 5 Artyom 2016-06-08 12:47:13 UTC
Simone, please change to relevant target release I need to know the version that already include the fix.

Comment 6 Doron Fediuck 2016-06-09 07:40:04 UTC
Simone, which version includes the fix?

Comment 7 Simone Tiraboschi 2016-06-09 08:18:46 UTC
ovirt-hosted-engine-setup-1.3.7.2-1.el7ev.noarch

I'll try to add the target release entry.

Comment 8 Artyom 2016-06-13 08:05:01 UTC
Verified on ovirt-hosted-engine-setup-1.3.7.2-1.el7ev.noarch

[WARNING] A configuration file must be supplied to deploy Hosted Engine on an additional host.
[ ERROR ] Unable to find the hosted-engine configuration volume on the shared storage.
          It seems like your existing HE infrastructure was deployed with version 3.5 (or before) and never upgraded to current release.
          Mixing hosts with HE from 3.5 (or before) and current release is not supported.
          Please upgrade the existing HE hosts to current release before adding this host.
          Please check the log file for more details.
          Replying "No" will abort Setup.
          Continue? (Yes, No) [No]:

Now it looks better, but I do not sure if we need to provide at all answer yes, by my opinion we need just to abort setup without give to user possibility to continue because if I continue setup I receive some another error:
2016-06-13 10:59:59 DEBUG otopi.plugins.otopi.dialog.human dialog.__logString:219 DIALOG:SEND                    - model_Opteron_G2: AMD Opteron G2
2016-06-13 10:59:59 DEBUG otopi.plugins.otopi.dialog.human dialog.__logString:219 DIALOG:SEND                    - model_Opteron_G1: AMD Opteron G1
2016-06-13 10:59:59 DEBUG otopi.context context._executeMethod:156 method exception
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/otopi/context.py", line 146, in _executeMethod
    method['method']()
  File "/usr/share/ovirt-hosted-engine-setup/scripts/../plugins/ovirt-hosted-engine-setup/vdsmd/cpu.py", line 237, in _customization
    ohostedcons.VDSMEnv.VDSM_CPU
RuntimeError: Invalid CPU type specified: None

And I believe it will be not single one.

What do you think Simone?

Comment 9 Simone Tiraboschi 2016-06-13 08:20:59 UTC
(In reply to Artyom from comment #8)
> Verified on ovirt-hosted-engine-setup-1.3.7.2-1.el7ev.noarch
> 
> [WARNING] A configuration file must be supplied to deploy Hosted Engine on
> an additional host.
> [ ERROR ] Unable to find the hosted-engine configuration volume on the
> shared storage.
>           It seems like your existing HE infrastructure was deployed with
> version 3.5 (or before) and never upgraded to current release.
>           Mixing hosts with HE from 3.5 (or before) and current release is
> not supported.
>           Please upgrade the existing HE hosts to current release before
> adding this host.
>           Please check the log file for more details.
>           Replying "No" will abort Setup.
>           Continue? (Yes, No) [No]:
> 
> Now it looks better, but I do not sure if we need to provide at all answer
> yes, by my opinion we need just to abort setup without give to user
> possibility to continue because if I continue setup I receive some another
> error:
> 2016-06-13 10:59:59 DEBUG otopi.plugins.otopi.dialog.human
> dialog.__logString:219 DIALOG:SEND                    - model_Opteron_G2:
> AMD Opteron G2
> 2016-06-13 10:59:59 DEBUG otopi.plugins.otopi.dialog.human
> dialog.__logString:219 DIALOG:SEND                    - model_Opteron_G1:
> AMD Opteron G1
> 2016-06-13 10:59:59 DEBUG otopi.context context._executeMethod:156 method
> exception
> Traceback (most recent call last):
>   File "/usr/lib/python2.7/site-packages/otopi/context.py", line 146, in
> _executeMethod
>     method['method']()
>   File
> "/usr/share/ovirt-hosted-engine-setup/scripts/../plugins/ovirt-hosted-engine-
> setup/vdsmd/cpu.py", line 237, in _customization
>     ohostedcons.VDSMEnv.VDSM_CPU
> RuntimeError: Invalid CPU type specified: None
> 
> And I believe it will be not single one.
> 
> What do you think Simone?

This is something we discussed in the past on the patch.
At the end we decided that was more elegant to let the user abort instead of directly failing but at the end there is not way to continue without prior upgrading an existing host to 3.6.

Comment 10 Artyom 2016-06-13 08:27:10 UTC
Thanks for explanation Simone.
Verified on ovirt-hosted-engine-setup-1.3.7.2-1.el7ev.noarch

Comment 11 Marina Kalinin 2016-06-14 02:34:31 UTC
Shouldn't the message be different though?
Like follow kcs https://access.redhat.com/solutions/2351141 / https://access.redhat.com/solutions/2300331

Comment 12 Simone Tiraboschi 2017-03-07 16:50:59 UTC
The message was fine, kcs has been updated according to it and providing a viable alternative (RHEV-H 7 hypervisor for RHEV 3.5).


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