[ClusterLabs] Make sure either 0 or all resources in a group are running

Ken Gaillot kgaillot at redhat.com
Mon Mar 28 20:31:24 UTC 2016


On 03/28/2016 02:19 PM, Sam Gardner wrote:
> Is there any way to modify the behavior of a resource group N of A, B, and C so that either A, B, and C are running on the same node, or none of them are?
> 
> With Pacemaker 1.1.12 and Corosync 1.4.8, if a group N is defined via:
> pcs resource group N A B C
> 
> if resource C cannot run, A and B still do.
> 
> --
> Sam Gardner
> Trustwave | SMART SECURITY ON DEMAND

The problem with that model is that none of the resources can be placed
or started, because each depends on the others being placed and started
already.

I can think of two similar alternatives, though they would only work for
failures, not for any other reasons C might be stopped:

* Use on-fail=standby, so that if any resource fails, all resources are
forced off that node. The node must be manually taken out of standby to
be used again.

* Use rules to say that A cannot run on any node where fail-count-B gt 0
or fail-count-C gt 0, and B cannot run on any node where fail-count C gt
0. (The group should handle the rest of the dependencies.)





More information about the Users mailing list