Gitweb:
http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=...
Commit: f504ce0183dba5ab86ac70b56ca39399f87eb347
Parent: 52d28f1887ddb642b316251e22f4359c7ab79302
Author: Lon Hohberger <lhh(a)redhat.com>
AuthorDate: Fri Feb 19 10:13:54 2010 -0500
Committer: Lon Hohberger <lhh(a)redhat.com>
CommitterDate: Fri Feb 19 10:13:54 2010 -0500
Revert "qdisk: Autoconfigure default timings"
This reverts commit 52d28f1887ddb642b316251e22f4359c7ab79302.
---
cman/man/qdisk.5 | 1 -
cman/qdisk/disk.h | 2 +-
cman/qdisk/main.c | 35 ++---------------------------------
3 files changed, 3 insertions(+), 35 deletions(-)
diff --git a/cman/man/qdisk.5 b/cman/man/qdisk.5
index 4d7e8e8..f578e92 100644
--- a/cman/man/qdisk.5
+++ b/cman/man/qdisk.5
@@ -211,7 +211,6 @@ This is the frequency of read/write cycles, in seconds.
\fItko\fP\fB="\fP10\fB"\fP
.in 12
This is the number of cycles a node must miss in order to be declared dead.
-The default for this number is dependent on the configured token timeout.
.in 9
\fItko_up\fP\fB="\fPX\fB"\fP
diff --git a/cman/qdisk/disk.h b/cman/qdisk/disk.h
index 8678ca7..c5b3d18 100644
--- a/cman/qdisk/disk.h
+++ b/cman/qdisk/disk.h
@@ -246,7 +246,7 @@ typedef struct {
int qc_max_error_cycles;
int qc_master; /* Master?! */
int qc_config;
- int qc_token_timeout;
+ int qc_pad;
disk_node_state_t qc_disk_status;
disk_node_state_t qc_status;
run_flag_t qc_flags;
diff --git a/cman/qdisk/main.c b/cman/qdisk/main.c
index b0fa501..eb3ab3c 100644
--- a/cman/qdisk/main.c
+++ b/cman/qdisk/main.c
@@ -24,7 +24,6 @@
#include <ccs.h>
#include <liblogthread.h>
#include "score.h"
-#include "../daemon/cman.h"
#include <sys/syslog.h>
#define LOG_DAEMON_NAME "qdiskd"
@@ -1487,36 +1486,14 @@ get_static_config_data(qd_ctx *ctx, int ccsfd)
if (ctx->qc_interval < 1)
ctx->qc_interval = 1;
}
-
- snprintf(query, sizeof(query), "/cluster/totem/@token");
- if (ccs_get(ccsfd, query, &val) == 0) {
- ctx->qc_token_timeout = atoi(val);
- free(val);
- if (ctx->qc_token_timeout < 10000) {
- logt_print(LOG_DEBUG, "Token timeout %d is too fast "
- "to use with qdiskd!\n",
- ctx->qc_token_timeout);
- }
- } else {
- ctx->qc_token_timeout = DEFAULT_TOKEN_TIMEOUT;
- }
/* Get tko */
snprintf(query, sizeof(query), "/cluster/quorumd/@tko");
if (ccs_get(ccsfd, query, &val) == 0) {
ctx->qc_tko = atoi(val);
free(val);
- } else {
- ctx->qc_tko = ((ctx->qc_token_timeout / 1000) -
- ctx->qc_interval) / 2;
- logt_print(LOG_DEBUG, "Auto-configured TKO as %d based on "
- "token=%d interval=%d\n", ctx->qc_tko,
- ctx->qc_token_timeout, ctx->qc_interval);
- }
-
- if (ctx->qc_tko < 4) {
- logt_print(LOG_ERR, "Quorum disk TKO (%d) is too low!\n",
- ctx->qc_tko);
+ if (ctx->qc_tko < 3)
+ ctx->qc_tko = 3;
}
/* Get up-tko (transition off->online) */
@@ -1550,14 +1527,6 @@ get_static_config_data(qd_ctx *ctx, int ccsfd)
}
if (ctx->qc_master_wait <= ctx->qc_tko_up)
ctx->qc_master_wait = ctx->qc_tko_up + 1;
-
- if ((ctx->qc_interval * (ctx->qc_master_wait +
- ctx->qc_upgrade_wait +
- ctx->qc_tko) * 1000) >=
- ctx->qc_token_timeout) {
- logt_print(LOG_WARNING, "Master failover too slow for "
- "configured token timeout!\n");
- }
/* Get votes */
snprintf(query, sizeof(query), "/cluster/quorumd/@votes");