No subject
Thu Sep 30 11:38:38 UTC 2010
6.2.2. Asymmetrical "Opt-In" Clusters
To create an opt-in cluster, start by preventing resources from
running anywhere by default
crm_attribute --attr-name symmetric-cluster --attr-value false
Then start enabling nodes. The following fragment says that the web
server prefers sles-1, the database prefers sles-2 and both can
failover to sles-3 if their most preferred node fails.
<constraints>
<rsc_location id="loc-1" rsc="Webserver" node="sles-1" score="200"/>
<rsc_location id="loc-2" rsc="Webserver" node="sles-3" score="0"/>
<rsc_location id="loc-3" rsc="Database" node="sles-2" score="200"/>
<rsc_location id="loc-4" rsc="Database" node="sles-3" score="0"/>
</constraints>
Example 6.1. Example set of opt-in location constraints
At the moment you have symmetric-cluster=false, you need to add
location constraints in order to get your resources running.
Below is my conf and it works as expected, pbx_service_01 starts on
node-01 and never fails back, in case failed over to node-03 and
node-01 is back on line, due to resource-stickiness="1000", but take a
look at the score in location constraint, very low scores compared to
1000 - I could have also set it to inf
location PrimaryNode-drbd_01 ms-drbd_01 100: node-01
location PrimaryNode-drbd_02 ms-drbd_02 100: node-02
location PrimaryNode-pbx_service_01 pbx_service_01 200: node-01
location PrimaryNode-pbx_service_02 pbx_service_02 200: node-02
location SecondaryNode-drbd_01 ms-drbd_01 0: node-03
location SecondaryNode-drbd_02 ms-drbd_02 0: node-03
location SecondaryNode-pbx_service_01 pbx_service_01 10: node-03
location SecondaryNode-pbx_service_02 pbx_service_02 10: node-03
location fencing-on-node-01 pdu 1: node-01
location fencing-on-node-02 pdu 1: node-02
location fencing-on-node-03 pdu 1: node-03
rsc_defaults $id="rsc-options" resource-stickiness="1000"
[1]http://www.clusterlabs.org/doc/en-US/Pacemaker/1.0/html/Pacemaker_Explained/ch06s02s02.html
More information about the Pacemaker
mailing list