[Pacemaker] combining connectivity and stickiness: howto?

Thomas ThomasCaspari at t-online.de
Fri May 13 19:09:06 UTC 2011


So, I have tried to help with that topic in the near past, but I must admit, I
havent't understood it myself. Yet.

My objective: 
- IP and dependent resources should stick to clusternode1 as it has the most
powerful hardware (new server)
- IP should react to ping or pingd scores and move to a reachable node. If none
can be reached, it's okay that the IP dies until connectivity returns. Each node
has a static IP
- when clusternode1 has connectivity, IP mandatory shall run on that node!
Otherwise fail over to secondary.

I can achieve stickiness or connectivity, but currently I fail to combine both.
What have I misunderstood/overseen? 192.168.56.1/24 is the default gateway in
this scenario:

My config (only relevant parts):
---
primitive resIP ocf:heartbeat:IPaddr2 \
        params ip="192.168.56.20" nic="eth0" cidr_netmask="24" \
        op start timeout="20" op stop timeout="20" \
        op monitor interval="10" timeout="20"
primitive resPINGD ocf:pacemaker:pingd \
        params host_list="192.168.56.1" dampen="3s" multiplier="100" \
        op monitor interval="10s" timeout="20s" start-delay="30s" \
        op start timeout="90s" op stop timeout="100s"
location locIP resIP \
        rule $id="locIP-pingd" pingd: defined pingd \
        rule $id="locIP-nopingd" -inf: not_defined pingd \
        rule $id="locIP-stickiness-node1" 25: #uname eq clusternode1 \
        rule $id="locIP-stickiness-node2" -25: #uname eq clusternode2
---

This is the version which reacts correctly to connectivity, but ignores
stickiness. What have I misconfigured here?

thanx in advance for helping

Thomas





More information about the Pacemaker mailing list