From owner-freebsd-apache@FreeBSD.ORG Tue May 6 08:08:21 2008 Return-Path: Delivered-To: freebsd-apache@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A4FFA1065685 for ; Tue, 6 May 2008 08:08:21 +0000 (UTC) (envelope-from oxy@field.hu) Received: from green.field.hu (green.field.hu [217.20.130.28]) by mx1.freebsd.org (Postfix) with ESMTP id 67AE68FC35 for ; Tue, 6 May 2008 08:08:21 +0000 (UTC) (envelope-from oxy@field.hu) Received: from localhost (green.field.hu [217.20.130.28]) by green.field.hu (Postfix) with ESMTP id BE2BBB2527 for ; Tue, 6 May 2008 09:53:08 +0200 (CEST) X-Virus-Scanned: by Amavisd-new (Spamassassin+Razor2+Pyzor+DCC+Bayes db, Clamd Antivirus) at field.hu Received: from green.field.hu ([217.20.130.28]) by localhost (green.field.hu [217.20.130.28]) (amavisd-new, port 10024) with ESMTP id VbzVWhcD-hfX for ; Tue, 6 May 2008 09:53:07 +0200 (CEST) Received: from [192.168.1.2] (dsl77-234-81-222.pool.tvnet.hu [77.234.81.222]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by green.field.hu (Postfix) with ESMTPSA id 9DAB7B24C3 for ; Tue, 6 May 2008 09:53:07 +0200 (CEST) Message-ID: <48200E67.8080208@field.hu> Date: Tue, 06 May 2008 09:53:11 +0200 From: oxy User-Agent: Thunderbird 2.0.0.14 (Windows/20080421) MIME-Version: 1.0 To: freebsd-apache@freebsd.org Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 7bit Subject: increasing file descriptors X-BeenThere: freebsd-apache@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Support of apache-related ports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 May 2008 08:08:21 -0000 hi! i am using fbsd 7.0-rel and apache 2.2.8.. my problem is that after ~230 vhosts i ran out of file descriptors.. (2x230 files, access and error log for each vhost) when i use only one error log i don't run out, however i need to use different error log for each vhost and don't want to use one and divide it later... the error in httpd-error.log is: /usr/src/lib/bind/isc/../../../contrib/bind9/lib/isc/unix/socket.c:2238: REQUIRE(maxfd <= (int)1024U) failed. /usr/src/lib/bind/isc/../../../contrib/bind9/lib/isc/unix/socket.c:2238: REQUIRE(maxfd <= (int)1024U) failed. /usr/src/lib/bind/isc/../../../contrib/bind9/lib/isc/unix/socket.c:2238: REQUIRE(maxfd <= (int)1024U) failed. sysctl settings: kern.maxfiles: 65536 kern.maxfilesperproc: 65536 kern.maxusers: 1024 thanks for your help! From owner-freebsd-apache@FreeBSD.ORG Thu May 8 05:16:43 2008 Return-Path: Delivered-To: freebsd-apache@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 057B61065677 for ; Thu, 8 May 2008 05:16:43 +0000 (UTC) (envelope-from pgollucci@p6m7g8.com) Received: from exhub015-1.exch015.msoutlookonline.net (exhub015-1.exch015.msoutlookonline.net [207.5.72.93]) by mx1.freebsd.org (Postfix) with ESMTP id E4FB18FC18 for ; Thu, 8 May 2008 05:16:42 +0000 (UTC) (envelope-from pgollucci@p6m7g8.com) Received: from [192.168.254.42] (70.88.236.22) by smtpx15.msoutlookonline.net (207.5.72.103) with Microsoft SMTP Server (TLS) id 8.1.263.0; Wed, 7 May 2008 22:16:42 -0700 Message-ID: <48228CAC.3030206@p6m7g8.com> Date: Thu, 8 May 2008 01:16:28 -0400 From: "Philip M. Gollucci" Organization: P6 Web Applications User-Agent: Thunderbird 2.0.0.14 (Windows/20080421) MIME-Version: 1.0 To: oxy References: <48200E67.8080208@field.hu> In-Reply-To: <48200E67.8080208@field.hu> Content-Type: text/plain; charset="ISO-8859-2"; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-apache@freebsd.org Subject: Re: increasing file descriptors X-BeenThere: freebsd-apache@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Support of apache-related ports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 May 2008 05:16:43 -0000 oxy wrote: > the error in httpd-error.log is: > /usr/src/lib/bind/isc/../../../contrib/bind9/lib/isc/unix/socket.c:2238: > REQUIRE(maxfd <= (int)1024U) failed. > /usr/src/lib/bind/isc/../../../contrib/bind9/lib/isc/unix/socket.c:2238: > REQUIRE(maxfd <= (int)1024U) failed. > /usr/src/lib/bind/isc/../../../contrib/bind9/lib/isc/unix/socket.c:2238: > REQUIRE(maxfd <= (int)1024U) failed. You aren't running out of file descriptions, you are confusing bind. Why are these errors in your httpd logs? If you were out of file descriptors, you would see file: table is full check the dmesg buffer. Are you using mod_domain in httpd ? > >/usr/src/lib/bind/isc/../../../contrib/bind9/lib/isc/unix/socket.c:2238: > REQUIRE(maxfd <= (int)1024U) failed. As seen in the actual source file: REQUIRE(maxfd <= (int)FD_SETSIZE); that (int)1024U comes from /usr/src/sys/sys/select.h /* * Select uses bit masks of file descriptors in longs. These macros * manipulate such bit fields (the filesystem macros use chars). * FD_SETSIZE may be defined by the user, but the default here should * be enough for most uses. */ #ifndef FD_SETSIZE #define FD_SETSIZE 1024U #endif You can raise this, but you'll need to recompile bind too. I'd start with 2048U if I were you. Bind does this b/c it indexes arrays for sockets based on this.