summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2011-02-22 22:24:50 +0100
committerMichael Adam <obnox@samba.org>2011-02-24 10:35:24 +0100
commit0c93a2932c0641b6ba22977483f464e21fe915df (patch)
tree2f340601b402bb67aa484bd575eb943c48dfd974
parentc9df23ae1d210eda9245c185c0f3e324157b5025 (diff)
downloadsamba-0c93a2932c0641b6ba22977483f464e21fe915df.tar.gz
samba-0c93a2932c0641b6ba22977483f464e21fe915df.tar.xz
samba-0c93a2932c0641b6ba22977483f464e21fe915df.zip
persistent_store_timout: do not really time out the trans3_commit control in recovery
If a recovery was started, then all further processing of the update_record controls sent by the trans3_commit control and timing them out is disabled. The recovery should trigger sending the reply for the update record control when finished. (This used to be ctdb commit 983c1ca2e18ecd60fca69bfe9e116125cc695857)
-rw-r--r--ctdb/server/ctdb_persistent.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/ctdb/server/ctdb_persistent.c b/ctdb/server/ctdb_persistent.c
index 3f297fa22f..cde3365053 100644
--- a/ctdb/server/ctdb_persistent.c
+++ b/ctdb/server/ctdb_persistent.c
@@ -88,7 +88,13 @@ static void ctdb_persistent_store_timeout(struct event_context *ev, struct timed
struct timeval t, void *private_data)
{
struct ctdb_persistent_state *state = talloc_get_type(private_data, struct ctdb_persistent_state);
-
+
+ if (state->ctdb->recovery_mode != CTDB_RECOVERY_NORMAL) {
+ DEBUG(DEBUG_INFO, ("ctdb_persistent_store_timeout: ignoring "
+ "timeout during recovery\n"));
+ return;
+ }
+
ctdb_request_control_reply(state->ctdb, state->c, NULL, CTDB_TRANS2_COMMIT_TIMEOUT,
"timeout in ctdb_persistent_state");