[ClusterLabs] Offtopic - role migration

Ken Gaillot kgaillot at redhat.com
Tue Apr 18 15:09:10 EDT 2023

On Tue, 2023-04-18 at 19:50 +0200, Vladislav Bogdanov wrote:
> Btw, an interesting question. How much efforts would it take to
> support a migration of a Master role over the nodes? An use-case is
> drbd, configured for a multi-master mode internally, but with master-
> max=1 in the resource definition. Assuming that resource-agent
> supports that flow - 
> 1. Do nothing. 
> 2. Promote on a dest node. 
> 3. Demote on a source node.
> Actually just wonder, because may be it could be some-how achievable
> to migrate VM which are on top of drbd which is not a multi-master in
> pacemaker. Fully theoretical case. Didn't verify the flow in-the-
> mind.
> I believe that currently only the top-most resource is allowed to
> migrate, but may be there is some room for impovement?
> Sorry for the off-topic.
> Best
> Vlad

It would be worthwhile, but conceptually it's difficult to imagine a

If a resource must be colocated with the promoted role of another
resource, and only one instance can be promoted at a time, how would it
be possible to live-migrate? You couldn't promote the new instance
before demoting the old one, and you couldn't demote the old one
without stopping the dependent resource.

You would probably need some really complex new constraint types and/or
resource agent actions. Something like "colocate rsc1 with the promoted
role of rsc2-clone, unless it needs to migrate, in which case call this
special agent action to prepare it for running with a demoted instance,
then demote the instance, then migrate the resource, then promote the
new instance, then call this other agent action to return it to normal
Ken Gaillot <kgaillot at redhat.com>

More information about the Users mailing list