Bug 1522712 - OVEHOSTED_VM/cloudinitVMStaticCIDR will be set without CIDR
Summary: OVEHOSTED_VM/cloudinitVMStaticCIDR will be set without CIDR
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: cockpit-ovirt
Classification: oVirt
Component: Hosted Engine
Version: ---
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: ovirt-4.2.2
: 0.11.18
Assignee: Simone Tiraboschi
QA Contact: Yihui Zhao
URL:
Whiteboard:
: 1522941 (view as bug list)
Depends On: 1528818 1558036
Blocks: 1458709
TreeView+ depends on / blocked
 
Reported: 2017-12-06 10:01 UTC by Bernhard Seidl
Modified: 2018-03-29 11:18 UTC (History)
13 users (show)

Fixed In Version: cockpit-ovirt-0.11.18-0.1
Clone Of:
Environment:
Last Closed: 2018-03-29 11:18:55 UTC
oVirt Team: Integration
Embargoed:
rule-engine: ovirt-4.2+
rule-engine: blocker+
rule-engine: testing_ack+


Attachments (Terms of Use)
Screenshot when trying to enter CIDR (15.19 KB, image/png)
2017-12-06 10:01 UTC, Bernhard Seidl
no flags Details
Screenshot only having address without CIDR (14.43 KB, image/png)
2017-12-06 10:02 UTC, Bernhard Seidl
no flags Details
Setup Log (933.87 KB, text/plain)
2017-12-06 12:27 UTC, Bernhard Seidl
no flags Details
Screenshot from 2018-02-18 13-00-19.png (18.70 KB, image/png)
2018-02-18 11:00 UTC, Nikolai Sednev
no flags Details
Screenshot from 2018-02-22 21-08-23.png (58.13 KB, image/png)
2018-02-22 19:09 UTC, Nikolai Sednev
no flags Details
sosreport from alma04 (9.52 MB, application/x-xz)
2018-03-18 19:29 UTC, Nikolai Sednev
no flags Details
cockpit1 (52.03 KB, image/png)
2018-03-26 08:23 UTC, Yihui Zhao
no flags Details
cockpit2 (71.29 KB, image/png)
2018-03-26 08:24 UTC, Yihui Zhao
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 85142 0 master MERGED network: Add CIDR prefix if missing in the answerfile 2018-09-03 09:37:32 UTC

Description Bernhard Seidl 2017-12-06 10:01:14 UTC
Created attachment 1363579 [details]
Screenshot when trying to enter CIDR

Description of problem:
Error Message during setup:
The Engine VM (192.168.78.23) and this host (192.168.78.20/24) will not be in the same IP subnet.

Root cause:
The static ip address field during setup just allows to enter an ip address without CIDR (see attached screenshots). This value will be set as OVEHOSTED_VM/cloudinitVMStaticCIDR in the answer file. However 
OVEHOSTED_VM/cloudinitVMStaticCIDR expects to have a

Version-Release number of selected component (if applicable):
ovirt-node-ng-installer-master-2017120509.iso
ovirt-engine-appliance-4.2-20171205.1.el7.centos.noarch.rpm

How reproducible:


Steps to Reproduce:
1. Install ovirt node cluster members
2. Start setup of hosted engine with gluster
3. Select to have a static ip for engine

Actual results:
OVEHOSTED_VM/cloudinitVMStaticCIDR missing CIDR

Expected results:
CIDR can be entered an will be set in answerfile

Additional info:

Workaround:
Add CIDR notation in answerfile manually after setup failed and retry again.

Comment 1 Bernhard Seidl 2017-12-06 10:02:05 UTC
Created attachment 1363580 [details]
Screenshot only having address without CIDR

Comment 2 Yedidyah Bar David 2017-12-06 10:25:08 UTC
Please attach full setup logs. Thanks.

Comment 3 Yedidyah Bar David 2017-12-06 12:19:26 UTC
Simone explained the issue in private: The new cockpit plugin generates an answerfile with no CIDR. We have two options:

1. Move the bug there and add the CIDR

2. Change the code to add the CIDR if missing in answerfile.

I think I'll opt for (2.).

Logic will be same as today - use CIDR of the nic or bridge.

Comment 4 Bernhard Seidl 2017-12-06 12:27:00 UTC
Created attachment 1363638 [details]
Setup Log

Comment 5 Bernhard Seidl 2017-12-06 12:27:41 UTC
Please note attachment

Comment 6 Bernhard Seidl 2017-12-06 12:31:29 UTC
Option two might be a quick fix, due to the fact that some networks might use a different CIDR than /24.

Comment 7 Yedidyah Bar David 2017-12-06 21:37:05 UTC
*** Bug 1522941 has been marked as a duplicate of this bug. ***

Comment 8 Bernhard Seidl 2017-12-12 15:07:14 UTC
Test versions:
ovirt-node-ng-installer-master-2017121109
4.2.1-0.0.master.20171210113630.git504d08f.el7.centos

Result:
Works

Comment 9 Nikolai Sednev 2018-02-18 10:59:32 UTC
Still being reproduced on these components: 
ovirt-hosted-engine-ha-2.2.5-1.el7ev.noarch
ovirt-hosted-engine-setup-2.2.10-1.el7ev.noarch
rhvm-appliance-4.2-20180202.0.el7.noarch
Linux 3.10.0-693.19.1.el7.x86_64 #1 SMP Thu Feb 1 12:34:44 EST 2018 x86_64 x86_64 x86_64 GNU/Linux

Comment 10 Red Hat Bugzilla Rules Engine 2018-02-18 10:59:38 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 11 Nikolai Sednev 2018-02-18 11:00:54 UTC
Created attachment 1397529 [details]
Screenshot from 2018-02-18 13-00-19.png

Comment 12 Nikolai Sednev 2018-02-22 19:09:14 UTC
I still see the same error as described within the attachment.
cockpit-ovirt-dashboard-0.11.12-0.1.el7ev.noarch
ovirt-hosted-engine-ha-2.2.6-1.el7ev.noarch
ovirt-hosted-engine-setup-2.2.11-1.el7ev.noarch
rhvm-appliance-4.2-20180202.0.el7.noarch
Red Hat Enterprise Linux Server release 7.5 Beta (Maipo)
Linux alma03.qa.lab.tlv.redhat.com 3.10.0-855.el7.x86_64 #1 SMP Tue Feb 20 06:46:45 EST 2018 x86_64 x86_64 x86_64 GNU/Linux

Moving back to assigned.

Happens on vintage and ansible.

Comment 13 Red Hat Bugzilla Rules Engine 2018-02-22 19:09:20 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 14 Nikolai Sednev 2018-02-22 19:09:39 UTC
Created attachment 1399505 [details]
Screenshot from 2018-02-22 21-08-23.png

Comment 15 Simone Tiraboschi 2018-02-23 17:08:15 UTC
The fix is to consume host network mask length if we don't found a value in the answer file from cockpit vintage.

If we also need to let the user enter a valid prefix from cockpit wizard please open a new bug there.

Comment 16 Nikolai Sednev 2018-02-24 20:55:15 UTC
(In reply to Simone Tiraboschi from comment #15)
> The fix is to consume host network mask length if we don't found a value in
> the answer file from cockpit vintage.
> 
> If we also need to let the user enter a valid prefix from cockpit wizard
> please open a new bug there.

So what will be the reproduction steps for this bug?

Comment 17 Simone Tiraboschi 2018-02-26 08:16:05 UTC
(In reply to Nikolai Sednev from comment #16)
> So what will be the reproduction steps for this bug?

Simply enter a static  IPv4 address for the engine VM in cockpit, the engine VM will be configured with the host netmask.

Comment 18 Nikolai Sednev 2018-02-26 08:25:20 UTC
(In reply to Simone Tiraboschi from comment #17)
> (In reply to Nikolai Sednev from comment #16)
> > So what will be the reproduction steps for this bug?
> 
> Simply enter a static  IPv4 address for the engine VM in cockpit, the engine
> VM will be configured with the host netmask.

But the static IP is not receiving the CIDR, e.g. x.x.x.x/y, it can only get static IP without CIDR, e.g. x.x.x.x.
Wasn't this bug initially been open on CIDR inability of configuration from Cockpit UI?
See also originally posted https://bugzilla.redhat.com/attachment.cgi?id=1363579.

Comment 19 Nikolai Sednev 2018-02-28 08:45:12 UTC
(In reply to Simone Tiraboschi from comment #15)
> The fix is to consume host network mask length if we don't found a value in
> the answer file from cockpit vintage.
> 
> If we also need to let the user enter a valid prefix from cockpit wizard
> please open a new bug there.

https://bugzilla.redhat.com/show_bug.cgi?id=1549983

Comment 20 Nikolai Sednev 2018-03-18 19:25:31 UTC
Deployment of SHE Node 0, over NFS, using Cockpit, failed on these components: 
Works for me on these components on host:
ovirt-hosted-engine-ha-2.2.7-1.el7ev.noarch
ovirt-hosted-engine-setup-2.2.13-1.el7ev.noarch
rhvm-appliance-4.2-20180202.0.el7.noarch
Linux 3.10.0-861.el7.x86_64 #1 SMP Wed Mar 14 10:21:01 EDT 2018 x86_64 x86_64 x86_64 GNU/Linux
Red Hat Enterprise Linux Server release 7.5 (Maipo)

I've used static IP without CIDR prefix in Cockpit.


[ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: list object has no element 0\n\nThe error appears to have been in '/usr/share/ovirt-hosted-engine-setup/ansible/create_storage_domain.yml': line 111, column 5, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n - debug: var=app_ovf\n - name: parse OVF\n ^ here\n\nexception type: <class 'ansible.errors.AnsibleUndefinedVariable'>\nexception: list object has no element 0"}

Comment 21 Red Hat Bugzilla Rules Engine 2018-03-18 19:25:38 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 22 Nikolai Sednev 2018-03-18 19:29:21 UTC
Created attachment 1409549 [details]
sosreport from alma04

Comment 23 Simone Tiraboschi 2018-03-19 17:12:07 UTC
(In reply to Nikolai Sednev from comment #20)
> [ ERROR ] fatal: [localhost]: FAILED! => {"msg": "The task includes an
> option with an undefined variable. The error was: list object has no element
> 0\n\nThe error appears to have been in
> '/usr/share/ovirt-hosted-engine-setup/ansible/create_storage_domain.yml':
> line 111, column 5, but may\nbe elsewhere in the file depending on the exact
> syntax problem.\n\nThe offending line appears to be:\n\n - debug:
> var=app_ovf\n - name: parse OVF\n ^ here\n\nexception type: <class
> 'ansible.errors.AnsibleUndefinedVariable'>\nexception: list object has no
> element 0"}

This really sounds like a duplicate of https://bugzilla.redhat.com/show_bug.cgi?id=1558036

Please retest this when 1558036 will be fixed.

Comment 24 Yihui Zhao 2018-03-26 08:23:50 UTC
Created attachment 1413011 [details]
cockpit1

Comment 25 Yihui Zhao 2018-03-26 08:24:32 UTC
Created attachment 1413012 [details]
cockpit2

Comment 26 Yihui Zhao 2018-03-26 08:27:15 UTC
Tested with these versions:
rhvh-4.2.2.0-0.20180322.0+1
cockpit-ovirt-dashboard-0.11.19-1.el7ev.noarch
ovirt-hosted-engine-setup-2.2.14-1.el7ev.noarch
ovirt-hosted-engine-ha-2.2.7-1.el7ev.noarch
rhvm-appliance-4.2-20180322.0.el7.noarch



Test result:
See the attachment 1413011 [details] and attachment 1413012 [details], it works well.



So, I will change this bug's status to verified.

Comment 27 Sandro Bonazzola 2018-03-29 11:18:55 UTC
This bugzilla is included in oVirt 4.2.2 release, published on March 28th 2018.

Since the problem described in this bug report should be
resolved in oVirt 4.2.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.


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