<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>leveldb uses LSM-tree while dets linear hash like schema.</div><div>I do agree about leveldb usage in general. </div><div>However, I am looking for explicit linear hashing storage.</div><div><br></div><div>- Dmitry</div><div> </div><br><div><div>On Sep 8, 2013, at 11:05 PM, OvermindDL1 <<a href="mailto:overminddl1@gmail.com">overminddl1@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><p dir="ltr">I would recommend leveldb if you need local and fast storage, there is a great erlang library for it too.</p>
<div class="gmail_quote">On Sep 8, 2013 2:03 PM, "Janos Hary" <<a href="mailto:janos.n.hary@gmail.com">janos.n.hary@gmail.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Dimitry,<br>
<br>
Not exactly what you asked, but I measured the write performance of mnesia<br>
disc_only bag table, which is backed by dets. I used the following function<br>
to generate records, where I can set the amount of repeating keys by<br>
?REPCOUNT:<br>
<br>
fill_modulo(_, Tab, 0, _, _, AccessMod) -><br>
        {ok, tab_size(Tab, AccessMod)};<br>
fill_modulo(run, Tab, N, Max, T, AccessMod) -><br>
        T1 = progress(N, Max, T),<br>
        R = #trec{ dbid = N rem ?REPCOUNT, data1 = <<"Hello World!">>, data2<br>
= Max - N },<br>
        case write_transaction(Tab, R, AccessMod) of<br>
                ok -><br>
                        fill_modulo(run, Tab, N-1, Max, T1, AccessMod);<br>
                error -><br>
                        {error, Max-N}<br>
        end.<br>
<br>
This is the result of inserting 4M records with ?REPCOUNT set to 10000 (each<br>
line shows the running time of the given 5% of the whole task):<br>
......... 11.01s at 5%<br>
......... 11.44s at 10%<br>
......... 12.39s at 15%<br>
......... 12.37s at 20%<br>
......... 12.89s at 25%<br>
......... 13.53s at 30%<br>
......... 14.09s at 35%<br>
......... 14.04s at 40%<br>
......... 15.07s at 45%<br>
......... 14.84s at 50%<br>
......... 15.52s at 55%<br>
......... 15.49s at 60%<br>
......... 16.57s at 65%<br>
......... 16.25s at 70%<br>
......... 17.60s at 75%<br>
......... 16.89s at 80%<br>
......... 17.41s at 85%<br>
......... 18.63s at 90%<br>
......... 17.77s at 95%<br>
.........<br>
tab7 -> (ok) modulo insert into bag 4000000 of 4000000 in 306.931000s<br>
<br>
And this is the result of the same test ran with ?REPCOUNT set to 100:<br>
......... 30.34s at 5%<br>
......... 70.68s at 10%<br>
......... 117.20s at 15%<br>
......... 163.29s at 20%<br>
......... 203.08s at 25%<br>
......... 246.20s at 30%<br>
... and giving up waiting.<br>
<br>
Since then I learned some other problems using mnesia/dets in this manner<br>
(see my post 'mnesia silent failure and table corruption' and Ahmed Omar's<br>
reply), and I stopped further investigation. Now I'm evaluating Berkely DB<br>
for the task.<br>
<br>
Best Regards,<br>
Janos<br>
<br>
-----Original Message-----<br>
From: <a href="mailto:erlang-questions-bounces@erlang.org">erlang-questions-bounces@erlang.org</a><br>
[mailto:<a href="mailto:erlang-questions-bounces@erlang.org">erlang-questions-bounces@erlang.org</a>] On Behalf Of Dmitry Kolesnikov<br>
Sent: Sunday, September 08, 2013 9:08 PM<br>
To: erlang-questions Questions<br>
Subject: Re: [erlang-questions] dets disk i/o<br>
<br>
ping!<br>
It looks that I should measure it by myself.<br>
<br>
Best Regards,<br>
Dmitry<br>
<br>
On Sep 4, 2013, at 12:09 AM, Dmitry Kolesnikov <<a href="mailto:dmkolesnikov@gmail.com">dmkolesnikov@gmail.com</a>><br>
wrote:<br>
<br>
> Hello,<br>
><br>
> Does any one run a disk i/o analysis on dets tables?<br>
> I am very curious about bag case, write scenario.<br>
><br>
> Let's assume that I have a key which is associated with multiple entries.<br>
> What is dets behaviour when I am writing a new entry to same key.<br>
> Does it make append-only to data slot? or Does it read/write whole slot?<br>
><br>
> Best Regards,<br>
> Dmitry<br>
<br>
_______________________________________________<br>
erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
<br>
_______________________________________________<br>
erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
</blockquote></div>
</blockquote></div><br></body></html>