list_nodes() shouldn't return pacemaker remote nodes

Bug #1995295 reported by Corey Bryant
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack HA Cluster Charm
Fix Committed
Undecided
Unassigned

Bug Description

The new behavior of list_nodes() has changed and it is returning pacemaker-remote nodes for >= jammy that weren't returned in the past. list_nodes() should only return the hacluster nodes for >= jammy.

== focal ==

$ sudo crm node status
<nodes>
  <node id="1000" uname="juju-d3a5e7-zaza-9181f084d303-13"/>
  <node id="1001" uname="juju-d3a5e7-zaza-9181f084d303-14"/>
  <node id="1002" uname="juju-d3a5e7-zaza-9181f084d303-12"/>
</nodes>

== jammy ==

$ sudo crm node show
juju-108b5d-zaza-efda5e75c553-10.project.serverstack: member
        remote_node: true
        in_ccm: true
        crm-debug-origin: do_update_resource
        node_fenced: 0
juju-108b5d-zaza-efda5e75c553-12(1000): member
juju-108b5d-zaza-efda5e75c553-13(1001): member
juju-108b5d-zaza-efda5e75c553-14(1002): member
juju-108b5d-zaza-efda5e75c553-8.project.serverstack: member
        remote_node: true
        in_ccm: true
        crm-debug-origin: do_update_resource
        node_fenced: 0
juju-108b5d-zaza-efda5e75c553-9.project.serverstack: member
        remote_node: true
        in_ccm: true
        crm-debug-origin: do_update_resource
        node_fenced: 0

description: updated
description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to charm-hacluster (master)
Changed in charm-hacluster:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to charm-hacluster (master)

Reviewed: https://review.opendev.org/c/openstack/charm-hacluster/+/863138
Committed: https://opendev.org/openstack/charm-hacluster/commit/a03b0b2a87e8667da2f43c4e5f827d9ff8843307
Submitter: "Zuul (22348)"
Branch: master

commit a03b0b2a87e8667da2f43c4e5f827d9ff8843307
Author: Corey Bryant <email address hidden>
Date: Tue Nov 1 11:53:21 2022 +0100

    Only return hacluster nodes from list_nodes()

    list_nodes() recently had some changes to run 'crm node show'
    in jammy+ instead of 'crm node status'. The difference is that
    'crm node show' returns the pacemaker-remote nodes in addition
     to the hacluster nodes. This change limits the nodes returned
    by list_nodes() to the hacluster nodes (ie. the nodes that
    have a node ID).

    Closes-Bug: #1995295
    Change-Id: Ia405d4270f56c949f79167f8b75c1304b598b918

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

Fix proposed to branch: stable/jammy
Review: https://review.opendev.org/c/openstack/charm-hacluster/+/863262

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to charm-hacluster (stable/jammy)

Reviewed: https://review.opendev.org/c/openstack/charm-hacluster/+/863262
Committed: https://opendev.org/openstack/charm-hacluster/commit/5825fbae2e2be50613f64d160e84655d6c828acb
Submitter: "Zuul (22348)"
Branch: stable/jammy

commit 5825fbae2e2be50613f64d160e84655d6c828acb
Author: Corey Bryant <email address hidden>
Date: Tue Nov 1 11:53:21 2022 +0100

    Only return hacluster nodes from list_nodes()

    list_nodes() recently had some changes to run 'crm node show'
    in jammy+ instead of 'crm node status'. The difference is that
    'crm node show' returns the pacemaker-remote nodes in addition
     to the hacluster nodes. This change limits the nodes returned
    by list_nodes() to the hacluster nodes (ie. the nodes that
    have a node ID).

    Closes-Bug: #1995295
    Change-Id: Ia405d4270f56c949f79167f8b75c1304b598b918
    (cherry picked from commit a03b0b2a87e8667da2f43c4e5f827d9ff8843307)

tags: added: in-stable-jammy
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.