mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emmanuel Lecharny (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (DIRMINA-1069) Number of pipe and eventpoll goes up about 30 when connecting to server with NioSocketConnector
Date Wed, 26 Jul 2017 04:01:08 GMT

    [ https://issues.apache.org/jira/browse/DIRMINA-1069?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16101140#comment-16101140
] 

Emmanuel Lecharny commented on DIRMINA-1069:
--------------------------------------------

One thing is important to understand : you can use a {{Connector}} to connect to many remote
hosts. In order to allow such a thing, the {{Connector}} internally will create more than
a thread (actually, it defaults to Nb processors +1 threads being created : if you are running
with 4 processors, that is 5 threads. This is configurable). 

In any case, each connection to a remote host will eat a socket, which will be a linux file
descriptor.

Also note that the linux limit is configurable, and if you really need to exceed the default
limit (which should be 2000, I think), then there is nothing bad in tuning this parameter
: you are not a 'normal' linux user.

Still, I'd like to see a {{lsof}} run on yoru process id, to get a glance at what your process
is using.

> Number of pipe and eventpoll goes up  about 30 when connecting to server with NioSocketConnector
> ------------------------------------------------------------------------------------------------
>
>                 Key: DIRMINA-1069
>                 URL: https://issues.apache.org/jira/browse/DIRMINA-1069
>             Project: MINA
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.0.3, 2.0.16
>         Environment: Linux version 2.6.32-431.el6.x86_64(CentOS 65)
> Java 1.7.0_75
>            Reporter: Wenzhi Wu
>            Priority: Critical
>         Attachments: After connecting to server successfully.PNG, Before connecting to
server.PNG, File descriptors.PNG
>
>
> When connecting to server with NioSocketConnector,number of pipe and eventpoll goes up
about 30.When I connect 1000 times,it will consume more file handles,finally exceed linux
maximum limits.I think,maybe it is worser.
> Before connecting to server,number of file descriptors is 269.After it,it becomes 301.
> So,how did everybody solve it?



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message