Distribution with Mnesia
Ulf Wiger (ÄL2/EAB)
Tue Aug 12 12:56:16 CEST 2003
You would only call wait_for_table() for tables that need
a replica on the diskless node. Otherwise, all that is needed
is that the schema is replicated from a master node.
Since mnesia offers distribution transparency, all data will
still be accessible on each diskless node. If you have lots
of diskless nodes, you will probably not want to replicate
all data to all nodes, since it will make table updates much
From: Serge Aleynikov [mailto:serge@REDACTED]
Sent: Tuesday, August 12, 2003 12:51
To: Ulf Wiger (ÄL2/EAB)
Cc: 'Marc Ernst Eddy van Woerkom'; erlang-questions@REDACTED
Subject: Re: Distribution with Mnesia
I wonder in case of your suggested use of the msesia's distribution
what's the penalty of a restart of an "extra" node? Apparently, the
first thing such a node would do is call wait_for_table(). In my small
experiments a call to this function on a mnesia node containing a disk
image of a 15M table took a couple of minutes to complete (which seemed
conciderably long, as I would think that the disk image uses binary
format and involves no parsing). If both primary and "extra" nodes
reside in the same LAN, is the wait_for_table() call on the "extra"
diskless distributed node is as slow (or even slower due to LAN speed
vs. disk speed) than calling it on the primary node?
Ulf Wiger (ÄL2/EAB) wrote:
> If you want to have a very dynamic network of mnesia nodes,
> I suggest you configure a few nodes to hold a disk copy of
> the schema, and manage them with care. Then, you can connect
> other nodes using the mnesia 'extra_db_nodes' feature.
> These nodes will be "diskless" from mnesia's perspective,
> and may come and go at will... almost. If a diskless node
> loses contact with one of the master nodes, it should
> unconditionally restart (mnesia, at least).
> Running distributed erlang over SSL is probably a good idea.
> -----Original Message-----
> From: Marc Ernst Eddy van Woerkom
> Sent: Tuesday, August 12, 2003 04:32
> To: erlang-questions@REDACTED
> Subject: Distribution with Mnesia
> The features of Mnesia, as described in the docs, are remarkable.
> But what exactly is its useful grade of distribution?
> Is it just usuable for a well defined group (not changing too
> much in time) of nodes that are kind of close together (e.g.
> in the same corporate LAN or WAN?
> The other extreme would be a kind of P2P setting,
> with lots nodes that join and leave the net in an
> unpredictable fashion.
> Or not so extme:
> Would it allow connecting let's say 10 servers
> via the internet?
> Would inter node metadata flow be possible over
> encrypted channels?
More information about the erlang-questions