[ClusterLabs] set start-failure-is-fatal per resource?

Ken Gaillot kgaillot at redhat.com
Mon Oct 17 20:12:13 CEST 2016


On 10/17/2016 12:42 PM, Israel Brewster wrote:
> I have one resource agent (redis, to be exact) that sometimes apparently
> fails to start on the first attempt. In every case, simply running a
> 'pcs resource cleanup' such that pacemaker tries to start it again
> successfully starts the process. Now, obviously, the proper thing to do
> is to figure out why redis sometimes fails to start, and fix that (it
> sort of feels like there may be a race condition going on somewhere to
> me), which I fully intend to spend some time investigating. However, in
> the meantime the quick "fix" is to simply have Pacemaker try starting
> the resource again if it fails the first time. This is easily
> accomplished by setting the property start-failure-is-fatal to false,
> which works beautifully for the redis resource. However, this is a
> global setting, and for most resources it doesn't make sense - if they
> don't start on the first try, I'm probably going to need to fix
> something before they will start.
> 
> So the question is, is there a way to set the start-failure-is-fatal
> property to false only for one resource, or in some other way configure
> the resources such that the effect is the same - i.e. the one resource I
> want will retry start, but the others will give up after a single
> failure? Thanks.

Currently, start-failure-is-fatal can only be set globally. There was a
recent thread about a major overhaul of Pacemaker's failure handling
configuration that would make the equivalent functionality per-resource,
so this may change in a future version.

In the meantime, you can get the behavior you want by setting
start-failure-is-fatal=false, and setting migration-threshold=1 on the
resources you want to fail after a single failure. However, that will
also affect monitor failures (i.e. the resource will move to another
node after a single monitor failure).

> -----------------------------------------------
> Israel Brewster
> Systems Analyst II
> Ravn Alaska
> 5245 Airport Industrial Rd
> Fairbanks, AK 99709
> (907) 450-7293
> -----------------------------------------------



More information about the Users mailing list