From owner-freebsd-stable@FreeBSD.ORG Tue Nov 20 17:45:34 2007 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 224D616A41A for ; Tue, 20 Nov 2007 17:45:34 +0000 (UTC) (envelope-from lol@chistydom.ru) Received: from comtv.ru (comtv.ru [217.10.32.17]) by mx1.freebsd.org (Postfix) with ESMTP id 7CE6113C459 for ; Tue, 20 Nov 2007 17:45:33 +0000 (UTC) (envelope-from lol@chistydom.ru) X-UCL: actv Received: from yoda.org.ru ([83.167.98.162] verified) by comtv.ru (CommuniGate Pro SMTP 4.1.8) with ESMTP id 20952719; Tue, 20 Nov 2007 20:45:31 +0300 Received: from [192.168.102.10] (unknown [192.168.102.10]) (Authenticated sender: llp@soekris.ru) by yoda.org.ru (Postfix) with ESMTP id EA6D728CF5; Tue, 20 Nov 2007 20:45:49 +0300 (MSK) Message-ID: <47431D21.4050804@chistydom.ru> Date: Tue, 20 Nov 2007 20:45:05 +0300 From: Alexey Popov User-Agent: Thunderbird 2.0.0.6 (X11/20070924) MIME-Version: 1.0 To: Tom Evans References: <4741905E.8050300@chistydom.ru> <47419AB3.5030008@chistydom.ru> <4741B3DE.2000009@chistydom.ru> <47430AE8.7050408@chistydom.ru> <1195577222.82763.20.camel@localhost> In-Reply-To: <1195577222.82763.20.camel@localhost> Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-stable@freebsd.org, Ivan Voras Subject: Re: 2 x quad-core system is slower that 2 x dual core on FreeBSD X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Nov 2007 17:45:34 -0000 Hi. Tom Evans wrote: >> After that I rebuilt with SMP GENERIC kernel and put on that server 2 >> times more requests that UP could handle. For the first time it worked >> good. Then I increased load to 2.5 times more than UP. Immediately >> Apache child count increased to MaxClients (24), most of them in RUN >> state, and %sys became greater than %user (see attach). I think after >> some threshold of load FreeBSD is paying more CPU time to the management >> of running processes than to run them. > MaxClients of 24 seems very low for a 8 cpu box, running prefork MPM. On > our quad CPU boxes, running custom apache modules, we use > MaxClients 70 > MinSpareServers 5 > MaxSpareServers 15 > StartServers 20 > Perhaps you are seeing high system load because the system is having to > maintain a lot of queued connections. Certainly, our load remains > in-between comfortable margins, except when heavily stressed. I believe 8-core FreeBSD server is able to maintain 1024 waiting TCP connections without measurable CPU load. As of this problem: increasing MaxClients leads to growing %sys part of CPU load. Generally large MaxClients value is useful when most Apache children are waiting for I/O or something else but CPU. With best regards, Alexey Popov