Re: surprisingly slow accept/connect cycle time

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In <[email protected]> "Clifford T. Matthews" <[email protected]> writes:

>While writing some test code, I was surprised to find a couple
>processes running very slowly.  The attached program illustrates this.
>The program forks and the child attempts to accept 1000 connections.
>The parent attempts to connect 1000 times.  This often takes minutes
>to run, on 2.4 kernels and 2.6 kernels (including 2.6.12-rc4).

Have you tried using non-blocking sockets ?

I've been doing some network programming myself lately, and my apps 
have no problem handling a sustained load of 40 connections/second -
which should handle your testcase in 25 seconds. And I'm quite sure it
will be less, because it has handled peak loads of several hundred
connections per second.

But my program uses non-blocking sockets exclusively.


Henrik

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux