RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1517333 - 'pcs cluster auth' fails if an empty nodelist is configured in corosync
Summary: 'pcs cluster auth' fails if an empty nodelist is configured in corosync
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: pcs
Version: 7.5
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: rc
: ---
Assignee: Tomas Jelinek
QA Contact: cluster-qe@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-11-24 15:41 UTC by Tomas Jelinek
Modified: 2018-10-30 08:06 UTC (History)
6 users (show)

Fixed In Version: pcs-0.9.165-1.el7
Doc Type: Bug Fix
Doc Text:
Cause: The user runs 'pcs cluster auth' in a situation when corosync.conf exists but does not list any nodes due to it being edited by other means than pcs. Consequence: Pcs reports success, however nodes are not authenticated. Fix: If no nodes are defined in corosync.conf, save auth tokens on the local node only. Do not send them to an empty list of nodes. Result: 'pcs cluster auth' works.
Clone Of:
Environment:
Last Closed: 2018-10-30 08:05:31 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
proposed fix (4.45 KB, patch)
2017-12-13 14:24 UTC, Tomas Jelinek
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Github ClusterLabs pcs issues 153 0 None closed error checking node availability: Unable to authenticate in debian stretch 2020-12-10 13:49:48 UTC
Red Hat Product Errata RHBA-2018:3066 0 None None None 2018-10-30 08:06:10 UTC

Description Tomas Jelinek 2017-11-24 15:41:02 UTC
Description of problem:
* [nodeA]# pcs cluster auth nodeB nodeC
* pcs connects to nodes and authenticates without an issue
* if corosync is not configured on nodeA, pcs saves tokens to a file
* if corosync is configured on nodeA, pcs gets its nodelist and sends token to nodes in the nodelist
* if the nodelist is empty, tokens are discarded, which means nodes are not authenticated -> bug


How reproducible:
always, easily


Steps to Reproduce:
1. setup corosync with an empty nodelist
2. pcs cluster auth


Actual results:
nodes not authenticated


Expected results:
nodes or at least the local node authenticated

Comment 1 Tomas Jelinek 2017-12-13 14:24:15 UTC
Created attachment 1367416 [details]
proposed fix

Pcs always populates nodelist in corosync.conf so usually there should not be any issue. However, corrupted or manually edited corosync.conf should not cause that 'pcs cluster auth' does not work.

Test:
1. Remove or empty nodelist in /etc/corosync/corosync.conf on all nodes you want to authenticate (rh74-node1 rh74-node2).
2. Remove auth tokens on all nodes: pcs pcsd clear-auth
3. Authenticate the nodes: pcs cluster auth rh74-node1 rh74-node2
4. Check nodes status: pcs status pcsd rh74-node1 rh74-node2

Before fix:
# pcs status pcsd rh74-node1 rh74-node2                               
  rh74-node2: Unable to authenticate
  rh74-node1: Unable to authenticate
Nodes not authenticated even though 'pcs cluster auth' reported otherwise.

After fix:
# pcs status pcsd rh74-node1 rh74-node2
  rh74-node1: Online
  rh74-node2: Online

Comment 3 Ivan Devat 2018-06-22 12:15:24 UTC
After Fix:

[ant ~] $ rpm -q pcs pcs-snmp
pcs-0.9.165-1.el7.x86_64
pcs-snmp-0.9.165-1.el7.x86_64


[ant ~] $ cat /etc/corosync/corosync.conf|grep nodelist
[ant ~] $ pcs pcsd clear-auth
[ant ~] $ pcs cluster auth ant bee
Username: hacluster
Password:
ant: Authorized
bee: Authorized
[ant ~] $ pcs status pcsd ant bee
  ant: Online
  bee: Online

Comment 7 errata-xmlrpc 2018-10-30 08:05:31 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:3066


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