[chord] Can only instantiate 3+ nodes when port is specified
Emil Sit
sit at MIT.EDU
Fri Oct 19 22:08:05 EDT 2007
On Fri, 19 October 2007 at 16:24 (-0500), Diaz, Wilfredo (Freddy) wrote:
> I've been able to instantiate multiple nodes and execute vis on them.
> However, this is only possible when I specify the port to be used by
> each non-bootstrap node with the exception of the first non-bootstrap.
Oops. Can you apply the following patch and let me know if
it fixes your problem?
diff -r 1c6dfc6f325b lsd/lsd.C
--- a/lsd/lsd.C Fri Oct 19 14:19:50 2007 -0400
+++ b/lsd/lsd.C Fri Oct 19 22:03:32 2007 -0400
@@ -755,15 +755,6 @@ main (int argc, char **argv)
assert (mode == modes[mode].m);
- // Initialize for use by LSDCTL_GETLSDPARAMETERS
- parameters.nvnodes = vnodes;
- parameters.adbdsock = dbsock;
- Configurator::only ().get_int ("dhash.efrags", parameters.efrags);
- Configurator::only ().get_int ("dhash.dfrags", parameters.dfrags);
- Configurator::only ().get_int ("dhash.replica", parameters.nreplica);
- parameters.addr.hostname = my_name;
- parameters.addr.port = myport; // chord->get_port ();
-
chordnode = New refcounted<chord> (my_name,
myport,
modes[mode].producer,
@@ -776,6 +767,15 @@ main (int argc, char **argv)
chord_trigger_t::alloc (wrap (&finish_start))));
}
+ // Initialize for use by LSDCTL_GETLSDPARAMETERS
+ parameters.nvnodes = vnodes;
+ parameters.adbdsock = dbsock;
+ Configurator::only ().get_int ("dhash.efrags", parameters.efrags);
+ Configurator::only ().get_int ("dhash.dfrags", parameters.dfrags);
+ Configurator::only ().get_int ("dhash.replica", parameters.nreplica);
+ parameters.addr.hostname = my_name;
+ parameters.addr.port = chordnode->get_port ();
+
info << "starting amain.\n";
amain ();
--
Emil Sit / MIT CSAIL PDOS / http://pdos.csail.mit.edu/chord/
More information about the chord
mailing list