Settings tab is locked in case of network settings validation error

Bug #1531185 reported by Alexandra Morozova
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Released
High
Matthew Mosesohn
8.0.x
Fix Released
High
Matthew Mosesohn
Mitaka
Fix Released
High
Matthew Mosesohn

Bug Description

Reproduced on the ISO
build_number: "368"

Steps to reproduce:
1) create default environment
2) go to Settings tab and change some setting
3) try to save the change

Expected result: Save Changes button is enabled on the Settings tab and the change can be saved successfully

Actual result: Save Changes button is locked, the change can not be saved. no information on UI what happened and why the button is locked.

==========================================================================

The reason is invalid external_ntp.ntp_list setting that has "" (an empty string) value. This setting has "network" group attribute and is shown on Networks tab.

So, the ticket figures out the following issues:

1) invalid external_ntp.ntp_list setting value comes from backend. User obtains an OpenStack environment with invalid configuration, that can not be deployed.
Should be fixed in Nailgun.

2.1) environment Settings tab should not be locked in case of network settings error.
Should be fixed in Fuel UI code.

2.2) no validation error ("invalid" icon) on UI after refreshing the Networks tab with invalid external_ntp.ntp_list setting. If you move to other tab and come back, the validation error will be displayed.
Should be fixed in Fuel UI code.

Revision history for this message
Alexandra Morozova (astepanchuk) wrote :
Artem Roma (aroma-x)
Changed in fuel:
status: New → Confirmed
Changed in fuel:
assignee: Fuel UI Team (fuel-ui) → Julia Aranovich (jkirnosova)
summary: - Settings validation errors are invisible in case of error with not shown
- section
+ Settings tab is locked in case of network settings validation error
description: updated
Changed in fuel:
assignee: Julia Aranovich (jkirnosova) → Fuel Python Team (fuel-python)
Revision history for this message
Ihor Kalnytskyi (ikalnytskyi) wrote :

There's no bug in Nailgun side - it returns what was came from /etc/nailgun/settings.yaml, and it occurs to be an empty string:

  [root@fuel nailgun]# cat /etc/nailgun/settings.yaml | grep NTP_UP
  NTP_UPSTREAM: ""

So it's either bug in fuelmenu or bug in puppet manifest that creates setttings.yaml in Nailgun container.

Revision history for this message
Ihor Kalnytskyi (ikalnytskyi) wrote :

Well, according to the "nailgun-only.pp" the ntp server list comes from NTP1, NTP2 and NTP3 options of astute.yaml.

I've checked out astute.yaml and it occurs that they are empty:

  [root@fuel nailgun]# cat /etc/fuel/astute.yaml | grep NTP
  "NTP1": ""
  "NTP2": ""
  "NTP3": ""

So probably some fuel-menu bug.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to fuel-web (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/265900

Revision history for this message
Fedor Zhadaev (fzhadaev) wrote :

According to fuel-menu logic, values
  "NTP1": ""
  "NTP2": ""
  "NTP3": ""
are expected if user disabled NTP on 'Time Sync' tab in fuel-menu.
Also I tried to reproduce this bug on ISO #417 and found the default NTP settings in astute.yaml after master node deployment.
Seems like some settings were changed manually in fuel-menu during deployment process.

Revision history for this message
Alexandra Morozova (astepanchuk) wrote :

So, what should be the expected result if settings were changed manually? Should the UI display error message?

Revision history for this message
Julia Aranovich (jkirnosova) wrote :

Alexandra, I think that it should be a standard UI behavior, the field value is validated across it's regex and validation error is displayed as usual

Artem Roma (aroma-x)
Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Fuel UI (fuel-ui-team)
Revision history for this message
Matthew Mosesohn (raytrac3r) wrote :

We should make the user more conscious of this behavior and that we have to specify some value in the NTP server so that the clients don't freak out. My first suggestion was to put $fuel_admin_ip there, but that will break time settings for Fuel Master if it points to itself.
In this case, we should make 2 changes:
1 - Fuelmenu should alert that Fuel Master will be used as a time source if no external servers are specified
2 - puppet manifests for nailgun will specify fuel master IP as ntp server if it's empty

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-menu (master)

Fix proposed to branch: master
Review: https://review.openstack.org/266285

Changed in fuel:
assignee: Fuel UI (fuel-ui-team) → Matthew Mosesohn (raytrac3r)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-library (master)

Fix proposed to branch: master
Review: https://review.openstack.org/266293

Revision history for this message
Vitaly Kramskikh (vkramskikh) wrote :

Matt,

So AFAIU we should also allow empty string for NTP server list in openstack.yaml, right?

Revision history for this message
Maksim Malchuk (mmalchuk) wrote :

Matt, I didn't agree with this, NTP-servers should be always set to non-empty value.
On the fuel-menu side, we should use default NTP-server pointed to the master-node in a case of empty user input.
On the fuel-library side, we should only validate non-empty value and fall to error if empty.

Revision history for this message
Matthew Mosesohn (raytrac3r) wrote :

Vitaly, no, we should keep validating NTP servers. See my 2 patches on review.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-menu (master)

Reviewed: https://review.openstack.org/266285
Committed: https://git.openstack.org/cgit/openstack/fuel-menu/commit/?id=2a3775c4ed3c9bdbffdd14a59b70301709cc3efc
Submitter: Jenkins
Branch: master

commit 2a3775c4ed3c9bdbffdd14a59b70301709cc3efc
Author: Matthew Mosesohn <email address hidden>
Date: Tue Jan 12 13:43:06 2016 +0300

    Add note about Fuel Master being default NTP server

    Change-Id: I3e701ab12810874a25158375f07c441bf79fcfe4
    Partial-Bug: #1531185

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-menu (stable/8.0)

Fix proposed to branch: stable/8.0
Review: https://review.openstack.org/266965

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to fuel-web (stable/8.0)

Related fix proposed to branch: stable/8.0
Review: https://review.openstack.org/266995

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to fuel-web (stable/8.0)

Reviewed: https://review.openstack.org/266995
Committed: https://git.openstack.org/cgit/openstack/fuel-web/commit/?id=1c0f713999acbac09c6b36600f794bf57fd8c619
Submitter: Jenkins
Branch: stable/8.0

commit 1c0f713999acbac09c6b36600f794bf57fd8c619
Author: Julia Aranovich <email address hidden>
Date: Mon Jan 11 18:51:11 2016 +0300

    Fixes for environment settings validation on Networks and Settings tab

    * environment settings validated when opening Networks tab
    * network setting errors do not block Settings tab

    Related-Bug: #1531185

    Change-Id: I3b42b6af2a4382c804a68cbec6ae025a8cfad556

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to fuel-web (master)

Reviewed: https://review.openstack.org/265900
Committed: https://git.openstack.org/cgit/openstack/fuel-web/commit/?id=bb6ed8b7f7250db536c478fc2ce3654bca7c57ec
Submitter: Jenkins
Branch: master

commit bb6ed8b7f7250db536c478fc2ce3654bca7c57ec
Author: Julia Aranovich <email address hidden>
Date: Mon Jan 11 18:51:11 2016 +0300

    Fixes for environment settings validation on Networks and Settings tab

    * environment settings validated when opening Networks tab
    * network setting errors do not block Settings tab

    Related-Bug: #1531185

    Change-Id: I3b42b6af2a4382c804a68cbec6ae025a8cfad556

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-library (master)

Reviewed: https://review.openstack.org/266293
Committed: https://git.openstack.org/cgit/openstack/fuel-library/commit/?id=5ec28d2322f1b4430099b0304a581831605c13f4
Submitter: Jenkins
Branch: master

commit 5ec28d2322f1b4430099b0304a581831605c13f4
Author: Matthew Mosesohn <email address hidden>
Date: Tue Jan 12 13:53:37 2016 +0300

    Use Fuel Master for NTP if no NTP servers specified

    Nodes should sync time against Fuel Master if there are
    no NTP servers specified. This also fixes a UI bug in Fuel
    where the settings are invalid if there are no NTP servers.

    Change-Id: I50422de29badf91c7739c011844609131173e34e
    Partial-Bug: #1531185

Revision history for this message
Vitaly Kramskikh (vkramskikh) wrote :

UI patch is merged both to master and stalbe/8.0, library part misses stable/8.0 patch. Reassigning to the library team

tags: added: area-library
removed: area-ui
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-menu (stable/8.0)

Reviewed: https://review.openstack.org/266965
Committed: https://git.openstack.org/cgit/openstack/fuel-menu/commit/?id=6c1888a48e2c3244d7fdf6409c22874aac8a7495
Submitter: Jenkins
Branch: stable/8.0

commit 6c1888a48e2c3244d7fdf6409c22874aac8a7495
Author: Matthew Mosesohn <email address hidden>
Date: Tue Jan 12 13:43:06 2016 +0300

    Add note about Fuel Master being default NTP server

    Change-Id: I3e701ab12810874a25158375f07c441bf79fcfe4
    Partial-Bug: #1531185
    (cherry picked from commit 2a3775c4ed3c9bdbffdd14a59b70301709cc3efc)

Revision history for this message
Veronica Krayneva (vkrayneva) wrote :

Verified on #491 iso.

tags: added: on-verification
Revision history for this message
ElenaRossokhina (esolomina) wrote :

Verified on fuel-9.0-106-2016-03-24_02-00-00.iso

tags: removed: on-verification
Revision history for this message
Udayendu Kar (udayendu-kar) wrote :

I am also facing the same issue with Fuel 8.0 on VirtualBox setup:

Error
Deployment has failed. Method granular_deploy. Failed to execute hook 'ntp-check' Puppet run failed. Check puppet logs for details

---
uids:
- '1'
parameters:
  puppet_modules: /etc/puppet/modules
  puppet_manifest: /etc/puppet/modules/osnailyfacter/modular/ntp/ntp-check.pp
  timeout: 600
  cwd: /
priority: 200
fail_on_error: true
type: puppet
id: ntp-check
.
Inspect Astute logs for the details

Here is what my setup is:

   - From fuel menu, I have provided 3 NTP server IPs
   - During the network check I am able to see the success message
   - But deployment failed with " Deployment has failed. Method granular_deploy. Failed to execute hook 'ntp-check' Puppet run failed. Check puppet logs for details" error every time. All the nodes are able to access to internet.

Here are my queries:

   1. I have provided all 3 NTP servers name on FUEL MENU and save that with no error.
   2. I can see the correct entries for NTP servers in "/etc/fuel/astute.yaml" file.
   3. Network connection is also correct and all nodes have access to internet

But still the deployment failed with the below errors as mentioned in the log:

      Logs: http://paste.fedoraproject.org/356913/14609644/

Need some assistance on it so that I can make the setup ready. Fuel 8.0 is having few good features but NTP is a major issue still available since Fuel 7.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.