[ClusterLabs] ClusterIP won't return to recovered node

Jan Pokorný jpokorny at redhat.com
Wed Jun 28 14:22:35 UTC 2017


On 27/06/17 15:15 -0400, Dan Ragle wrote:
> All that said, and for anyone interested, here's the recipe I tried that
> appears to work well. After setting it up this way, I was able to
> standby/unstandby each of the nodes in turn with the clones consistently
> re-splitting after each unstandby (and the RealN resources all remaining on
> node1 if it was available and node otherwise):
> 
> # pcs property set placement-strategy=balanced
> 
> # pcs node utilization node1-pcs weight=250
> # pcs node utilization node2-pcs weight=250
> 
> # pcs resource create Real1 ocf:pacemaker:Dummy
> # pcs resource create Real2 ocf:pacemaker:Dummy
> # pcs resource create Real3 ocf:pacemaker:Dummy
> # pcs resource create Real4 ocf:pacemaker:Dummy
> # pcs resource utilization Real1 weight=1
> # pcs resource utilization Real2 weight=1
> # pcs resource utilization Real3 weight=1
> # pcs resource utilization Real4 weight=1
> # pcs constraint location Real1 prefers node1-pcs=INFINITY
> # pcs constraint location Real2 prefers node1-pcs=INFINITY
> # pcs constraint location Real3 prefers node1-pcs=INFINITY
> # pcs constraint location Real4 prefers node1-pcs=INFINITY
> 
> # pcs resource create Dummy1 ocf:pacemaker:Dummy meta priority=-1
> # pcs resource create Dummy2 ocf:pacemaker:Dummy meta priority=-1
> # pcs constraint location Dummy1 prefers node2-pcs=-INFINITY
> # pcs constraint location Dummy2 prefers node1-pcs=-INFINITY
> # pcs resource utilization Dummy1 weight=100
> # pcs resource utilization Dummy2 weight=100
> 
> # pcs resource create ClusterIP ocf:heartbeat:IPaddr2 ip=1.2.3.4 nic=bond0
> cidr_netmask=24 meta resource-stickiness=0
> # pcs resource utilization ClusterIP weight=100
> # pcs resource clone ClusterIP clone-max=2 clone-node-max=2
> globally-unique=true

You may find "pcs config export pcs-commands" helpful -- it will
expose the existing cluster configuration as a set of commands
to reinstate it (hopefully).  Actually, if you want just the CIB
subset (like above), it is currently not exposed through pcs,
you'd use "clufter cib2pcscmd -s".

Of course, it would not express the conceptual boundaries as in the
human-crafted case.  It would follow the preferred accumulate-and-push
approach though, which is not prone to keeping cluster in the needless
reevaluations of what should run where (amongst others), unlike the
stream of one-off changes to the course of cluster's run.

-- 
Jan (Poki)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.clusterlabs.org/pipermail/users/attachments/20170628/c2510eef/attachment-0002.sig>


More information about the Users mailing list