Search squid archive

Re: Override Max File Descriptors on Windows

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 28/10/11 02:38, Ghassan Gharabli wrote:
Hello,


I am looking for information might help me with your experience!


I have compiled Squid 2.7Stable9 on Windows using MinGW and Cygwin but
the thing I have already tried to avoid the file descriptors
limitation but with no luck anyway . The problem is MinGW is linking
with msvcrt.dll on Windows  and I am being forced to get max fd as
2048 on Windows .. so Is there anyway I can compile Squid Under
something to override FD definitions! .


I spent few days searching for the source code of msvcrt.dll so I can
edit the max 2048 but still no luck . Does anyone know who can direct
me to someone who might get the source code of msvcrt.dll and that
would be the best idea to improve performance on Windows or else I
need to work on changing the Squid Windows I/O .

Something like replacing the use of the POSIX I/O interfaces in mysys
on Windows with the Win32 API calls (CreateFile, WriteFile, etc). All
that I know , the Windows API does not support opening files in append
mode in all cases.


The day when network I/O on Windows supports POSIX enough that it can be done via CreateFile/WriteFile or some equivalent will be a happy day for many programmers around the world currently having to keep two sets of FD flying.

Windows FS in Squid uses the native Win32 Overlapping I/O thread interfaces for disk access whenever that is available. The FD limit is not related to that.

The 2048 FD limit (actually 2048 _handle_ limit per process) is built into the select() algorithm. It affects POSIX as well as Windows. But Windows support in Squid does not exist for any of the more advanced network I/O methods.

See comm_*.c for available comm modules. The ones with a Win32 API version have a win32 suffix. If you want to develop a new I/O module that works through some other Windows API for more FD and/or faster operation we are keen to see the results.

Note: that any new submissions will be applied upstream against Squid-3.HEAD. But the nature of the comm I/O modules currently makes them easily ported between the two Squid versions with few changes. So you can develop on Squid-2 and port after its proven working.

PS. Please contact squid-dev mailing list for more detailed help and developer assistance. This is an admin focussed help list.

Amos
--
Please be using
  Current Stable Squid 2.7.STABLE9 or 3.1.16
  Beta testers wanted for 3.2.0.13


[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux