[ClusterLabs] trigger something at ?

Klaus Wenninger kwenning at redhat.com
Mon Jan 29 11:59:54 EST 2024


On Mon, Jan 29, 2024 at 5:22 PM Ken Gaillot <kgaillot at redhat.com> wrote:

> On Fri, 2024-01-26 at 13:55 +0100, lejeczek via Users wrote:
> > Hi guys.
> >
> > Is it possible to trigger some... action - I'm thinking specifically
> > at shutdown/start.
> > If not within the cluster then - if you do that - perhaps outside.
> > I would like to create/remove constraints, when cluster starts &
> > stops, respectively.
> >
> > many thanks, L.
> >
>
> You could use node status alerts for that, but it's risky for alert
> agents to change the configuration (since that may result in more
> alerts and potentially some sort of infinite loop).
>
> Pacemaker has no concept of a full cluster start/stop, only node
> start/stop. You could approximate that by checking whether the node
> receiving the alert is the only active node.
>
> Another possibility would be to write a resource agent that does what
> you want and order everything else after it. However it's even more
> risky for a resource agent to modify the configuration.
>
> Finally you could write a systemd unit to do what you want and order it
> after pacemaker.
>
> What's wrong with leaving the constraints permanently configured?
>

My guts feeling tells me there is something wrong with the constraints
that probably will hit you as well when recovering from a problem.
But maybe it would be easier with some kind of example.

Klaus

> --
> Ken Gaillot <kgaillot at redhat.com>
>
> _______________________________________________
> Manage your subscription:
> https://lists.clusterlabs.org/mailman/listinfo/users
>
> ClusterLabs home: https://www.clusterlabs.org/
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clusterlabs.org/pipermail/users/attachments/20240129/4772259b/attachment.htm>


More information about the Users mailing list