[ClusterLabs] Colocation rule with vip and ms master

Ferenc Wágner wferi at niif.hu
Tue Oct 31 02:55:09 EDT 2017


Norberto Lopes <nlopes.ml at gmail.com> writes:

> On Fri, 27 Oct 2017 at 06:41 Ferenc Wágner <wferi at niif.hu> wrote:
>
>> Norberto Lopes <nlopes.ml at gmail.com> writes:
>>
>>> colocation backup-vip-not-with-master -inf: backupVIP postgresMS:Master
>>> colocation backup-vip-not-with-master inf: backupVIP postgresMS:Slave
>>>
>>> Basically what's occurring in my cluster is that the first rule stops the
>>> Sync node from being promoted if the Master ever dies. The second doesn't
>>> but I can't quite follow why.
>>
>> Getting a score of -inf means that the resource won't run.  On the other
>> hand, (+)inf just means "strongest" preference.
>
> Apologies but I'm not following. I'm probably misunderstanding something.
>
> From what I could gather from
> https://clusterlabs.org/doc/en-US/Pacemaker/1.1/html/Pacemaker_Explained/_mandatory_placement.html
> I can't follow the subtle difference between the two on a running
> cluster. As an example: If backupVIP is already in node A and
> postgresMS:Master in node B, and postgresMS:Master dies, in my case,
> postgresMS:Master never gets promoted in node C. But from the -inf
> rule it should be able to?
>
> Any insights into this would be greatly appreciated.

You're right: what I said was based on my experience with location
constraints, and according to the linked documentation colocation
constraints behave differently.  Sorry for misleading you.  I'm leaving
this discussion to the more knowledgeable.
-- 
Regards,
Feri




More information about the Users mailing list