if (node->dead_count >= CTDB_MONITORING_DEAD_COUNT) {
ctdb_node_dead(node);
+ ctdb_send_keepalive(ctdb, node->vnn);
/* maybe tell the transport layer to kill the
sockets as well?
*/
continue;
}
- if (node->tx_cnt == 0) {
+ if (node->tx_cnt == 0 && (node->flags & NODE_FLAGS_CONNECTED)) {
ctdb_send_keepalive(ctdb, node->vnn);
}
}
}
+ /* listen on our own address */
+ if (ctdb_ibw_listen(ctdb, 10)) /* TODO: backlog as param */
+ return -1;
+
return 0;
}
{
int i, ret;
- /* listen on our own address */
- if (ctdb_ibw_listen(ctdb, 10)) /* TODO: backlog as param */
- return -1;
-
/* everything async here */
for (i=0;i<ctdb->num_nodes;i++) {
struct ctdb_node *node = ctdb->nodes[i];
{
int i;
+ /* listen on our own address */
+ if (ctdb_tcp_listen(ctdb) != 0) return -1;
+
for (i=0; i<ctdb->num_nodes; i++) {
if (ctdb_tcp_add_node(ctdb->nodes[i]) != 0) {
DEBUG(0, ("methods->add_node failed at %d\n", i));
{
int i;
- /* listen on our own address */
- if (ctdb_tcp_listen(ctdb) != 0) return -1;
-
/* startup connections to the other servers - will happen on
next event loop */
for (i=0;i<ctdb->num_nodes;i++) {