[erlang-questions] Boostrapping a clique of replicating mnesia nodes

Wojciech Knapik wmknapik@REDACTED
Thu Mar 15 15:48:36 CET 2012

Hello everyone

I have a set of nodes (discovered via net_adm:world(), but others will
likely join in later) where I want to keep a fully replicated mnesia

All the nodes are identical in terms of code and all of them start at
roughly the same time on different machines.

If the database doesn't exist, one of the nodes needs to create the table
with {disc_copies, nodes()}. If it does exist and it's fully replicated,
then we're done, but if it's not fully replicated, the nodes that are not
replicating need to join in.

I put together this code http://pastie.org/3601148 to illustrate my idea.
It might be bad for whatever reason, but it's just to get my message across.

Does this algorithm make sense ? Is this the right direction I'm headed ?
I'd be grateful for any hints.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20120315/e028017c/attachment.htm>

More information about the erlang-questions mailing list