*/
#include "includes.h"
-#include "lib/events/events.h"
+#include "lib/tevent/tevent.h"
#include "system/filesys.h"
#include "system/wait.h"
#include "../include/ctdb_private.h"
/* send a keepalive to all other nodes, unless */
for (i=0;i<ctdb->num_nodes;i++) {
struct ctdb_node *node = ctdb->nodes[i];
+
+ if (node->flags & NODE_FLAGS_DELETED) {
+ continue;
+ }
+
if (node->pnn == ctdb->pnn) {
continue;
}
node->rx_cnt = 0;
if (node->dead_count >= ctdb->tunable.keepalive_limit) {
- DEBUG(0,("dead count reached for node %u\n", node->pnn));
+ DEBUG(DEBUG_NOTICE,("dead count reached for node %u\n", node->pnn));
ctdb_node_dead(node);
ctdb_send_keepalive(ctdb, node->pnn);
/* maybe tell the transport layer to kill the
continue;
}
- if (node->tx_cnt == 0) {
- DEBUG(DEBUG_DEBUG,("sending keepalive to %u\n", node->pnn));
- ctdb_send_keepalive(ctdb, node->pnn);
- }
+ DEBUG(DEBUG_DEBUG,("sending keepalive to %u\n", node->pnn));
+ ctdb_send_keepalive(ctdb, node->pnn);
node->tx_cnt = 0;
}
ctdb_check_for_dead_nodes, ctdb);
CTDB_NO_MEMORY_FATAL(ctdb, te);
- DEBUG(0,("Keepalive monitoring has been started\n"));
+ DEBUG(DEBUG_NOTICE,("Keepalive monitoring has been started\n"));
}
void ctdb_stop_keepalive(struct ctdb_context *ctdb)