Unix Programming - Re: why so many open files?

This is Interesting: Free IT Magazines  
Home > Archive > Unix Programming > June 2004 > Re: why so many open files?





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Re: why so many open files?
Shea Martin

2004-06-30, 6:02 pm

Nick Landsberg wrote:
> Shea Martin wrote:
>
>
>
>
> Hmmm... 50 requests per minute.
>
> If the "holding time" of this socket averaged 5 seconds,
> then, during any given average period of time, you
> would be holding 250 sockets open.
>
> If the clients start to time out and *all* hold the
> socket open for 10 seconds, you would need 500
> file descriptors to handle that situation.
>
> (N (number of sockets) = Arrival Rate of requests
> * Holding Time of socket).
>
> If you can't increase the fd's per process, reduce the
> timeout to 5 seconds rather than 10. 5 will almost
> guarantee you safety, unless the the holding time
> of a valid request is substantially longer than
> the timeout time. In this case you have to do
> complex arithmetic regarding stuff such as Erlang
> blocking factors.
>


The average length of a request is much less than a second. I think that main
problem is leaked file descriptors.

But I am going to change the close-wait time anyway.

~S
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com