diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2010-02-12 09:23:10 +0000 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2010-02-12 09:23:10 +0000 |
commit | 70d0560287642c0323f3566d8c998d907c52d7d7 (patch) | |
tree | 91aaabf79341949aceb7688a928102c25167ac35 /tools/libxc/xc_domain_restore.c | |
parent | d652a9595460cfc81afeb66c17aef7adedfb9175 (diff) | |
download | xen-70d0560287642c0323f3566d8c998d907c52d7d7.tar.gz xen-70d0560287642c0323f3566d8c998d907c52d7d7.tar.bz2 xen-70d0560287642c0323f3566d8c998d907c52d7d7.zip |
Remus: increase failover timeout from 500ms to 1s
500ms is aggressive enough to trigger split-brain under fairly
ordinary workloads, particularly for HVM. The long-term fix is to
integrate with a real HA monitor like linux HA.
Signed-off-by: Brendan Cully <brendan@cs.ubc.ca>
Diffstat (limited to 'tools/libxc/xc_domain_restore.c')
-rw-r--r-- | tools/libxc/xc_domain_restore.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/libxc/xc_domain_restore.c b/tools/libxc/xc_domain_restore.c index 4c04bf8a53..8aa58a1db9 100644 --- a/tools/libxc/xc_domain_restore.c +++ b/tools/libxc/xc_domain_restore.c @@ -444,7 +444,7 @@ alloc_page: /* set when a consistent image is available */ static int completed = 0; -#define HEARTBEAT_MS 500 +#define HEARTBEAT_MS 1000 #ifndef __MINIOS__ static ssize_t read_exact_timed(int fd, void* buf, size_t size) @@ -458,8 +458,8 @@ static ssize_t read_exact_timed(int fd, void* buf, size_t size) { if ( completed ) { /* expect a heartbeat every HEARBEAT_MS ms maximum */ - tv.tv_sec = 0; - tv.tv_usec = HEARTBEAT_MS * 1000; + tv.tv_sec = HEARTBEAT_MS / 1000; + tv.tv_usec = (HEARTBEAT_MS % 1000) * 1000; FD_ZERO(&rfds); FD_SET(fd, &rfds); |