From owner-freebsd-questions Sun Sep 8 15:26:14 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 583C037B400 for ; Sun, 8 Sep 2002 15:26:12 -0700 (PDT) Received: from nic.upatras.gr (nic.upatras.gr [150.140.129.30]) by mx1.FreeBSD.org (Postfix) with SMTP id D7C7A43E4A for ; Sun, 8 Sep 2002 15:26:10 -0700 (PDT) (envelope-from keramida@ceid.upatras.gr) Received: (qmail 852 invoked from network); 8 Sep 2002 22:19:26 -0000 Received: from upnet-dialinpool-72.upatras.gr (HELO hades.hell.gr) (150.140.128.182) by nic.upatras.gr with SMTP; 8 Sep 2002 22:19:26 -0000 Received: from hades.hell.gr (hades [127.0.0.1]) by hades.hell.gr (8.12.6/8.12.6) with ESMTP id g88MQ5SH004324 for ; Mon, 9 Sep 2002 01:26:05 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Received: (from charon@localhost) by hades.hell.gr (8.12.6/8.12.6/Submit) id g88MKxP0004256; Mon, 9 Sep 2002 01:20:59 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Date: Mon, 9 Sep 2002 01:20:59 +0300 From: Giorgos Keramidas To: Chris Bolt Cc: freebsd-questions@FreeBSD.ORG Subject: Re: How do I increase maxsockets? Message-ID: <20020908222059.GA4132@hades.hell.gr> References: <3D7BBA44.1080705@bolt.cx> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3D7BBA44.1080705@bolt.cx> X-PGP-Fingerprint: C1EB 0653 DB8B A557 3829 00F9 D60F 941A 3186 03B6 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message: <3D7BBA44.1080705@bolt.cx> Chris Bolt wrote: > I'm running a very busy web server with thttpd on FreeBSD > 4.6-RELEASE, and I need it to be able to handle more than 16,000 > connections. I've gone through everything else and I am almost > positive that the only bottleneck is the kern.ipc.maxsockets sysctl: > > # sysctl kern.ipc.maxsockets > kern.ipc.maxsockets: 16424 > > But I can't just set that, since it's ready only. The only way to > raise this magic number that I have found is by raising maxusers. The value of maxsockets can not be larger than the value of kern.maxfiles or kern.ipc.nmbclusters. You have to increase both of these accordingly, before increasing kern.ipc.maxsockets. You might also want to tinker with the value of kern.maxfilesperproc while you're at it. This limits the number of open files (or sockets) that a single process can have. - Giorgos To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message