>>> Papastavros Vaggelis <[email protected]> schrieb am 05.09.2017 um 14:43 >>> in Nachricht <CAO64vZkt2Jyodwz6LsNH7zS_u=sCW-46D=jowwfwzwmr_ep...@mail.gmail.com>: > Dear friends , > > I have two_nodes (sgw-01 and sgw-02) HA cluster integrated with two APC > PDUs as fence devices > > 1) pcs stonith create node2-psu fence_apc ipaddr="10.158.0.162" login="apc" > passwd="apc" port="1" pcmk_host_list="sgw-02" pcmk_host_check="static-list" > action="reboot" power_wait="5" op monitor interval="60s" > pcs constraint location node2-psu prefers sgw-01=INFINITY > > > 2)pcs stonith create node1-psu fence_apc ipaddr="10.158.0.161" login="apc" > passwd="apc" port="1" pcmk_host_list="sgw-01" pcmk_host_check="static-list" > action="reboot" power_wait="5" op monitor interval="60s" > pcs constraint location node1-psu prefers sgw-02=INFINITY > > > Fencing is working fine but i want to deploy the following scenario : > > If one node fenced more than x times during a specified time period then > change the fence action from reboot to stop.
What about this sketch: On every boot: "date >>some_file" If some_file is older than some time (e.g. 1 hour), delete it (or remove the oldest/first line). Also during boot: If file has more than n lines, reconfigure local stonith action to off. Obviously the mechnism can't recover locally from being off after s spacific time... ;-) Regards, Ulrich > > For example if the node rebooted more than 3 times during one hour then at > the next crash change the fence action from reboot to off. > > Is there a proper way to implement the above scenario ? > > is it mandatory to use two level fencing for the above case ? > > > > Sincerely > > Vaggelis Papastavros _______________________________________________ Users mailing list: [email protected] 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
