Re: [Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-24 Thread Robert Iakobashvili
Hi, On Tue, Nov 4, 2008 at 3:10 PM, Dan Kegel <[EMAIL PROTECTED]> wrote: > On Tue, Nov 4, 2008 at 4:16 AM, Richard Jones <[EMAIL PROTECTED]> wrote: > > I'm 90% finished writing up my findings as Part 3 to my comet series on > > www.metabrew.com - it turns out that my client process (C+libevent wi

RE: [Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-17 Thread Jones, Richard W
bject: Re: [Libevent-users] Patch: evhttp_connection_set_local_port On Tue, Nov 4, 2008 at 8:40 AM, Richard Jones <[EMAIL PROTECTED]> wrote: > I observed it stopped creating new connections when the local port range > was used up, so assumed that local ports weren't being allocated

Re: [Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-04 Thread Richard Jones
On Tue, 2008-11-04 at 08:32 -0800, Niels Provos wrote: > On Tue, Nov 4, 2008 at 8:24 AM, Richard Jones <[EMAIL PROTECTED]> wrote: > > Not sure I follow - I'm trying to open 1M connections from one machine > > to another machine. Only 2 machines are involved, and i'm only concerned > > with the clie

Re: [Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-04 Thread Richard Jones
On Tue, 2008-11-04 at 16:12 +, Niels Provos wrote: > On Tue, Nov 4, 2008 at 3:40 AM, Richard Jones <[EMAIL PROTECTED]> wrote: > > In order to open more than 2^16 connections (HTTP connections in my > > case) *from* one machine, you need to use multiple local IPs, > because > > the maximum local

Re: [Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-04 Thread Richard Jones
I just posted the third article about my comet experiments, which covers why I needed to patch libevent to open >1M connections: http://www.metabrew.com/article/a-million-user-comet-application-with-mochiweb-part-3/ On Tue, 2008-11-04 at 11:40 +, Richard Jones wrote: > Hi, > In order to open

Re: [Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-04 Thread Dan Kegel
On Tue, Nov 4, 2008 at 4:16 AM, Richard Jones <[EMAIL PROTECTED]> wrote: > I'm 90% finished writing up my findings as Part 3 to my comet series on > www.metabrew.com - it turns out that my client process (C+libevent with > my patch) that opens 1M connections takes 2.1GB resident once all 1M > conne

Re: [Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-04 Thread Richard Jones
On Tue, 2008-11-04 at 04:04 -0800, Dan Kegel wrote: > On Tue, Nov 4, 2008 at 3:40 AM, Richard Jones <[EMAIL PROTECTED]> wrote: > > I added "evhttp_connection_set_local_port", which in conjunction with > > evhttp_connection_set_local_address and some tcp/kernel tuning allowed > > me to open 1 millio

Re: [Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-04 Thread Dan Kegel
On Tue, Nov 4, 2008 at 3:40 AM, Richard Jones <[EMAIL PROTECTED]> wrote: > I added "evhttp_connection_set_local_port", which in conjunction with > evhttp_connection_set_local_address and some tcp/kernel tuning allowed > me to open 1 million http connections from one machine. I brought up 16 > IPs a

[Libevent-users] Patch: evhttp_connection_set_local_port

2008-11-04 Thread Richard Jones
Hi, In order to open more than 2^16 connections (HTTP connections in my case) *from* one machine, you need to use multiple local IPs, because the maximum local port number is 65536. evhttp_connection_set_local_address already exists and is suitable for this. The ephemeral port allocator, which is