overcloud node delete needs to support deployed-server delete by hostname

Bug #1869089 reported by Steve Baker
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Incomplete
High
Rabi Mishra

Bug Description

The instructions for deployed-server scale-down[1] currently require doing a nested stack list then eye-parsing the output to figure out what uuid to pass to the node delete command.

When using baremetal provisioning, this is automated by _translate_nodes_to_resources[2] however this function will be removed on the assumption that the scale_down playbook will be modified to handle nodes specified as hostnames.

Currently it appears that node delete doesn't work for deployed-server when specifying by uuid[3] or hostname[4]. This bug can track supporting both.

[1] https://docs.openstack.org/project-deploy-guide/tripleo-docs/latest/features/deployed_server.html#scaling-down
[2] https://opendev.org/openstack/python-tripleoclient/src/commit/bd9302d5523855442dacf88add600a2f67b3a318/tripleoclient/v1/overcloud_node.py#L119
[3] http://paste.openstack.org/show/791162/
[4] http://paste.openstack.org/show/791164/

Revision history for this message
Rabi Mishra (rabi) wrote :

Would not it be better to change the documentation for deployed server scale down[1] above to create an environment with RemovalPolicies (with the to be blacklisted indexes) and use it rather than making an inefficient search for 'name' atrribute of the Deployedserver heat resource?

IMO, we should probably deprecate and remove the node delete command and ask users to use environments with RemovalPolicies.

The key issue with node delete is that, it internally calculates the role count and is different from the ones provided in env files or role_data and users have issues most of the time doing an update after scale down and failing if there are not enough baremetal nodes to provision.

Revision history for this message
Rabi Mishra (rabi) wrote :

I've submitted a WIP patch, if we still want to modify code to support host names. Not tested with deployed servers yet.

https://review.opendev.org/#/c/715129/

Changed in tripleo:
assignee: nobody → Rabi Mishra (rabi)
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-common (master)

Reviewed: https://review.opendev.org/715129
Committed: https://git.openstack.org/cgit/openstack/tripleo-common/commit/?id=be7c90e30c8a64969894fee8e424f665f1a5a00c
Submitter: Zuul
Branch: master

commit be7c90e30c8a64969894fee8e424f665f1a5a00c
Author: Rabi Mishra <email address hidden>
Date: Thu Mar 26 12:45:40 2020 +0530

    Match hostname when doing node delete

    ``overcloud node delete`` at present matches the provided nova
    instance ids with existing severs to build the heat blacklist.
    This patch would allow users to also use hostnames when deleting
    nodes. This will work with deployed servers and scale_playbook.yaml
    that matches host pattern.

    Partial-Bug: #1869089
    Change-Id: I3066689facc169125ade29156190cb98910f32b8

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-common (stable/train)

Fix proposed to branch: stable/train
Review: https://review.opendev.org/716468

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-common (stable/train)

Reviewed: https://review.opendev.org/716468
Committed: https://git.openstack.org/cgit/openstack/tripleo-common/commit/?id=56c0fd5cafc75b1a5197897551c2224e14acdcad
Submitter: Zuul
Branch: stable/train

commit 56c0fd5cafc75b1a5197897551c2224e14acdcad
Author: Rabi Mishra <email address hidden>
Date: Thu Mar 26 12:45:40 2020 +0530

    Match hostname when doing node delete

    ``overcloud node delete`` at present matches the provided nova
    instance ids with existing severs to build the heat blacklist.
    This patch would allow users to also use hostnames when deleting
    nodes. This will work with deployed servers and scale_playbook.yaml
    that matches host pattern.

    Partial-Bug: #1869089
    Change-Id: I3066689facc169125ade29156190cb98910f32b8
    (cherry picked from commit be7c90e30c8a64969894fee8e424f665f1a5a00c)

tags: added: in-stable-train
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to python-tripleoclient (master)

Related fix proposed to branch: master
Review: https://review.opendev.org/717183

wes hayutin (weshayutin)
Changed in tripleo:
milestone: ussuri-3 → ussuri-rc3
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-common (stable/stein)

Fix proposed to branch: stable/stein
Review: https://review.opendev.org/725608

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-common (stable/rocky)

Fix proposed to branch: stable/rocky
Review: https://review.opendev.org/725609

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tripleo-common (stable/queens)

Fix proposed to branch: stable/queens
Review: https://review.opendev.org/725620

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-common (stable/stein)

Reviewed: https://review.opendev.org/725608
Committed: https://git.openstack.org/cgit/openstack/tripleo-common/commit/?id=f6e3041291f2fdf082065aae1b80ee79a5870142
Submitter: Zuul
Branch: stable/stein

commit f6e3041291f2fdf082065aae1b80ee79a5870142
Author: Rabi Mishra <email address hidden>
Date: Thu Mar 26 12:45:40 2020 +0530

    Match hostname when doing node delete

    ``overcloud node delete`` at present matches the provided nova
    instance ids with existing severs to build the heat blacklist.
    This patch would allow users to also use hostnames when deleting
    nodes. This will work with deployed servers and scale_playbook.yaml
    that matches host pattern.

    Partial-Bug: #1869089
    Change-Id: I3066689facc169125ade29156190cb98910f32b8
    (cherry picked from commit be7c90e30c8a64969894fee8e424f665f1a5a00c)
    (cherry picked from commit 56c0fd5cafc75b1a5197897551c2224e14acdcad)

tags: added: in-stable-stein
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-common (stable/rocky)

Reviewed: https://review.opendev.org/725609
Committed: https://git.openstack.org/cgit/openstack/tripleo-common/commit/?id=ee6358f9e8aeb03b10c53bbb78eaf059f697cefd
Submitter: Zuul
Branch: stable/rocky

commit ee6358f9e8aeb03b10c53bbb78eaf059f697cefd
Author: Rabi Mishra <email address hidden>
Date: Thu Mar 26 12:45:40 2020 +0530

    Match hostname when doing node delete

    ``overcloud node delete`` at present matches the provided nova
    instance ids with existing severs to build the heat blacklist.
    This patch would allow users to also use hostnames when deleting
    nodes. This will work with deployed servers and scale_playbook.yaml
    that matches host pattern.

    Partial-Bug: #1869089
    Change-Id: I3066689facc169125ade29156190cb98910f32b8
    (cherry picked from commit be7c90e30c8a64969894fee8e424f665f1a5a00c)
    (cherry picked from commit 56c0fd5cafc75b1a5197897551c2224e14acdcad)

tags: added: in-stable-rocky
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-common (stable/queens)

Reviewed: https://review.opendev.org/725620
Committed: https://git.openstack.org/cgit/openstack/tripleo-common/commit/?id=927583ded34aa62c6c8220ed3e37a816454b40bb
Submitter: Zuul
Branch: stable/queens

commit 927583ded34aa62c6c8220ed3e37a816454b40bb
Author: Rabi Mishra <email address hidden>
Date: Thu Mar 26 12:45:40 2020 +0530

    Match hostname when doing node delete

    ``overcloud node delete`` at present matches the provided nova
    instance ids with existing severs to build the heat blacklist.
    This patch would allow users to also use hostnames when deleting
    nodes. This will work with deployed servers and scale_playbook.yaml
    that matches host pattern.

    Partial-Bug: #1869089
    Depends-On: https://review.opendev.org/727696
    Change-Id: I3066689facc169125ade29156190cb98910f32b8
    (cherry picked from commit be7c90e30c8a64969894fee8e424f665f1a5a00c)
    (cherry picked from commit 56c0fd5cafc75b1a5197897551c2224e14acdcad)

tags: added: in-stable-queens
wes hayutin (weshayutin)
Changed in tripleo:
milestone: ussuri-rc3 → victoria-1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on python-tripleoclient (master)

Change abandoned by Rabi Mishra (<email address hidden>) on branch: master
Review: https://review.opendev.org/717183

Changed in tripleo:
milestone: victoria-1 → victoria-3
Changed in tripleo:
milestone: victoria-3 → wallaby-1
Changed in tripleo:
milestone: wallaby-1 → wallaby-2
Changed in tripleo:
milestone: wallaby-2 → wallaby-3
Changed in tripleo:
milestone: wallaby-3 → wallaby-rc1
Changed in tripleo:
milestone: wallaby-rc1 → xena-1
Revision history for this message
Marios Andreou (marios-b) wrote :

This is an automated action. Bug status has been set to 'Incomplete' and target milestone has been removed due to inactivity. If you disagree please re-set these values and reach out to us on freenode #tripleo

Changed in tripleo:
milestone: xena-1 → none
status: In Progress → Incomplete
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.