<div dir="ltr"><br><div>Hi.</div><div><br></div><div>I'm trying to get some idea about the proper way of configuring allocators.</div><div><br></div><div>We are running our erlang software flussonic, it captures around 1,5 gbit/s of input via TCP, allocates lot of binaries from 500 bytes to 1500 bytes and then prepares large binaries around 1 megabyte (video blobs). There are produced around 250 such blobs per second.</div><div><br></div><div><br></div><div>When I launch erlang with:</div><div><br></div><div>







<p class="gmail-p1"><span class="gmail-s1">+stbt db +sbwt short +swt very_low +sfwi 20</span> +zebwt short +sub true +MBas aoffcaobf +MBacul 0</p><p class="gmail-p1">I get around 2000 mmaps and munmaps per second and recon_alloc tells that I have 98% of usage.  It looks rather strange, so I tried to play with tunings and switched to:</p><p class="gmail-p1"><br></p><p class="gmail-p1">







</p><p class="gmail-p1"><span class="gmail-s1">+stbt db +sbwt short +swt very_low +sfwi 20</span> +zebwt short +sub true +MBas aoffcaobf +MBsbct 4096 +MBacul de +Mulmbcs 131071 +Mumbcgs 1 +Musmbcs 4095</p><p class="gmail-p1"><br></p><p class="gmail-p1">I'm not quite sure that my settings are sane, but I tried to make very large multiblock areas and try to store my binaries inside large areas (not single block carrier, but multiblock carrier).</p><p class="gmail-p1">With these settings I get about 50 mmap/munmap per second. Seems that hugepages are not used (frankly speaking I thought to autoenable them).</p><p class="gmail-p1">But with these settings I get about 50% of usage and all servers are quickly getting killer by OOM killer.</p><p class="gmail-p1">With these flags I tried to hint allocator to create 128MB large areas and objects smaller than 4 megabytes to put into there areas.</p><p class="gmail-p1"><br></p><p class="gmail-p1"><br></p><p class="gmail-p1">So my questions are:</p><p class="gmail-p1">1) should I worry about 2000 of mmap/unmap syscalls per second?<br></p><p class="gmail-p1">2) should I try to reduce usage of sbct and increase usage of mbct?</p><p class="gmail-p1">3) are my flags to erlang VM compatible with each other?</p><p class="gmail-p1">4) maybe some other hints?</p><p class="gmail-p1"><br></p></div></div>