From owner-freebsd-stable@FreeBSD.ORG Mon Dec 3 10:28:19 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 CB7F416A417 for ; Mon, 3 Dec 2007 10:28:19 +0000 (UTC) (envelope-from fbsd-stable@mawer.org) Received: from outbound.icp-qv1-irony-out3.iinet.net.au (outbound.icp-qv1-irony-out3.iinet.net.au [203.59.1.148]) by mx1.freebsd.org (Postfix) with ESMTP id 5782A13C46A for ; Mon, 3 Dec 2007 10:28:18 +0000 (UTC) (envelope-from fbsd-stable@mawer.org) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgAAAMJoU0fLzq3r/2dsb2JhbAAI X-IronPort-AV: E=Sophos;i="4.23,243,1194188400"; d="scan'208";a="189893384" Received: from unknown (HELO [10.24.1.1]) ([203.206.173.235]) by outbound.icp-qv1-irony-out3.iinet.net.au with ESMTP; 03 Dec 2007 19:28:16 +0900 Message-ID: <4753D9D7.7060900@mawer.org> Date: Mon, 03 Dec 2007 21:26:31 +1100 From: Antony Mawer User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) MIME-Version: 1.0 To: Alexey Popov References: <20071201213732.GA16638@cannabis.dataforce.net> <1497741406.20071201230441@rulez.sk> <20071202174540.GA29572@cannabis.dataforce.net> <200712020844.49718.linimon@FreeBSD.org> <4753C9E4.1060200@chistydom.ru> <4753D157.80208@chistydom.ru> In-Reply-To: <4753D157.80208@chistydom.ru> Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-stable@freebsd.org, Alexey Vlasov , Mark Linimon 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: Mon, 03 Dec 2007 10:28:19 -0000 On 3/12/2007 8:50 PM, Alexey Popov wrote: > Hi > > Alexey Popov wrote: >> Now we also have terribly performing PostgreSQL on 8-core server. We >> noticed the slowdown after moving PostgreSQL from 2xXeon 3.0 >> Apache+PostgreSQL server to dedicated PostgreSQL server. I collected >> some stats (see attach) before moving to Linux. > Sorry for the broken top ouptut in previuos message. Here's the correct > one. > > last pid: 70857; load averages: 35.05, 37.11, 33 up 25+23:08:00 12:46:29 > 94 processes: 46 running, 48 sleeping > CPU: 17.0% user, 0.0% nice, 80.5% system, 0.2% interrupt, 2.3% idle > Mem: 1209M Active, 1890M Inact, 494M Wired, 143M Cache, 214M Buf, 127M Free > Swap: 2048M Total, 72K Used, 2048M Free Have you tried testing with different values for kern.hz? I am by no means an expert, but have stumbled across various postings over the past few years that suggest the high value (1000) used by modern (5.x+?) kernels can be pessimistic for some workloads... If you could try testing with some other values by setting in /boot/loader.conf, eg: kern.hz="100" Perhaps testing 100 and 200 to see how they fare against the default value of 1000, would at least provide some indicator as to whether this has any bearing on performance. Some with a better knowledge of the kernel internals may be able to support or dimiss this idea, but as Kris is off on holidays I figured any suggestion was worthwhile! ;-) I'd also like to say thanks for your efforts to help test and track down the cause of these performance problems - in the end the whole community benefits, so the more you are able to test and help resolve these things the better for us all... :-) --Antony