Tamouh H. hakmi at
Thu Oct 6 22:26:32 PDT 2005


I'm having problems resolving FD_SETSIZE issues with FreeBSD 5.4 and Apache.
This error always continues:

[Thu Oct 6 14:51:31 2005] [warn] send body: filedescriptor (1367) larger
than FD_SETSIZE (1024) found, you probably need to rebuild Apache with a

I did re-compile apache (we made sure FD_SETSIZE is enabled)

however, the problem still occurs. so I modified
/usr/local/apache/bin/apachectl and added :

ulimit -n 16480
also in

But the same problem continues, it is happening much less than before, but
we continue to see it.

<?PHP echo `ulimit -n`; ?> shows: 11095

How else would we need to increase the FD_SETSIZE on FreeBSD 5 ?

I read somewhere there is also need to change it at:
/usr/include/sys/select.h ?

This requires recompiling Kernel, correct ? How about adding this to the
FBSD kernel:
options FD_SETSIZE nnn as suggested in Apache FAQ:

Also it appears there are different places the FD_SETSIZE need to be changed
as per:

I couldn't find good resources about FD_SETSIZE or tuning FreeBSD for large
sites except to:


Any input or experiences with these are welcomed.



More information about the freebsd-questions mailing list