<p dir="ltr">You can mix as you want, if ram space is not a problem I would use disc_copies on a two nodes.</p>
<br><div class="gmail_quote"><div dir="ltr">tis 1 mar 2016 18:46 Khitai Pang <<a href="mailto:khitai.pang@outlook.com">khitai.pang@outlook.com</a>> skrev:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
I'm storing user accounts and organizations (a tree of users, i.e.<br>
departments, sub-departments, etc) in mnesia tables. Modification to<br>
the data is not very frequent, i.e. not as frequent as a message queue.<br>
I can't afford losing the data. Assume I have 9 erlang nodes (Linux VMs<br>
in a clound), and I haven't decided how many of them should be used for<br>
handling client connections and how many should be used for data<br>
storage/backup.<br>
<br>
I know that the more nodes a table is replicated on, the slower writing<br>
to it will be; I also know that ram copies are faster than disk copies;<br>
I am seeking to find a balance between performance and data safety. How<br>
should the tables be replicated? Should I use ram copies or disk copies<br>
or a hybrid scheme? Can the data be in ram copies on some nodes and<br>
backed up in disk only copies on some other nodes? If this is possible,<br>
will it provide performance as ram copies while still have data safety<br>
like disk copies?<br>
<br>
What is the best practice here?<br>
<br>
<br>
Thanks<br>
Khitai<br>
_______________________________________________<br>
erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org" target="_blank">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" rel="noreferrer" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
</blockquote></div>