Cluster 26. Renaming pcs resource.
Below procedure found in:
https://bugzilla.redhat.com/show_bug.cgi?id=1126835 and tested by changing of the name of the resource type "ocf:heartbeat:VirtualDomain":
First:
https://bugzilla.redhat.com/show_bug.cgi?id=1126835 and tested by changing of the name of the resource type "ocf:heartbeat:VirtualDomain":
First:
- make resource unmanaged: pcs resource unmanage resource-old-name
- If this is VirtualDomain resource:
- change old-name to the new-name in XML definition files of your VM.
Backup existing config:
pcs cluster cib /tmp/cib.xml
Globally (not only first occurrence) change old-name to the new-name:
sed 's/resource-old-name/resource-new-name/g' -i /tmp/cib.xml
Verify changes:
vi /tmp/cib.xml
Push changed config to the cluster:
pcs cluster cib-push /tmp/cib.xml
Verify name change:
pcs status
Verify name change in the config dump:
pcs config | grep resource-new-name
Make resource managed again:
pcs resource manage resource-new-name
Make resource managed again:
pcs resource manage resource-new-name
No comments:
Post a Comment