Bug 948311 - allinone installation fails if host does not contain /etc/hosts entry
Summary: allinone installation fails if host does not contain /etc/hosts entry
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine-setup
Version: 3.2.0
Hardware: x86_64
OS: Linux
urgent
unspecified
Target Milestone: ---
: 3.2.0
Assignee: Sandro Bonazzola
QA Contact: Leonid Natapov
URL:
Whiteboard: integration
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-04-04 14:40 UTC by Dave Kline
Modified: 2015-09-22 13:09 UTC (History)
11 users (show)

Fixed In Version: sf14
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
oVirt Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
gzipped tar file of engine-setup_2013_04_03_14_10_58.log, ovirt-20130403151950-rhev.vm-35febd05.log, and server.log (390.00 KB, application/octet-stream)
2013-04-05 15:51 UTC, Dave Kline
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 13933 0 None None None Never

Description Dave Kline 2013-04-04 14:40:32 UTC
Description of problem:

I was unable to successfully install RHEV 3.2 beta with the allinone plugin unless I added the host's desired host name and IP address in /etc/hosts.

Version-Release number of selected component (if applicable):

[root@rhev ~]# rpm -qa|grep rhev
rhevm-image-uploader-3.2.0-1.el6ev.noarch
rhevm-config-3.2.0-10.14.beta1.el6ev.noarch
rhevm-notification-service-3.2.0-10.14.beta1.el6ev.noarch
rhevm-restapi-3.2.0-10.14.beta1.el6ev.noarch
rhevm-doc-3.2.0-0.3.beta.el6eng.noarch
rhev-guest-tools-iso-3.2-4.noarch
rhevm-sdk-3.2.0.5-1.el6ev.noarch
rhevm-tools-common-3.2.0-10.14.beta1.el6ev.noarch
rhevm-spice-client-x64-cab-3.2-2.el6ev.noarch
rhevm-setup-3.2.0-10.14.beta1.el6ev.noarch
rhevm-setup-plugin-allinone-3.2.0-10.14.beta1.el6ev.noarch
rhevm-log-collector-3.2.0-1.el6ev.noarch
rhevm-webadmin-portal-3.2.0-10.14.beta1.el6ev.noarch
rhevm-genericapi-3.2.0-10.14.beta1.el6ev.noarch
rhevm-spice-client-x86-cab-3.2-2.el6ev.noarch
rhevm-3.2.0-10.14.beta1.el6ev.noarch
qemu-kvm-rhev-0.12.1.2-2.355.el6_4.2.x86_64
rhevm-iso-uploader-3.2.0-1.el6ev.noarch
qemu-img-rhev-0.12.1.2-2.355.el6_4.2.x86_64
rhevm-cli-3.2.0.5-1.el6ev.noarch
rhevm-backend-3.2.0-10.14.beta1.el6ev.noarch
rhevm-dbscripts-3.2.0-10.14.beta1.el6ev.noarch
rhevm-userportal-3.2.0-10.14.beta1.el6ev.noarch

Steps to Reproduce:
1. yum install -y rhevm-setup-plugin-allinone rhevm-setup
2. Leave /etc/hosts untouched
3. Observe errors
  
Actual results:

Error on terminal:

AIO: Creating storage directory...                                [ DONE ]
AIO: Adding Local Datacenter and cluster...                    [ ERROR ]
Error: There's a problem with JBoss service.Check that it's up and rerun
setup.
Please check log file
/var/log/ovirt-engine/engine-setup_2013_04_03_14_10_58.log for more
information

----------------

The log contains:

2013-04-03 14:15:28::DEBUG::rhevm-setup::1895::root:: superuser-pass:
********
2013-04-03 14:15:28::ERROR::rhevm-setup::2311::root:: Traceback (most
recent call last):
  File "/usr/bin/rhevm-setup", line 2305, in <module>
    main(confFile)
  File "/usr/bin/rhevm-setup", line 2088, in main
    runSequences()
  File "/usr/bin/rhevm-setup", line 2010, in runSequences
    controller.runAllSequences()
  File "/usr/share/ovirt-engine/scripts/setup_controller.py", line 54,
in runAllSequences
    sequence.run()
  File "/usr/share/ovirt-engine/scripts/setup_sequences.py", line 154,
in run
    step.run()
  File "/usr/share/ovirt-engine/scripts/setup_sequences.py", line 60, in
run
    function()
  File "/usr/share/ovirt-engine/scripts/plugins/all_in_one_100.py", line
216, in waitForJbossUp
    utils.retry(isHealthPageUp, tries=25, timeout=15, sleep=5)
  File "/usr/share/ovirt-engine/scripts/common_utils.py", line 1008, in
retry
    return func()
  File "/usr/share/ovirt-engine/scripts/plugins/all_in_one_100.py", line
438, in isHealthPageUp
    raise Exception(ERROR_JBOSS_STATUS)
Exception: Error: There's a problem with JBoss service.Check that it's
up and rerun setup.

Expected results:

rhevm-setup yells at you for not adding an /etc/hosts stanza.

Comment 1 Sandro Bonazzola 2013-04-05 06:20:38 UTC
Can you please attach /var/log/ovirt-engine/engine-setup_2013_04_03_14_10_58.log , the log related to this run placed in /var/log/ovirt-engine/host-deploy/ and /var/log/ovirt-engine/server.log ?

Comment 2 Dave Kline 2013-04-05 15:51:46 UTC
Created attachment 731960 [details]
gzipped tar file of engine-setup_2013_04_03_14_10_58.log, ovirt-20130403151950-rhev.vm-35febd05.log, and server.log

Hello, this is a tgz of the requested logs.

Comment 3 Alex Lourie 2013-04-07 09:57:00 UTC
Dave

What archiver did you use to create the logs? I can't open it for some reason (tried gunzip and tar/gz).

Thanks.

Comment 4 Sandro Bonazzola 2013-04-08 11:46:45 UTC
Alex, it's a simple tar without compression and wrong extension.

Comment 5 Sandro Bonazzola 2013-04-08 11:58:06 UTC
Dave, just to be sure, in this bug you're asking to add a message inside rhevm-setup reminding to the user that if the specified FQDN can't be resolved it has to be added to /etc/hosts, right?

Because it seems that the provided host name was not resolved by the DNS and the script already prompted asking if you were sure you wanted to proceed with that FQDN.

Comment 6 Douglas Schilling Landgraf 2013-04-08 13:33:13 UTC
I saw another user reporting such error (not in allinone) over IRC.

From my point of view, I won't proceed with setup sharing a message like: 
"Couldn't resolve host provided [xyz.com], please use DNS or static table lookup for hostnames (/etc/hosts)"

Just my 2cents.

Cheers
Douglas

Comment 7 Alon Bar-Lev 2013-04-08 15:32:59 UTC
This bug and bug#928667 are related and can be solved using the same approach.

Comment 8 Sandro Bonazzola 2013-04-10 07:41:49 UTC
So the proposed solution of both this bug and bug #928667 is check if the provided fqdn resolve to a local address not mapped on a loopback device.
The check should accept a fqdn not resolved by DNS but resolved by hosts file.
If the check fails the setup should not allow to continue the installation.

Is this correct?

Comment 9 Alon Bar-Lev 2013-04-10 07:53:55 UTC
(In reply to comment #8)
> So the proposed solution of both this bug and bug #928667 is check if the
> provided fqdn resolve to a local address not mapped on a loopback device.

Right.

> The check should accept a fqdn not resolved by DNS but resolved by hosts
> file.

I am unsure about that... if we do not want to have DNS involved, we can just add our hosts entry with that address...
But if we do want offline operation I guess we cannot relay on DNS.
How have we managed this so far?

> If the check fails the setup should not allow to continue the installation.

Right.

Comment 10 Dave Kline 2013-04-12 19:06:55 UTC
From my humble user perspective, rhevm-setup should yell at me for entering and confirming an FQDN that's meaningless or that resolves to loopback.  I agree with Alon's comment about #928667, it certainly seems similar. AIO setups, I imagine, will have more DNS errors than tradition deployments.

Comment 11 Sandro Bonazzola 2013-04-15 08:57:18 UTC
(In reply to comment #9)

> > The check should accept a fqdn not resolved by DNS but resolved by hosts
> > file.
> 
> I am unsure about that... if we do not want to have DNS involved, we can
> just add our hosts entry with that address...
> But if we do want offline operation I guess we cannot relay on DNS.
> How have we managed this so far?

If you have multiple nics with different ip addresses how do you determine what to write in /etc/hosts? I think that the admin should take care of having the desired FQDN assigned to the right address before using it.

Comment 12 Sandro Bonazzola 2013-04-19 07:00:05 UTC
patch 13933 merged upstream master: http://gerrit.ovirt.org/gitweb?p=ovirt-engine.git;a=commit;h=1dd78501699913486c9cac8b1864975b5147d620

Comment 14 Leonid Natapov 2013-05-22 12:12:15 UTC
sf17. fixed.

Comment 15 Itamar Heim 2013-06-11 08:45:03 UTC
3.2 has been released

Comment 16 Itamar Heim 2013-06-11 08:45:08 UTC
3.2 has been released

Comment 17 Itamar Heim 2013-06-11 08:45:09 UTC
3.2 has been released

Comment 18 Itamar Heim 2013-06-11 08:51:16 UTC
3.2 has been released

Comment 19 Itamar Heim 2013-06-11 09:22:22 UTC
3.2 has been released


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