Proposed patch for Samba-2.0.7 to allow Solaris open more than
1014 (or rlim_fd_max) files
boehm at nortelnetworks.com
Fri Jan 26 10:39:12 GMT 2001
On Fri, Jan 26, 2001 at 10:08:33AM +0100, Andy Polyakov wrote:
>>>>> "Andy" == Andy Polyakov <appro at fy.chalmers.se> writes:
>>>>> "David" == David Boyce <dsb at world.std.com> writes:
Andy> Compiling with sfio doesn't solve all the problems. The remaining
Andy> problem is that we don't know if library functions called by SAMBA
Andy> call fopen and company. Linking with binary compatibility shim
Andy> doesn't help as it would presumably suffer from the very same
Andy> deficiency (or won't be binary compatible).
David> Please remember, as mentioned before, that this whole
David> stdio/sfio/MAX_OPEN thing is a sidetrack from the real (setrlimit)
Andy> Sure we remember that, but it was the author of the original post
Andy> who brought the issue up:-)
I'm the person who brought it up :-(. I'm afraid I didn't David credit where
credit is due. The analysis of SFIO and FDs between 256 and 1024 is all
David's work. The information I included was a summary of an analysis he
posted to the CCIUG (ClearCase International Users Group) mailing list. It was
not my intent to take credit for his work.
David> ... any idea why it didn't get rolled in?
Andy> No. Probably because it was brought up as a side comment, just like
Andy> this time:-)
Andy> Was it just overlooked or did someone have a problem with it?
Perhaps it should be raised as a separate issue then so that it doesn't get
Andy> Rather nobody (but me at that time) experienced a problem without
Andy> it... Indeed, it takes a site running Solaris (in some specific
Andy> configuration as it's most likely nss_*.so modules that use stdio
Andy> and therefore would suffer), pushing SAMBA hard on it and sticking
Andy> to Solaris when a problem arises. And there aren't many enough to
Andy> care about...
I'm not pushing it *that* hard. Approximately 400 users across 4 servers.
Andy> I should also recommend -DUSE_POLL and -DFD_SETSIZE=2400 (or
Andy> something), -DUSE_POLL effectively prevents SAMBA from using select
Andy> (which is btw very similar front-end to poll anyway) and FD_SETSIZE
Andy> scales up structures used by SAMBA itself.
I thought these were useful points. I agree that increasing FD_SETSIZE to
scale up structures is a good idea.
I decided to punt on the issue of SFIO and other functions calling open(2)
indirectly. I decided to compile samba as a 64-bit application. That increases
FD_SETSIZE to 65536, avoids problems with select and no need to shuffle file
If you can't generate a 64-bit samba I'm willing to share binaries if you'd
like to test.
Eric M. Boehm boehm at nortelnetworks.com
More information about the samba-technical