Hi Chrissie,
This (I think) should fix the qdiskd registration issue.
-- Lon
diff --git a/cman/qdisk/main.c b/cman/qdisk/main.c
index a6be5a8..83892a3 100644
--- a/cman/qdisk/main.c
+++ b/cman/qdisk/main.c
@@ -1777,29 +1777,32 @@ main(int argc, char **argv)
if (!_running)
goto out;
-
- cman_register_quorum_device(ctx.qc_cman_admin,
- (ctx.qc_flags&RF_CMAN_LABEL)?
- ctx.qc_cman_label:
- ctx.qc_device,
- ctx.qc_votes);
- /*
- XXX this always returns -1 / EBUSY even when it works?!!!
-
- if ((rv = cman_register_quorum_device(ctx.qc_cman_admin, ctx.qc_device,
- ctx.qc_votes)) < 0) {
+
+ while ((rv = cman_register_quorum_device(ctx.qc_cman_admin,
+ (ctx.qc_flags&RF_CMAN_LABEL)?
+ ctx.qc_cman_label:
+ ctx.qc_device,
+ ctx.qc_votes)) < 0) {
+
+ if (errno == EBUSY) {
+ cman_poll_quorum_device(ctx.qc_cman_admin, 0);
+ cman_unregister_quorum_device(ctx.qc_cman_admin);
+ continue;
+ }
+
logt_print(LOG_CRIT,
"Could not register %s with CMAN; "
"return = %d; error = %s\n",
ctx.qc_device, rv, strerror(errno));
goto out;
}
- */
io_nanny_start(ctx.qc_tko * ctx.qc_interval);
- if (quorum_loop(&ctx, ni, MAX_NODES_DISK) == 0)
+ if (quorum_loop(&ctx, ni, MAX_NODES_DISK) == 0) {
+ cman_poll_quorum_device(ctx.qc_cman_admin, 0);
cman_unregister_quorum_device(ctx.qc_cman_admin);
+ }
io_nanny_stop();