<div dir="ltr"><div><div><div><div><div>@Raimo, I'll try increasing read_packets.<br>How does increasing read_packets work compared to increasing recbuf?<br>Both have the same effect only read_packets keep unhanded packets as Erlang messages while recbuf keep them as raw data?<br><br>Do you have a suggestion how to check the effect of increasing it?<br></div>How do I know if UDP packets where dropped on the network or on the buffer because my Erlang process didn't process them fast enough?<br><br></div>@Andreas<br></div>How did you compare gen_socket with gen_udp?<br></div>Before going the nif way, I want to be sure that it improves my throughput.<br></div>Why a nif can handle more UDP packets than gen_udp? I thought that the Erlang code should be the bottleneck in both cases.<br><div><div><div><div><br></div></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Nov 21, 2016 at 10:29 AM, Andreas Schultz <span dir="ltr"><<a href="mailto:aschultz@tpip.net" target="_blank">aschultz@tpip.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 11/19/2016 08:51 PM, Max Lapshin wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
ah, it is receive?<br>
<br>
We had to write special port driver to receive 500 mbit/s of UDP video multicast<br>
</blockquote>
<br></span>
With [1] I'm able to forward (receive and send) 500mbit/s on a single core. The<br>
interface itself is a port driver combined with a nif and works only on Linux<br>
(and maybe OSX), but the actual forwarding code is pure Erlang [2].<br>
<br>
Andreas<br>
<br>
[1]: <a href="https://github.com/travelping/gen_socket" rel="noreferrer" target="_blank">https://github.com/travelping/<wbr>gen_socket</a><br>
[2]: <a href="https://github.com/travelping/gtp_u_edp/blob/master/src/gtp_u_edp_forwarder.erl" rel="noreferrer" target="_blank">https://github.com/travelping/<wbr>gtp_u_edp/blob/master/src/gtp_<wbr>u_edp_forwarder.erl</a><br>
</blockquote></div><br></div>