[Mono-bugs] [Bug 565686] New: Max number of Sockets on Linux (1020)

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Thu Dec 17 12:58:03 EST 2009


http://bugzilla.novell.com/show_bug.cgi?id=565686

http://bugzilla.novell.com/show_bug.cgi?id=565686#c0


           Summary: Max number of Sockets on Linux (1020)
    Classification: Mono
           Product: Mono: Class Libraries
           Version: 2.4.x
          Platform: x86
        OS/Version: UNIX Other
            Status: NEW
          Severity: Major
          Priority: P5 - None
         Component: System
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: osp at tinet.org
         QAContact: mono-bugs at lists.ximian.com
          Found By: Community User
           Blocker: ---


Created an attachment (id=333248)
 --> (http://bugzilla.novell.com/attachment.cgi?id=333248)
A Program.cs to reproduce the problem

Description of Problem:

Any mono application running on Linux (this doesn't happen on Mono Windows or
NET Framework) issues a "System.Net.Sockets.SocketException: Too many open
files" when handling more than 1020 sockets at once.


Steps to reproduce the problem:

1. I have attached a test case that reproduces the problem.


Actual Results:
10 Socket connection initiated, 10 Socket accepted
20 Socket connection initiated, 20 Socket accepted
30 Socket connection initiated, 30 Socket accepted
[...]
490 Socket connection initiated, 490 Socket accepted
500 Socket connection initiated, 500 Socket accepted
510 Socket connection initiated, 510 Socket accepted

Unhandled Exception: System.Net.Sockets.SocketException: Too many open files
  at System.Net.Sockets.Socket..ctor (AddressFamily family, SocketType type,
ProtocolType proto) [0x0005e] in
/oriolsp/downloads/mono-2.4.2.3/mcs/class/System/System.Net.Sockets/Socket.cs:793


Expected Results:
10 Socket connection initiated, 10 Socket accepted
20 Socket connection initiated, 20 Socket accepted
30 Socket connection initiated, 30 Socket accepted
[...]
5970 Socket connection initiated, 5970 Socket accepted
5980 Socket connection initiated, 5980 Socket accepted
5990 Socket connection initiated, 5990 Socket accepted
6000 Socket connection initiated, 6000 Socket accepted

How often does this happen? 

Always.

Additional Information:

This happens on all Linux I have tried (CentOS 5.x, also older Red Hat), on
mono version 2.4.2.3 and older versions. I haven't tested with latest mono
version, but I am pretty sure the issue remains, as no fix have been done about
this (as far as I know).

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the mono-bugs mailing list