From owner-freebsd-hackers Sun Dec 8 08:45:03 1996 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.4/8.8.4) id IAA16812 for hackers-outgoing; Sun, 8 Dec 1996 08:45:03 -0800 (PST) Received: from sdev.usn.blaze.net.au (sdev.usn.blaze.net.au [203.17.53.19]) by freefall.freebsd.org (8.8.4/8.8.4) with ESMTP id IAA16778 for ; Sun, 8 Dec 1996 08:44:30 -0800 (PST) Received: (from davidn@localhost) by sdev.usn.blaze.net.au (8.8.4/8.6.9) id DAA07909; Mon, 9 Dec 1996 03:42:26 +1100 (EST) Message-ID: Date: Mon, 9 Dec 1996 03:42:25 +1100 From: davidn@sdev.usn.blaze.net.au (David Nugent) To: angio@aros.net (Dave Andersen) Cc: mbarkah@hemi.com (Ade Barkah), imb@scgt.oz.au (michael butler), jfesler@calweb.com, hackers@FreeBSD.ORG Subject: Re: Apache and huge numbers of IP's.. References: <199612080242.TAA01291@hemi.com> <199612080408.VAA07389@fluffy.aros.net> X-Mailer: Mutt 0.50 Mime-Version: 1.0 In-Reply-To: <199612080408.VAA07389@fluffy.aros.net>; from Dave Andersen on Dec 7, 1996 21:08:06 -0700 Sender: owner-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk Dave Andersen writes: > > > options "CHILD_MAX=512" > > > options "OPEN_MAX=512" > > > > Is this sufficient ? You still have: > > > > #ifndef FD_SETSIZE > > #define FD_SETSIZE 256 > > #endif > > > > in /usr/include/sys/types.h. FD_SETSIZE ultimately limits the > > At the beginning of your program, before ALL other #includes, say: > > #define FD_SETSIZE 512 Examining the source for the kernel implementation of select(2) in sys/kern/sys_generic.c suggests that this won't help. The kernel would also needs to understand the new FD_SETSIZE for fd's >= FD_SETSIZE to be seen at that level. Modifying the define in sys/sys/types.h directly would seem to be the only way, after which a kernel build/install and make world would be necessary. And probably rebuild any ports and extras that use select() as well. Perhaps FD_SETSIZE should be set higher by default? I'm also wondering if this might cause transition problems. :-( A more reasonable default would be 1024 (imho) - this is after all only 128 bytes in an fd_set block. The problem with virtual domains is becoming increasingly common and 256 is definitely too small a value. Regards, David Nugent, Unique Computing Pty Ltd - Melbourne, Australia Voice +61-3-9791-9547 Data/BBS +61-3-9792-3507 3:632/348@fidonet davidn@blaze.net.au http://www.blaze.net.au/~davidn