Rev 355: tweak timeouts in http://samba.org/~tridge/ctdb

tridge at samba.org tridge at samba.org
Sat May 26 23:43:27 GMT 2007


------------------------------------------------------------
revno: 355
revision-id: tridge at samba.org-20070526234325-u41a50wc6bnwahl1
parent: tridge at samba.org-20070526081319-5d45ahkx4n0tgd6d
committer: Andrew Tridgell <tridge at samba.org>
branch nick: tridge
timestamp: Sun 2007-05-27 09:43:25 +1000
message:
  tweak timeouts
modified:
  common/ctdb_recoverd.c         recoverd.c-20070503213540-bvxuyd9jm1f7ig90-1
  include/ctdb_private.h         ctdb_private.h-20061117234101-o3qt14umlg9en8z0-13
=== modified file 'common/ctdb_recoverd.c'
--- a/common/ctdb_recoverd.c	2007-05-26 04:01:08 +0000
+++ b/common/ctdb_recoverd.c	2007-05-26 23:43:25 +0000
@@ -36,6 +36,7 @@
 }
 
 #define CONTROL_TIMEOUT() timeval_current_ofs(5, 0)
+#define MONITOR_TIMEOUT() timeval_current_ofs(1, 0)
 
 static int set_recovery_mode(struct ctdb_context *ctdb, struct ctdb_node_map *nodemap, uint32_t rec_mode)
 {
@@ -699,7 +700,7 @@
 
 	/* we only check for recovery once every second */
 	timed_out = 0;
-	event_add_timed(ctdb->ev, mem_ctx, CONTROL_TIMEOUT(), timeout_func, ctdb);
+	event_add_timed(ctdb->ev, mem_ctx, MONITOR_TIMEOUT(), timeout_func, ctdb);
 	while (!timed_out) {
 		event_loop_once(ctdb->ev);
 	}

=== modified file 'include/ctdb_private.h'
--- a/include/ctdb_private.h	2007-05-26 04:01:08 +0000
+++ b/include/ctdb_private.h	2007-05-26 23:43:25 +0000
@@ -334,7 +334,7 @@
 #define CTDB_TRAVERSE_TIMEOUT 20
 
 /* timeout between dead-node monitoring events */
-#define CTDB_MONITORING_TIMEOUT 3
+#define CTDB_MONITORING_TIMEOUT 2
 
 /* number of monitoring timeouts before a node is considered dead */
 #define CTDB_MONITORING_DEAD_COUNT 2



More information about the samba-cvs mailing list