Description of problem: The hacluster pmda in pcp executes the "crm_mon -X --inactive" command to retrieve cluster information. In RHEL 9.x, the format of the output of that command has changed somewhat, as compared to previous versions. Due to this, the PMDA does not process this data correctly, and returns incorrect data. Version-Release number of selected component (if applicable): 9.2 How reproducible: 100% Steps to Reproduce: 1.set up RHEL 9.2 cluster 2.set up pcp, pmproxy, and hacluster PMDA 3. perform curl http://localhost:44322/metrics?names=ha_cluster| grep ha_cluster_pacemaker_nodes_status_dc Actual results: # TYPE ha_cluster_pacemaker_nodes_status_dc gauge ha_cluster_pacemaker_nodes_status_dc{hostname="rh9dhdb00l1c0",instname="rh9dhdb00l0c0",machineid="dc7028ce53a64b0bba7d52ee52cf568a",domainname="localdomain",instid="0"} 0 ha_cluster_pacemaker_nodes_status_dc{hostname="rh9dhdb00l1c0",instname="rh9dhdb00l1c0",machineid="dc7028ce53a64b0bba7d52ee52cf568a",domainname="localdomain",instid="1"} 0 Expected results: since every cluster has one DC, the command in #3 should return at least one line that has value of 1 Additional info: "crm_mon -C --inactive" is now returning some extra fields "health" and "feature_set": <node name="rh9dhdb00l0c0" id="1" online="true" standby="false" standby_onfail="false" maintenance="false" pending="false" unclean="false" health="green" feature_set="3.16.2" shutdown="false" expected_up="true" is_dc="false" resources_running="5" type="member"/> The processing of these in the pmda pacemaker.c has not taken into account these new fields (see line 537 in https://github.com/performancecopilot/pcp/blob/177b3d6294eb6b6bc3e2d9dcafdc09b6930554af/src/pmdas/hacluster/pacemaker.c).
Thanks Ross, yep, looks like we have some work to do here. I've CC'd my colleague Paul Evans who knows this code best for his input. One thing we'll need will be captured output of the command in the updated format to use in PCP regression test qa/1897 (in the pcp github repo) - in the form of qa/hacluster/hacluster-root-001.tgz there. Paul, do you have a hacluster test setup handy where you can capture that? And do you have cycles to update the code? (I can help with that if needed once we have the test data to work with). cheers.
I have a 9.2 cluster that I've been testing with, and I put sample output from crm_mon -X in a github repo here: https://bugzilla.redhat.com/show_bug.cgi?id=2216308 I threw together a little program (in the github) to test this out, and updated for the 9.2 output. Let me know if there is anything I can do to help, since getting this corrected is pretty important for our support of RHEL 9.2 in Azure Monitor for SAP Solutions.
sorry here is my github: https://github.com/rsponholtz/pmtest
Thanks Ross. I'm away until July 3rd so I am hoping Paul has some cycles to make progress while I'm away. Otherwise I'll take you up on that kind offer for assistance and work with you to get this resolved shortly after I return.
Hi Nathan, Ross. It looks like pacemaker 2.1.5 added the extra fields to the output from crm_mon which causes the issue for collecting the ha_cluster_pacemaker_nodes_status_dc. I've attached a patch which will fix this issue for RHEL 9.2 (I believe this could be an issue in RHEL8.8 also). I've provided a merge-request for upstream also to fix this issue. Regards, Paul.
(In reply to Paul Evans from comment #5) > Hi Nathan, Ross. > > It looks like pacemaker 2.1.5 added the extra fields to the output from > crm_mon > which causes the issue for collecting the > ha_cluster_pacemaker_nodes_status_dc. > I've attached a patch which will fix this issue for RHEL 9.2 (I believe this > could be an issue in RHEL8.8 also). > > I've provided a merge-request for upstream also to fix this issue. > > Regards, > > Paul. Hi, Where do we find the attached patch? I don't see an attachment to the BZ. Thanks! Ralitza
Hi Ralitza, you can find Paul's latest updates here: https://github.com/performancecopilot/pcp/pull/1770
Verifying using the upstream testsuite.