Too many open files error with Netty

Trustin Lee (이희승) trustin at gmail.com
Tue Oct 27 03:37:42 EDT 2009


2009/10/27 Trustin Lee (이희승) <trustin at gmail.com>:
> On Tue, Oct 27, 2009 at 2:31 PM, Trustin Lee (이희승) <trustin at gmail.com> wrote:
>> Hi Albert,
>>
>> On Thu, Oct 22, 2009 at 4:09 PM, Albert Strasheim <fullung at gmail.com> wrote:
>>> Hey Trustin
>>>
>>> On Fri, Oct 16, 2009 at 11:09 AM, Albert Strasheim <fullung at gmail.com> wrote:
>>>> On Fri, Oct 16, 2009 at 10:05 AM, Trustin Lee (이희승) <trustin at gmail.com> wrote:
>>>>> FD leak should not occur at any case.  I will take a look soon.  Does
>>>>> this issue occur only in Solaris or also in Linux?
>>>> I am seeing the same behaviour on Linux, but the
>>>> NioClientSocketChannel leak causes the process to come to a halt
>>>> before I start seeing any "Too many open files" errors.
>>>
>>> Have you had a chance to look at this yet?
>>
>> I'm investigating this issue right now.  Sorry about the delay.  I
>> will get back to you again soon.
>
> My observation so far is that the file descriptors are released in the
> slower rate then the creation rate.  For some reason, the file
> descriptor are not released immediately.  In the long term, the file
> descriptors of the closed sockets are released completely according to
> 'lsof'.  Release rate is a problem though - I will keep investigating.

I've just checked in the fix.  The number of open files will not
exceed (the number of open channels) + 128 * (the number of active
ChannelFactories).

HTH

-- Trustin Lee, http://gleamynode.net/



More information about the netty-users mailing list