[Mono-dev] Problem handling more the 1024 file handle

Torello Querci tquerci at gmail.com
Fri Nov 4 06:18:05 EDT 2011


Hy Robert,

On 32bit arch IntPtr is 32bit, on 64 bit arch, IntPrt is 64 bit.

However I try your suggestion but the setrlimit no more work. Looking
inside the strace output this is the setrlimit syscall:

setrlimit(RLIMIT_NOFILE, {rlim_cur=20000, rlim_max=0}) = -1 EINVAL
(Invalid argument)

As you can see now the parameters are now wrong and the code cannot go on.

Using IntPrt the strace output was:

setrlimit(RLIMIT_NOFILE, {rlim_cur=20000, rlim_max=20000}) = 0


2011/11/4 Robert Jordan <robertj at gmx.net>:
> On 04.11.2011 10:49, Torello Querci wrote:
>> Sorry, You are right .... I'm on 32bit arch
>
> Then you need this:
>
>          struct rlimit {
>                 public long rlimit_cur;
>                 public long rlimit_max;
>          }
>
> Robert
>
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
>


More information about the Mono-devel-list mailing list