Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-15-SP1:Update
pacemaker.29834
bsc#1210074-0007-Fix-controller-initial-timeout...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File bsc#1210074-0007-Fix-controller-initial-timeout-for-fencing-callback-.patch of Package pacemaker.29834
From db32a9c43462c36dfe07eb4c3393aa2e9d711dad Mon Sep 17 00:00:00 2001 From: "Gao,Yan" <ygao@suse.com> Date: Mon, 17 Apr 2023 11:36:32 +0200 Subject: [PATCH 07/11] Fix: controller: initial timeout for fencing callback takes any priority fencing delay into account It's usually not necessary under normal circumstances since the timeout for the async callback gets updated very soon with st_client.c:update_callback_timeout() once fencer has decided the total fencing timeout and reported it back to controller with fenced_remote.c:report_timeout_period(). But anyway it makes sense to be added for the initial. --- daemons/controld/controld_te_actions.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) Index: pacemaker-2.0.1+20190417.13d370ca9/daemons/controld/controld_te_actions.c =================================================================== --- pacemaker-2.0.1+20190417.13d370ca9.orig/daemons/controld/controld_te_actions.c +++ pacemaker-2.0.1+20190417.13d370ca9/daemons/controld/controld_te_actions.c @@ -154,7 +154,9 @@ te_fence_node(crm_graph_t * graph, crm_a const char *target = NULL; const char *type = NULL; const char *priority_delay = NULL; + int delay_i = 0; gboolean invalid_action = FALSE; + guint stonith_timeout = transition_graph->stonith_timeout; enum stonith_call_options options = st_opt_none; id = ID(action->xml); @@ -176,7 +178,7 @@ te_fence_node(crm_graph_t * graph, crm_a crm_notice("Requesting fencing (%s) of node %s " CRM_XS " action=%s timeout=%u%s%s", - type, target, id, transition_graph->stonith_timeout, + type, target, id, stonith_timeout, priority_delay ? " priority_delay=" : "", priority_delay ? priority_delay : ""); @@ -187,15 +189,19 @@ te_fence_node(crm_graph_t * graph, crm_a options |= st_opt_allow_suicide; } + delay_i = crm_atoi(priority_delay, "0"); rc = stonith_api->cmds->fence_with_delay(stonith_api, options, target, type, - (int) (transition_graph->stonith_timeout / 1000), - 0, crm_atoi(priority_delay, "0")); + (int) (stonith_timeout / 1000), + 0, delay_i); - stonith_api->cmds->register_callback(stonith_api, rc, transition_graph->stonith_timeout / 1000, + stonith_api->cmds->register_callback(stonith_api, rc, + ((int) (stonith_timeout / 1000) + + (delay_i > 0 ? delay_i : 0)), st_opt_timeout_updates, generate_transition_key(transition_graph->id, action->id, 0, te_uuid), - "tengine_stonith_callback", tengine_stonith_callback); + "tengine_stonith_callback", + tengine_stonith_callback); return TRUE; }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor