Modify resource parameters

To modify the parameters of a configured cluster resource, use the pcs resource update command.

About this task

To modify the options or parameters of a cluster resource, use the following syntax:

# pcs resource update resource_id [resource_options]
Note

When updating a resource operation with the pcs resource update command, options that are not explicitly specified reset to their default values.

The following example procedure modifies the ip parameter of the VirtualIP resource.

Procedure

  1. Display the current configuration parameters for the VirtualIP resource:
    # pcs resource config VirtualIP
     Resource: VirtualIP (type=IPaddr2 class=ocf provider=heartbeat)
      Attributes: ip=192.168.0.120 cidr_netmask=24
      Operations: monitor interval=30s
  2. Update the value of the ip parameter for the VirtualIP resource:
    # pcs resource update VirtualIP ip=192.169.0.120
  3. Verify the updated parameter values for the VirtualIP resource:
    # pcs resource config VirtualIP
     Resource: VirtualIP (type=IPaddr2 class=ocf provider=heartbeat)
      Attributes: ip=192.169.0.120 cidr_netmask=24
      Operations: monitor interval=30s