-
Story
-
Resolution: Unresolved
-
Normal
-
rhel-9.0.0
-
Moderate
-
FutureFeature
-
rhel-ha
-
0
-
False
-
False
-
-
None
-
None
-
None
-
None
-
If docs needed, set a value
-
-
Unspecified
-
None
-
57,005
Description of problem:
There are no error checks or warnings when setting invalid resource meta attributes. This can lead to unexpected behaviors for users who believed they set a valid option.
Version-Release number of selected component (if applicable):
$ rpm -q pcs
pcs-0.10.8-1.el8.x86_64
How reproducible:
Set an invalid meta attribute to either a specific resource or for resource defaults:
[root@clusterb-rhel8 ~]# pcs resource defaults update resource-sti=1000 Warning: Defaults do not apply to resources which override them with their own defined values [root@clusterb-rhel8 ~]# pcs resource update dummy1 meta resource-sti=100
Actual results:
This results in an update to the configuration, but the values won't actually do anything since the attribute are invalid:
[root@clusterb-rhel8 ~]# pcs config ---------------->8-------------------- Resources: Resource: dummy1 (class=ocf provider=heartbeat type=Dummy) Attributes: fake=1 Meta Attrs: resource-sti=100 ---------------->8-------------------- Resources Defaults: Meta Attrs: rsc_defaults-meta_attributes resource-sti=1000 resource-stickiness=1000
Expected results:
A warning or error that prevents an update to configuration, and requests additional "--force" option to set invalid values.
Note:
If pcs is going to be validating values of meta attributes, make sure to check whether they are case sensitive or not. See RHEL-92043. Note that in RHEL-23401, pacemaker implemented a listing of valid meta attribute names and values, and there is no indication whether they are case sensitive or insensitive. Pcs might need to normalize values to expected case before validating them and storing them to CIB. Pcs itself, however, should be kept case insensitive itself with respect to these so that backward compatibility is kept.
Implementation note:
- This applies to only primitives.
- Dev team decided to add this to `pcs resource meta`, `pcs resource create` and `pcs resource defaults` commands.
- For the command `pcs resource update` there will be only added warning message that it is not validated and for validation the command `pcs resource meta` should be used
- Also the behaviour of `pcs resource update` will be described in help and man page.
- blocks
-
RHEL-12197 [RFE] Only allow setting resource meta attributes which are valid Rhel 9
-
- Closed
-
- is blocked by
-
RHEL-7691 [RFE] Provide meta-attributes definition, ideally in OCF-like format
-
- Closed
-
-
RHEL-7702 Both pacemaker-controld and pacemaker-schedulerd metadata contains 'no-quorum-policy' cluster property
-
- Closed
-
-
RHEL-23401 Create command-line method of listing all possible cluster options, primitive meta-attributes, and special fencing resource parameters
-
- Closed
-
- is duplicated by
-
RHEL-12197 [RFE] Only allow setting resource meta attributes which are valid Rhel 9
-
- Closed
-
- relates to
-
RHEL-92043 'pcs resource delete' fails when target-role is not capitalized properly [rhel-10]
-
- Release Pending
-
- external trackers