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 2166289 - [RFE] Provide means to export configured cluster properties as pcs commands
Summary: [RFE] Provide means to export configured cluster properties as pcs commands
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: pcs
Version: 8.9
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: 8.9
Assignee: Miroslav Lisik
QA Contact: cluster-qe
Steven J. Levine
URL:
Whiteboard:
Depends On: 2163914
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-02-01 12:43 UTC by Tomas Jelinek
Modified: 2023-11-14 15:54 UTC (History)
10 users (show)

Fixed In Version: pcs-0.10.17-1.el8
Doc Type: Enhancement
Doc Text:
.Enhancements to the `pcs property` command The `pcs property` command now supports the following enhancements: * The `pcs property config --output-format=` option ** Specify `--output-format=cmd` to display the `pcs property set` command created from the current cluster properties configuration. You can use this command to re-create configured cluster properties on a different system. ** Specify `--output-format=json` to display the configured cluster properties in JSON format. ** Specify `output-format=text` to display the configured cluster properties in plain text format, which is the default value for this option. * The `pcs property defaults` command, which replaces the deprecated `pcs property --defaults` option * The `pcs property describe` command, which describes the meaning of cluster properties.
Clone Of: 2163914
Environment:
Last Closed: 2023-11-14 15:22:35 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker CLUSTERQE-6613 0 None None None 2023-04-19 21:52:40 UTC
Red Hat Issue Tracker RHELPLAN-147273 0 None None None 2023-02-01 12:44:09 UTC
Red Hat Product Errata RHBA-2023:6903 0 None None None 2023-11-14 15:23:35 UTC

Description Tomas Jelinek 2023-02-01 12:43:21 UTC
+++ This bug was initially created as a clone of Bug #2163914 +++

This is a part of a long term goal to export the whole cluster configuration in form of pcs commands which, when run, recreate the same configuration.

This particular BZ is focused on cluster properties configuration.

Comment 1 Tomas Jelinek 2023-05-19 15:41:13 UTC
Upstream patch: https://github.com/ClusterLabs/pcs/commit/d5642c2ede0d6555603bc385dc35e581d2f0fddd

Updated commands:
* pcs property [config]

Added commands:
* pcs property defaults
* pcs property describe

Environment: A running cluster with some configured properties.

Test:

# pcs property set placement-strategy=minimal
# pcs property config --output-format=cmd
pcs property set --force -- \
  placement-strategy=minimal
# pcs property defaults placement-strategy
placement-strategy=default
# pcs property describe placement-strategy
placement-strategy
  Description: How the cluster should allocate resources to nodes
  Allowed values: 'balanced', 'default', 'minimal', 'utilization'
  Default: default

Comment 3 Michal Pospisil 2023-05-29 10:09:53 UTC
DevTestResults:

[root@r08-09-a ~]# rpm -q pcs
pcs-0.10.16-1.el8.x86_64

[root@r08-09-a ~]# pcs property set placement-strategy=minimal

[root@r08-09-a ~]# pcs property config --output-format=cmd
pcs property set --force -- \
  placement-strategy=minimal

Comment 7 Michal Mazourek 2023-06-13 09:32:00 UTC
As discussed, 'pcs property config' text output should not change in late RHEL8 release.

Comment 9 Miroslav Lisik 2023-06-19 12:17:51 UTC
Upstream patch: https://github.com/ClusterLabs/pcs/commit/88f57a99be1abba795c0b95f88f2f9930d26ec15

Updated commands:
* pcs property [config]
* pcs config

Environment: A running cluster with some configured properties.

Test:
# pcs property
Cluster Properties:
 cluster-infrastructure: corosync
 cluster-name: HACluster
 dc-version: 2.1.6-1.el8-6fdc9deea29
 have-watchdog: false

# pcs config | sed "/Cluster Properties:/,/^$/p" -n
Cluster Properties:
 cluster-infrastructure: corosync
 cluster-name: HACluster
 dc-version: 2.1.6-1.el8-6fdc9deea29
 have-watchdog: false

Comment 10 Michal Pospisil 2023-06-20 09:19:33 UTC
DevTestResults:

[root@r08-09-b ~]# rpm -q pcs
pcs-0.10.17-1.el8.x86_64

[root@r08-09-b ~]# pcs property config --output-format=cmd
pcs property set --force -- \
 maintenance-mode=false \
 placement-strategy=minimal

[root@r08-09-b ~]# pcs property config
Cluster Properties:
cluster-infrastructure: corosync
cluster-name: pre1
dc-version: 2.1.6-1.el8-6fdc9deea29
have-watchdog: false
maintenance-mode: false
placement-strategy: minimal

Comment 17 errata-xmlrpc 2023-11-14 15:22:35 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 (pcs bug fix and enhancement update), 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-2023:6903


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