Bug 1995419

Summary: fence_watchdog has invalid metadata
Product: Red Hat Enterprise Linux 8 Reporter: Madison Kelly <mkelly>
Component: pacemakerAssignee: Klaus Wenninger <kwenning>
Status: CLOSED DUPLICATE QA Contact: cluster-qe <cluster-qe>
Severity: medium Docs Contact:
Priority: unspecified    
Version: CentOS StreamCC: bstinson, cluster-maint, jwboyer, kgaillot, kwenning, nwahl
Target Milestone: betaFlags: pm-rhel: mirror+
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-08-20 14:47:45 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Madison Kelly 2021-08-19 04:42:39 UTC
Description of problem:

'fence_watchdog -o metadata' returns malformed XML, specifically;

====
<?xml version="1.0" ?>
<resource-agent name="fence_watchdog" shortdesc="Dummy watchdog fence agent">
<longdesc>fence_watchdog just provides
meta-data - actual fencing is done by the pacemaker internal watchdog agent.</longdesc>
<parameters>
    <parameter name="actionrequired="1">
      <getopt mixed="-o, --action=[action]" />
      <content type="string" default="metadata" />
      <shortdesc lang="en">Fencing Action</shortdesc>
    </parameter>
    <parameter name="nodenamerequired="0">
      <getopt mixed="-N, --nodename" />
      <content type="string"  />
      <shortdesc lang="en">Ignored</shortdesc>
    </parameter>
    <parameter name="plugrequired="1">
      <getopt mixed="-n, --plug=[id]" />
      <content type="string"  />
      <shortdesc lang="en">Ignored</shortdesc>
    </parameter>
    <parameter name="versionrequired="0">
      <getopt mixed="-V, --version" />
      <content type="boolean"  />
      <shortdesc lang="en">Display version information and exit</shortdesc>
    </parameter>
    <parameter name="helprequired="0">
      <getopt mixed="-h, --help" />
      <content type="boolean"  />
      <shortdesc lang="en">Display help and exit</shortdesc>
    </parameter>
  </parameters>
 <actions>
    <action name="on" />
    <action name="off" />
    <action name="reboot" />
    <action name="monitor" />
    <action name="list" />
    <action name="metadata" />
  </actions>
</resource-agent>
====

The '<parameter name="x="y"> appears in all instances, likely a parse error.

Version-Release number of selected component (if applicable):

pacemaker-2.1.0-5.el8.x86_64


How reproducible:

100%


Steps to Reproduce:
1. Call 'fence_watchdog -o metadata'
2.
3.

Actual results:

Malformed XML.


Expected results:

Well-formed XML.


Additional info:

Comment 1 Klaus Wenninger 2021-08-19 07:38:51 UTC
https://github.com/ClusterLabs/pacemaker/pull/2482

Comment 2 Ken Gaillot 2021-08-20 14:47:45 UTC
Since this feature hasn't been tested or released in RHEL yet, I'm going to close this as a duplicate of the feature bz for bookkeeping purposes. I'll add a note there to verify the meta-data.

The fix will land in both RHEL 8.5 and CentOS Stream 8 as of build pacemaker-2.1.0-8.el8

*** This bug has been marked as a duplicate of bug 1443666 ***