[ClusterLabs] Antw: SBD stonith in 2 node cluster - how to make it prefer one side of cluster?
Ulrich Windl
Ulrich.Windl at rz.uni-regensburg.de
Mon Nov 27 09:03:18 CET 2017
Hi!
With an sbd running on each node, I think it doesn't make a big differentce wich one was started first in cas eof a split brain: There is a chance that both nodes will kill each other.
I'd put my efforts into redundant reliable networking instead (MHO)...
Regards,
Ulrich
> Wrapping my head around how pcmk_delay_max works, my understanding is
>
> - on startup pacemaker always starts one instance of stonith/sbd; it
> probably randomly selects node for it. I suppose this initial start is
> delayed by random number within pcmk_delay_max.
>
> - when cluster is partitioned, pacemaker *also* starts one instance of
> stonith/sbd in each partition where it is not yet running. This startup
> is also delayed by random number within pcmk_delay_max.
>
> - this makes partition that already has stonith/sbd running win race for
> kill request
>
> Is my understanding correct?
>
> If yes, consider two node cluster where one application is more
> important than the other. The obvious example is replicated database -
> in case of split brain we want to preserve node with primary as it
> likely has active connections.
>
> Would using advisory colocation constraint between application and
> stonith/sbd work? Let's consider (using crmsh notation)
>
> primitive my_database
> ms my_replicated_database my_database
> primitive fencing_sbd stonith:external/sbd params pcmk_delay_max=15
> colocation prefer_primary 10: fencing_sbd my_replicated_database:Master
>
> It is going to work?
>
> It should work on startup, as it simply affects where sbd resource is
> placed initially and pacemaker need to make this decision anyway.
>
> I expect it to work if my_primary_database master moves to another node
> - pacemaker should move sbd resource too, right? It does add small
> window where no stonith agent is running, but as I understand pacemaker
> is going to start it anyway in case of split brain, so in the worst case
> non-preferred node will be fenced, which is not worse than what we have
> already.
>
> What I am not sure is what happens during split brain. Will colocation
> affect pacemaker decision to start another copy of sbd resource on
> another partitioned node? I hope not, as it is advisory so it should
> still use the only available node left in this case?
>
> Does it all make sense? Anyone has used it in real life?
>
>
> _______________________________________________
> Users mailing list: Users at clusterlabs.org
> http://lists.clusterlabs.org/mailman/listinfo/users
>
> Project Home: http://www.clusterlabs.org
> Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> Bugs: http://bugs.clusterlabs.org
More information about the Users
mailing list