mirror of
https://github.com/samba-team/samba.git
synced 2025-03-20 22:50:26 +03:00
we have to get a NEW generation id after completing recovery
to solve a race condition with the logic to retransmit in ctdb_call.c/ctdb_call_timeout() (This used to be ctdb commit 1044ddca9ff5c434816de35d3f659aa182704e97)
This commit is contained in:
parent
7769a2d45e
commit
0c9bb4bb44
@ -891,7 +891,7 @@ int ctdb_ctrl_setrecmode(struct ctdb_context *ctdb, struct timeval timeout, uint
|
||||
CTDB_CONTROL_SET_RECMODE, 0, data,
|
||||
ctdb, &outdata, &res, &timeout);
|
||||
if (ret != 0 || res != 0) {
|
||||
DEBUG(0,(__location__ " ctdb_control for getrecmode failed\n"));
|
||||
DEBUG(0,(__location__ " ctdb_control for setrecmode failed\n"));
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
@ -426,6 +426,7 @@ static int do_recovery(struct ctdb_context *ctdb, struct event_context *ev,
|
||||
|
||||
|
||||
/* build a new vnn map with all the currently active nodes */
|
||||
generation = random();
|
||||
vnnmap = talloc(mem_ctx, struct ctdb_vnn_map);
|
||||
CTDB_NO_MEMORY(ctdb, vnnmap);
|
||||
vnnmap->generation = generation;
|
||||
|
Loading…
x
Reference in New Issue
Block a user