mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
ctdb-recoverd: Only check for LMASTER nodes in the VNN map
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14085 Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
This commit is contained in:
parent
53daeb2f87
commit
5d655ac6f2
@ -2989,13 +2989,19 @@ static void main_loop(struct ctdb_context *ctdb, struct ctdb_recoverd *rec,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* verify that all active nodes in the nodemap also exist in
|
/*
|
||||||
the vnnmap.
|
* Verify that all active lmaster nodes in the nodemap also
|
||||||
|
* exist in the vnnmap
|
||||||
*/
|
*/
|
||||||
for (j=0; j<nodemap->num; j++) {
|
for (j=0; j<nodemap->num; j++) {
|
||||||
if (nodemap->nodes[j].flags & NODE_FLAGS_INACTIVE) {
|
if (nodemap->nodes[j].flags & NODE_FLAGS_INACTIVE) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
if (! ctdb_node_has_capabilities(rec->caps,
|
||||||
|
ctdb->nodes[j]->pnn,
|
||||||
|
CTDB_CAP_LMASTER)) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
if (nodemap->nodes[j].pnn == pnn) {
|
if (nodemap->nodes[j].pnn == pnn) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
@ -3006,8 +3012,8 @@ static void main_loop(struct ctdb_context *ctdb, struct ctdb_recoverd *rec,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (i == vnnmap->size) {
|
if (i == vnnmap->size) {
|
||||||
DEBUG(DEBUG_ERR, (__location__ " Node %u is active in the nodemap but did not exist in the vnnmap\n",
|
D_ERR("Active LMASTER node %u is not in the vnnmap\n",
|
||||||
nodemap->nodes[j].pnn));
|
nodemap->nodes[j].pnn);
|
||||||
ctdb_set_culprit(rec, nodemap->nodes[j].pnn);
|
ctdb_set_culprit(rec, nodemap->nodes[j].pnn);
|
||||||
do_recovery(rec, mem_ctx, pnn, nodemap, vnnmap);
|
do_recovery(rec, mem_ctx, pnn, nodemap, vnnmap);
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user