[Pacemaker] Help on defining resource-stickness

Paul Sun paul.sun at syniverse.com
Mon Mar 11 06:01:30 UTC 2013


Hi

I am currently learning how to use pacemaker. I have created a three nodes configuration, and two IP resources. My target to setup the IP to follow only two nodes, and this is able to achieve by using the score in location command. My next target is to disable the failover back when node is resumed. But I am confused how I can define the resource-stickness accordingly to different resources.

Below is my configuration.

crm(live)configure# show
node HA_NODE1
node HA_NODE2
node HA_NODE3
primitive ClusterIP ocf:heartbeat:IPaddr2 \
      params ip="192.168.206.161" cidr_netmask="32" \
      op monitor interval="30s"
primitive PDNS_IP ocf:heartbeat:IPaddr2 \
      params ip="192.168.206.160" cidr_netmask="32" nic="eth2"
location ClusterIP-prefer1 ClusterIP 500: HA_NODE1
location ClusterIP-prefer2 ClusterIP 300: HA_NODE2
location ClusterIP-prefer3 ClusterIP -inf: HA_NODE3
location PDNS_IP-prefer1 PDNS_IP -inf: HA_NODE1
location PDNS_IP-prefer2 PDNS_IP 500: HA_NODE2
location PDNS_IP-prefer3 PDNS_IP 300: HA_NODE3
property $id="cib-bootstrap-options" \
      dc-version="1.1.7-6.el6-148fccfd5985c5590cc601123c6c16e966b85d14" \
      cluster-infrastructure="openais" \
      expected-quorum-votes="3" \
      stonith-enabled="false" \
      no-quorum-policy="ignore" \
      last-lrm-refresh="1362737116"
rsc_defaults $id="rsc-options" \
      resource-stickiness="150"

Target is to

1.       ClusterIP will flow between HA_NODE1 and HA_NODE2 only.

2.       PDNS_IP will flow between HA_NODE2 and HA_NODE3 only.

Question:
How I can setup the resources "CLUSTERIP" not failover back to HA_NODE1 when it is resumed, and resources "PDNS_IP" failover back to HA_NODE2 when it is resumed?


RBK


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clusterlabs.org/pipermail/pacemaker/attachments/20130311/aa4458ac/attachment-0003.html>


More information about the Pacemaker mailing list