Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1763766

Summary: ovirt-host-deploy-ansible fails on isolated (offline) nodes due to yum checks on ovirt-engine-metrics/oVirt.initial-validations
Product: [oVirt] ovirt-engine-metrics Reporter: Christophe Godart <christophe.godart>
Component: GenericAssignee: Shirly Radco <sradco>
Status: CLOSED DUPLICATE QA Contact: Lukas Svaty <lsvaty>
Severity: high Docs Contact:
Priority: high    
Version: unspecifiedCC: bugs, rbarry, stirabos
Target Milestone: ovirt-4.3.7   
Target Release: ---   
Hardware: x86_64   
OS: Other   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-11-04 08:19:09 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Metrics RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Hosted Engine Setup log
none
hosted engine log directory none

Description Christophe Godart 2019-10-21 14:46:57 UTC
Created attachment 1627717 [details]
Hosted Engine Setup log

Description of problem:

I'm tryng to install an oVirt Cluster and the hosted-engine --deploy fails at the step "Wait for the host to be up"

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

$  yum list installed | grep ovirt
cockpit-machines-ovirt.noarch              195.1-1.el7.centos.0.1      installed
cockpit-ovirt-dashboard.noarch             0.13.8-1.el7                installed
ovirt-ansible-engine-setup.noarch          1.1.9-1.el7                 installed
ovirt-ansible-hosted-engine-setup.noarch   1.0.29-1.el7                installed
ovirt-ansible-repositories.noarch          1.1.5-1.el7                 installed
ovirt-engine-appliance.x86_64              4.3-20190926.1.el7          installed
ovirt-host.x86_64                          4.3.4-1.el7                 installed
ovirt-host-dependencies.x86_64             4.3.4-1.el7                 installed
ovirt-host-deploy-common.noarch            1.8.2-1.el7                 installed
ovirt-hosted-engine-ha.noarch              2.3.5-1.el7                 installed
ovirt-hosted-engine-setup.noarch           2.3.12-1.el7                installed
ovirt-imageio-common.x86_64                1.5.2-0.el7                 installed
ovirt-imageio-daemon.noarch                1.5.2-0.el7                 installed
ovirt-node-ng-image-update-placeholder.noarch
ovirt-node-ng-nodectl.noarch               4.3.6-0.20190820.0.el7      installed
ovirt-provider-ovn-driver.noarch           1.2.22-1.el7                installed
ovirt-release-host-node.noarch             4.3.6-1.el7                 installed
ovirt-release43.noarch                     4.3.6-1.el7                 installed
ovirt-vmconsole.noarch                     1.0.7-2.el7                 installed
ovirt-vmconsole-host.noarch                1.0.7-2.el7                 installed
python-ovirt-engine-sdk4.x86_64            4.3.2-2.el7                 installed
python2-ovirt-host-deploy.noarch           1.8.2-1.el7                 installed
python2-ovirt-node-ng-nodectl.noarch       4.3.6-0.20190820.0.el7      installed
python2-ovirt-setup-lib.noarch             1.2.0-1.el7                 installed

How reproducible:
100 %

Steps to Reproduce:
1. Install oVirt Node 4.3.6
2. $ rpm -i ovirt-engine-appliance-4.3-20190926.1.el7.x86_64.rpm
3. $ hosted-engine --deploy --4

Actual results:
Setup hangs at "Wait for the host to be up" then fails.

Expected results:
Setup succeed

Additional info:
N/A

Comment 1 Christophe Godart 2019-10-21 14:54:31 UTC
The engine is up and reachable with this URL:
https://<host>:6900/ovirt-engine

The hosted engine section tells me:
This system is already registered to <engine-host>!

But CLI does not agree:

# hosted-engine --vm-status
It seems like a previous attempt to deploy hosted-engine failed or it's still in progress. Please clean it up before trying again

# hosted-engine --check-deployed
The hosted engine has not been deployed

# hosted-engine --check-liveliness
Error reading the configuration file

Comment 2 Sandro Bonazzola 2019-10-23 07:06:23 UTC
Can you please attach sos report from the host and from the engine VM?

Comment 3 Simone Tiraboschi 2019-10-23 07:09:42 UTC
The host got in "status": "install_failed", but we need host-deploy logs to understand the root cause.

Comment 4 Christophe Godart 2019-10-23 08:14:39 UTC
Created attachment 1628195 [details]
hosted engine log directory

I made a new try. Same result. This is the content of the log directory for hosted engine setup.

Comment 5 Simone Tiraboschi 2019-10-23 08:20:37 UTC
The issue is here:

2019-10-23 09:53:30,138 p=32317 u=ovirt |  failed: [srv-ptf-digit-01.wks.era.sds.safran] (item=collectd-write_syslog) => {
    "ansible_loop_var": "item", 
    "changed": false, 
    "item": "collectd-write_syslog"
}

MSG:

Error from repoquery: ['/usr/bin/repoquery', '--show-duplicates', '--plugins', '--quiet', '--disablerepo', '', '--enablerepo', '', '--qf', '%{name}|%{epoch}|%{version}|%{release}|%{arch}|%{repoid}', 'collectd-write_syslog']: Could not match packages: Cannot retrieve metalink for repository: ovirt-4.3-epel/x86_64. Please verify its path and try again


2019-10-23 09:53:30,149 p=32317 u=ovirt |  PLAY RECAP *********************************************************************
2019-10-23 09:53:30,149 p=32317 u=ovirt |  srv-ptf-digit-01.wks.era.sds.safran : ok=37   changed=3    unreachable=0    failed=1    skipped=16   rescued=0    ignored=1  


it fails running a query over a yum repo.
Is the host offline at install time?

Comment 6 Christophe Godart 2019-10-23 08:37:00 UTC
(In reply to Simone Tiraboschi from comment #5)

> it fails running a query over a yum repo.
> Is the host offline at install time?

Yes. It's connected to an enterprise network and we did not set up an ovirt mirror for the moment.
We have a Red Hat mirror but it does not include rhev repository.

Is this yum query really required ? Does the host need to install additional packages or is it just a system update ?

Comment 7 Simone Tiraboschi 2019-10-23 08:50:00 UTC
(In reply to Christophe Godart from comment #6)
> Is this yum query really required ? Does the host need to install additional
> packages or is it just a system update ?

It's still a (new) duplicate of this one:
https://bugzilla.redhat.com/show_bug.cgi?id=1677246

list action on yum ansible module requires a connection to the repo even if all the packets are already there:

https://github.com/oVirt/ovirt-engine-metrics/blob/master/roles/oVirt.initial-validations/tasks/check_logging_collectors.yml#L30

Comment 8 Christophe Godart 2019-10-23 09:38:23 UTC
Do you think it may help if I set up a local mirror on the node ?
Or is it useless in this case ?

Comment 9 Simone Tiraboschi 2019-10-23 09:49:03 UTC
Yes, it should work,
you can test it running 
  /usr/bin/repoquery --show-duplicates --quiet --qf "%{name}|%{epoch}|%{version}|%{release}|%{arch}|%{repoid}" rsyslog-elasticsearch

on that host and it shouldn't fail.

Comment 10 Christophe Godart 2019-10-23 15:12:07 UTC
OK, I made it work using a mirror.

Comment 11 Sandro Bonazzola 2019-11-04 08:19:09 UTC
closing as duplicate of bug #1677246 as per comment #7

*** This bug has been marked as a duplicate of bug 1677246 ***

Comment 12 Christophe Godart 2019-11-05 09:04:10 UTC
(In reply to Sandro Bonazzola from comment #11)
> closing as duplicate of bug #1677246 as per comment #7
> 
> *** This bug has been marked as a duplicate of bug 1677246 ***

Sorry but it seems to be a new bug.
This bug is present in oVirt 4.3.6 !