[Pacemaker] question related to resource starting
Dominik Klein
dk at in-telegence.net
Tue Mar 24 08:18:49 UTC 2009
Glory Smith wrote:
> On Tue, Mar 24, 2009 at 12:16 PM, Dominik Klein <dk at in-telegence.net> wrote:
>
>> Glory Smith wrote:
>>> Hi All,
>>> when we create a resource , how pacemaker choose a node to start
>> resource
>>> on it.
>>>
>>> To be more clear , suppose we have four node cluster , we configure any
>>> resource xx and we see that it is started on say , node C . so my
>>> question is why node C is choosen to run the resource xx. is this
>> behavior
>>> is random or some logic is behind this.
>>>
>>> Thanks for your enlightening answers.
>> If you don't tell the cluster where to start the resource (through
>> constraints), it will try to balance resources throughout the nodes. It
>> does however _not_ (yet) take node hardware or load into account.
>>
>
> suppose there is no resource running anywhere on cluster . if anyone
> configure a resource (it will be first resource) then on which node it will
> be placed.?
That is supposed to be random, but in my experience it is always the
same node. I don't know anything about the actual algorithm though.
> does during failover also cluster try to balance resources??
Yes. If you don't have any preferences configured, it may happen that if
one resource needs to be failed over to a certain node, that other
resources that are currently running there are migrated to another node
to balance resources across nodes.
You can use the resource-stickiness meta attribute to avoid that.
Regards
Dominik
More information about the Pacemaker
mailing list