Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
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.
Description of problem: If a user gives pcs options in the wrong order, the resulting error message does not suggest what the problem is.
Version-Release number of selected component (if applicable):
How reproducible: trivially
Steps to Reproduce:
1. pcs resource create res_A ocf:pacemaker:Dummy --clone op monitor interval=30s
Actual results:
Error: When using 'op' you must specify an operation name and at least one option
Expected results:
A more helpful error message
I tried to run the reproducer but the command worked correctly.
[vm-rhel72-1 ~] $ rpm -q pcs
pcs-0.9.157-1.el7.x86_64
[vm-rhel72-1 ~] $ pcs resource create res_A ocf:pacemaker:Dummy --clone op monitor interval=30s
[vm-rhel72-1 ~] $ pcs resource
Clone Set: res_A-clone [res_A]
Started: [ vm-rhel72-1 vm-rhel72-3 ]
Then I tried to downgrade pcs and I get the expected error:
[vm-rhel72-1 ~] $ rpm -q pcs
pcs-0.9.143-15.el7.x86_64
[vm-rhel72-1 ~] $ pcs resource create res_B ocf:pacemaker:Dummy --clone op monitor interval=30s
Error: When using 'op' you must specify an operation name and at least one option
Command works correctly with the current upstream as well.
What version of pcs do you use? Can you try upgrade pcs and launch command on it?
The command `pcs resource create` was (relatively) recently overhauled (it should be in the rhel7.4 builds already). So I guess the problem should be only in the older versions of pcs.
I see that exactly this bug was fixed: bz1395226 (see: Flag --clone steals options of the "op" keyword when "--clone" precedes "op".).
The problem was that pcs lacked the required `op` arguments: name and at least one option. Because flag `--clone` stole it. So the message was correct.