Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 4CCCE1337999 for ; Tue, 12 Apr 2011 05:55:24 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 43184-06 for ; Tue, 12 Apr 2011 08:55:06 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from nm11.bullet.mail.ukl.yahoo.com (nm11.bullet.mail.ukl.yahoo.com [217.146.183.185]) by mail.postgresql.org (Postfix) with SMTP id C0B651337A5D for ; Tue, 12 Apr 2011 05:55:00 -0300 (ADT) Received: from [217.146.183.215] by nm11.bullet.mail.ukl.yahoo.com with NNFMP; 12 Apr 2011 08:54:59 -0000 Received: from [217.146.183.169] by tm8.bullet.mail.ukl.yahoo.com with NNFMP; 12 Apr 2011 08:54:59 -0000 Received: from [127.0.0.1] by omp1010.mail.ukl.yahoo.com with NNFMP; 12 Apr 2011 08:54:59 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 881990.2237.bm@omp1010.mail.ukl.yahoo.com Received: (qmail 84697 invoked by uid 60001); 12 Apr 2011 08:54:59 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.co.uk; s=s1024; t=1302598499; bh=OW69GGpGBedT8jo2PkqAErKUD3W+QgQdegu+tPBzFBg=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=YjUg6V4Bm+JuFi9qasurIg4pstRJl+dH6G1zI7Wc77dKQEwcIwlDf1R4ch9t3vlwTaUzsdTu9SM9ZeV4LfmKR+CKREEbaMv5fP5oOqR5YjSOkXWBj1WgG2hYNNePPQmiZih/JhC3aYHgGUBw0Y6i/IA1e+ogpai4j000ozTX2Rk= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.co.uk; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=1mFvFefQfOl4UvoTTO2lKiyZTTVc84f7LrazKmfPEekfJ98caLxmvmrR2Ve7dsodUDbPXrCWTJuwegoFVSzc0a+EU4lmsM+zbPt23Mqa5Fl/sheARXndO1bH8LrxJNTzAI+0fJ50D3Ob85S2bKrYcXWzSCmXfz/ucAbz8Btx8Uk=; Message-ID: <768150.83213.qm@web26002.mail.ukl.yahoo.com> X-YMail-OSG: rSG2FWkVM1m9wILyjqY.GwSXxlhuEH1CnIKGqg4373UrMLG upjvco92XXxhYql6cVZsDcE.GcSvkkntUazyGBGQOBBe49tcfwBLYWJEh.NW 7OSycA5InAk9x9NYfdFQfYSYnqfBTgkispKiB9.LKckFPsI0bp_LInCZsbMp gUWMzxFNHFv_kjquPH9uB5XBe9CCpc08OWJj8iUIK_Pld4On66wPefGACw6e GferBp1UVXj4XGvZSQ.3j_tvROE9snkbS73dTk3iHkyRw3YnZfh560N4UILL cnzT_bR0lu5va3NESYl0WsNtNAfy.i8CzmBuXvbwZOYv6D5NEQ5nK.fg2U6w PGT5prZy3l9kLaINSF9YmPR5Big-- Received: from [83.100.146.195] by web26002.mail.ukl.yahoo.com via HTTP; Tue, 12 Apr 2011 09:54:59 BST X-Mailer: YahooMailClassic/12.0.2 YahooMailWebService/0.8.109.295617 Date: Tue, 12 Apr 2011 09:54:59 +0100 (BST) From: Glyn Astill Subject: Re: Linux: more cores = less concurrency. To: Kevin Grittner , Merlin Moncure Cc: david@lang.hm, Steve Clark , "Joshua D. Drake" , Scott Marlowe , pgsql-performance@postgresql.org In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.898 tagged_above=-10 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RFC_ABUSE_POST=0.001 X-Spam-Level: X-Archive-Number: 201104/147 X-Sequence-Number: 43209 --- On Tue, 12/4/11, Merlin Moncure wrote:=0A=0A> >> T= he issue I'm seeing is that 8 real cores=0A> outperform 16 real=0A> >> core= s, which outperform 32 real cores under high=0A> concurrency.=0A> >=0A> > W= ith every benchmark I've done of PostgreSQL, the=0A> "knee" in the=0A> > pe= rformance graph comes right around ((2 * cores) +=0A> > effective_spindle_c= ount). =A0With the database fully=0A> cached (as I=0A> > believe you mentio= ned), effective_spindle_count is=0A> zero. =A0If you=0A> > don't use a conn= ection pool to limit active=0A> transactions to the=0A> > number from that = formula, performance drops off. =A0The=0A> more CPUs you=0A> > have, the sh= arper the drop after the knee.=0A> =0A> I was about to say something simila= r with some canned=0A> advice to use a=0A> connection pooler to control thi= s.=A0 However, OP=0A> scaling is more or=0A> less topping out at cores / 4.= ..yikes!.=A0 Here are my=0A> suspicions in=0A> rough order:=0A> =0A> 1. The= re is scaling problem in client/network/etc.=A0=0A> Trivially=0A> disproved= , convert the test to pgbench -f and post results=0A> 2. The test is in fac= t i/o bound. Scaling is going to be=0A> hardware/kernel determined.=A0 Can = we see=0A> iostat/vmstat/top snipped=0A> during test run?=A0 Maybe no-op is= burning you?=0A=0AThis is during my 80 clients test, this is a point at wh= ich the performance is well below that of the same machine limited to 8 cor= es.=0A=0Ahttp://www.privatepaste.com/dc131ff26e=0A=0A> 3. Locking/concurren= cy issue in heavy_seat_function()=0A> (source for=0A> that?)=A0 how much wr= iting does it do?=0A> =0A=0ANo writing afaik - its a select with a few join= s and subqueries - I'm pretty sure it's not writing out temp data either, b= ut all clients are after the same data in the test - maybe theres some lock= s there?=0A=0A> Can we see some iobound and cpubound pgbench runs on both= =0A> servers?=0A> =0A=0AOf course, I'll post when I've gotten to that.=0A