After deletion of 2 controllers from HA-cluster /etc/hosts wasn't cleaned up

Bug #1513401 reported by Vladimir Khlyunev
30
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Committed
High
Matthew Mosesohn
8.0.x
Won't Fix
High
Fuel Python (Deprecated)
Mitaka
Fix Released
High
Matthew Mosesohn

Bug Description

I got this bug on iso 7.0-301 + MU1, but clear 7.0-301 can be affected too.

Steps to reproduce:
1) Deploy cluster: 3 controllers + 1 compute, Neutron VLAN
2) Remove 2 controllers, re-deploy
3) Check hosts /etc/hosts on all nodes
4) Run OSTF

Result:
/etc/hosts on remaining nodes wasn't changed
also nodes became unavailable by dns name

I will keep my env - feel free to request it

Revision history for this message
Vladimir Khlyunev (vkhlyunev) wrote :
description: updated
summary: - After deletion of 2 nodes from HA-cluster several errors occures (OSTF
- test failure, /etc/hosts wasn't cleaned up, nova-service doesn't
+ After deletion of 2 controllers from HA-cluster several errors occures
+ (OSTF test failure, /etc/hosts wasn't cleaned up, nova-service doesn't
migrated)
summary: - After deletion of 2 controllers from HA-cluster several errors occures
- (OSTF test failure, /etc/hosts wasn't cleaned up, nova-service doesn't
- migrated)
+ After deletion of 2 controllers from HA-cluster s/etc/hosts wasn't
+ cleaned up
description: updated
Revision history for this message
Matthew Mosesohn (raytrac3r) wrote : Re: After deletion of 2 controllers from HA-cluster s/etc/hosts wasn't cleaned up

nodes that are being deleted are not included in astute.yaml, so the hosts.pp granular module cannot delete these entries. It can only add entries for those nodes that are present in astute.yaml.

We could try to introduce an array of hosts that are being deleted so we can perform whatever cleanup tasks are necessary. I believe it needs an entire "nodes hash" for each one, just so we can identify its roles, ips, network roles, etc, and ensure all proper migrations can take place.

Revision history for this message
Dmitry Klenov (dklenov) wrote :

Matthew, do you see feasible to perform 'set' operation for /etc/hosts file and put only hosts available in astute.yaml there? opposing to apply 'add' / 'delete' operations for new / obsolete hosts correspondingly.

tags: added: area-library
tags: added: life-cycle-management
Dmitry Pyzhov (dpyzhov)
no longer affects: fuel/8.0.x
Dmitry Klenov (dklenov)
Changed in fuel:
status: New → Confirmed
Revision history for this message
Andrey Sledzinskiy (asledzinskiy) wrote :

There are also problem after adding new controllers with getting these nodes by dns names:
Steps to reproduce:
1) Deploy cluster: 1 controller + 1 compute, Neutron VLAN
2) Add 2 controllers, re-deploy

Actual result - /etc/hosts was updated on all nodes but nodes aren't available by dns names

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

Andrey, that's related to a different bug with Fuel Master patching. Your steps aren't going to cause that bug.

Revision history for this message
Andrey Sledzinskiy (asledzinskiy) wrote :

Please, disregard my comment, it was env problem

tags: added: 70-mu1-new-bug
Revision history for this message
Michael Polenchuk (mpolenchuk) wrote :

* Nailgun should inject info of removed nodes as well (orchestrator/tasks_serializer.py (class UploadNodesInfo))
* Modify osnailyfacter/modular/hosts/hosts.pp to handle removed nodes

Changed in fuel:
assignee: Fuel Library Team (fuel-library) → Michael Polenchuk (mpolenchuk)
Changed in fuel:
status: Confirmed → In Progress
Revision history for this message
Stanislaw Bogatkin (sbogatkin) wrote :
Revision history for this message
Vitaly Sedelnik (vsedelnik) wrote :

Won't Fix for 7.0-updates because of Medium importance

Changed in fuel:
assignee: Michael Polenchuk (mpolenchuk) → Bogdan Dobrelya (bogdando)
Revision history for this message
Bogdan Dobrelya (bogdando) wrote :

The fix got stuck, fuel-web folks please merge the dependency

tags: added: area-python
removed: area-library
Changed in fuel:
assignee: Bogdan Dobrelya (bogdando) → Fuel Python Team (fuel-python)
status: In Progress → New
Ilya Kutukov (ikutukov)
Changed in fuel:
status: New → Confirmed
Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Michael Polenchuk (mpolenchuk)
status: Confirmed → In Progress
Changed in fuel:
assignee: Michael Polenchuk (mpolenchuk) → Fuel Python Team (fuel-python)
Changed in fuel:
status: In Progress → Confirmed
Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Michael Polenchuk (mpolenchuk)
status: Confirmed → In Progress
Revision history for this message
Dmitry Pyzhov (dpyzhov) wrote :

Moved to 9.0 because of SCF in 8.0

Changed in fuel:
milestone: 8.0 → 9.0
no longer affects: fuel/7.0.x
Changed in fuel:
assignee: Michael Polenchuk (mpolenchuk) → Fuel Python Team (fuel-python)
status: In Progress → Confirmed
Revision history for this message
Vladimir Khlyunev (vkhlyunev) wrote :

Wont fix - medium but after SCF.

Dmitry Pyzhov (dpyzhov)
no longer affects: fuel/mitaka
summary: - After deletion of 2 controllers from HA-cluster s/etc/hosts wasn't
+ After deletion of 2 controllers from HA-cluster /etc/hosts wasn't
cleaned up
Revision history for this message
Nastya Urlapova (aurlapova) wrote :

@Dima, it is not Medium issue, because as you can see also from #4 other scenarios are affected. We can put into MU1?

Changed in fuel:
importance: Medium → High
Revision history for this message
Dmitry Pyzhov (dpyzhov) wrote :

@Nastya, comment #4 is not applicable to this bug, see comment #6. Moving the bug back to medium. Also we have very small chance to successfully backport fixes related to lifecycle management because this feature is in active development and doesn't present in previous releases.

Changed in fuel:
importance: High → Medium
tags: added: release-notes
tags: added: 8.0 release-notes-done
removed: release-notes
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on fuel-library (master)

Change abandoned by Michael Polenchuk (<email address hidden>) on branch: master
Review: https://review.openstack.org/245169
Reason: outdated

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on fuel-web (master)

Change abandoned by Michael Polenchuk (<email address hidden>) on branch: master
Review: https://review.openstack.org/245135
Reason: outdated

Revision history for this message
Bug Checker Bot (bug-checker) wrote : Autochecker

(This check performed automatically)
Please, make sure that bug description contains the following sections filled in with the appropriate data related to the bug you are describing:

actual result

expected result

For more detailed information on the contents of each of the listed sections see https://wiki.openstack.org/wiki/Fuel/How_to_contribute#Here_is_how_you_file_a_bug

tags: added: need-info
tags: added: keep-in-9.0
Changed in fuel:
importance: Medium → High
Revision history for this message
Dmitry Pyzhov (dpyzhov) wrote :

Leaving as "Won't fix" for 8.0 because fix depends on new task based deployment feature.

Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Alexander Kislitsky (akislitsky)
Changed in fuel:
milestone: 9.0 → 10.0
Revision history for this message
Alexander Kislitsky (akislitsky) wrote :

Fix should be done by introducing yaql based task which stores removed nodes hash. After that /etc/hosts can be fixed on the all nodes on the library side. Reassigning to Matthew.

Changed in fuel:
assignee: Alexander Kislitsky (akislitsky) → Matthew Mosesohn (raytrac3r)
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/309319

Changed in fuel:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-library (master)

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

commit eacb493e38a31747dc61a43a081adf00adbeb8eb
Author: Matthew Mosesohn <email address hidden>
Date: Fri Apr 22 12:43:04 2016 +0300

    Purge deleted /etc/hosts entries for deleted ndoes

    Deleted nodes now will get stored in a file
    /etc/hiera/deleted_nodes.yaml and be inserted into
    the hiera hierarchy.

    host entries for any records present in deleted_nodes.yaml
    will be purged when evaluating hosts task.

    The source YAML for deleted nodes is generated on master
    because nodes that are deployed from scratch or from Error
    state will not be able to identify deleted nodes due to
    certain orchestration limitations.

    Change-Id: I01db215e77a3532a6fa7bf46ab7e20e281e8c165
    Closes-Bug: #1513401

Changed in fuel:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-library (stable/mitaka)

Fix proposed to branch: stable/mitaka
Review: https://review.openstack.org/315684

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

Reviewed: https://review.openstack.org/315684
Committed: https://git.openstack.org/cgit/openstack/fuel-library/commit/?id=c923fb21ef584e2e09bd4c514f01872d3874abac
Submitter: Jenkins
Branch: stable/mitaka

commit c923fb21ef584e2e09bd4c514f01872d3874abac
Author: Matthew Mosesohn <email address hidden>
Date: Fri Apr 22 12:43:04 2016 +0300

    Purge deleted /etc/hosts entries for deleted ndoes

    Deleted nodes now will get stored in a file
    /etc/hiera/deleted_nodes.yaml and be inserted into
    the hiera hierarchy.

    host entries for any records present in deleted_nodes.yaml
    will be purged when evaluating hosts task.

    The source YAML for deleted nodes is generated on master
    because nodes that are deployed from scratch or from Error
    state will not be able to identify deleted nodes due to
    certain orchestration limitations.

    Change-Id: I01db215e77a3532a6fa7bf46ab7e20e281e8c165
    Closes-Bug: #1513401
    (cherry picked from commit eacb493e38a31747dc61a43a081adf00adbeb8eb)

Egor Kotko (ykotko)
tags: added: on-verification
Revision history for this message
Egor Kotko (ykotko) wrote :
Revision history for this message
Oleksiy Molchanov (omolchanov) wrote :

Verified on #465. Passed.

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

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