Bug 2107063

Summary: [HE] ansible-role is calling ovn-config without specifying the host FQDN
Product: [oVirt] ovirt-ansible-collection Reporter: Michael Burman <mburman>
Component: hosted-engine-setupAssignee: eraviv
Status: CLOSED CURRENTRELEASE QA Contact: Michael Burman <mburman>
Severity: high Docs Contact:
Priority: high    
Version: 2.0.3CC: amusil, arachman, bugs, dfodor, eraviv, michal.skrivanek, mperina, msheena
Target Milestone: ovirt-4.5.2Flags: mperina: ovirt-4.5+
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: ovirt-ansible-collection-2.2.1 Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-08-30 08:47:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Network RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Michael Burman 2022-07-14 08:52:07 UTC
Description of problem:
[HE] ansible-role is calling ovn-config without specifying the host FQDN 
which is causing the first host to be deployed with UUID in the chassis ovn-sbctl, instead of FQDN. Which making OVN not functional after fresh HE deploy on the first deployed host. 

ansible.builtin.command: vdsm-tool ovn-config {{ engine_vm_ip.stdout_lines[0] }} {{ he_mgmt_network }}

Chassis "5d9ae13e-1fb9-48d9-ba66-c777d5753444"

Version-Release number of selected component (if applicable):
ansible-core-2.12.2-3.1.el8.x86_64
ovirt-ansible-collection-2.1.0-1.el8ev.noarch
rhvm-4.5.1.3-0.28.el8ev.noarch
ovirt-hosted-engine-setup-2.6.4-1.el8ev.noarch
ovirt-hosted-engine-ha-2.5.0-1.el8ev.noarch

How reproducible:
100%

Steps to Reproduce:
1. Deploy fresh Hosted Engine 4.5.1.3

Actual results:
HE ansible-role is calling ovn-config without specifying the host FQDN. Ends up with first host's chassis in sbctl as UUID instead of FQDN. Making OVN not functional on the first deployed host in the HE environment. 

Expected results:
HE ansible-role should specify the host FQDN when calling ovn-config

Additional info:
The work around will be:
vdsm-tool ovn-config {{ ovn_central }} {{ ovn_tunneling_interface }} {{ ovn_host_fqdn }}

Comment 5 Michael Burman 2022-07-31 11:10:00 UTC
    ansible.builtin.command: vdsm-tool ovn-config {{ engine_vm_ip.stdout_lines[0] }} {{ he_mgmt_network }} {{ he_host_name }} is picking up: name used by the engine for the first host
in our case it return 'host_mixed_1'

Comment 6 Michael Burman 2022-07-31 11:19:58 UTC
The following should be fixed in the docs:

he_host_name is NOT equal to $(hostname -f)

he_host_address is NOT equal to $(hostname -f) - it should be host's IP address

Suggesting to change he_ansible_host_name to $(hostname -f)

Comment 9 Michael Burman 2022-08-08 11:09:08 UTC
Verified on - ovirt-ansible-collection-2.2.1-1.el8ev.noarch  with:

rhvm-4.5.2.1-0.1.el8ev.noarch
ovirt-hosted-engine-setup-2.6.5-1.el8ev.noarch
vdsm-4.50.2.2-1.el8ev.x86_64

Comment 10 Sandro Bonazzola 2022-08-30 08:47:42 UTC
This bugzilla is included in oVirt 4.5.2 release, published on August 10th 2022.
Since the problem described in this bug report should be resolved in oVirt 4.5.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.