X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id D4A27DB927 for ; Wed, 16 Nov 2005 13:49:46 -0400 (AST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 39244-10 for ; Wed, 16 Nov 2005 17:49:45 +0000 (GMT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from mail.mi8.com (d01gw04.mi8.com [63.240.6.44]) by svr1.postgresql.org (Postfix) with ESMTP id E3C56DB92D for ; Wed, 16 Nov 2005 13:49:43 -0400 (AST) Received: from 172.16.1.112 by mail.mi8.com with ESMTP (- Welcome to Mi8 Corporation www.Mi8.com (D4)); Wed, 16 Nov 2005 12:49:41 -0500 X-Server-Uuid: C8FB4D43-1108-484A-A898-3CBCC7906230 Received: from MI8NYCMAIL06.Mi8.com ([172.16.1.175]) by D01SMTP02.Mi8.com with Microsoft SMTPSVC(6.0.3790.211); Wed, 16 Nov 2005 12:49:31 -0500 Received: from 67.103.45.218 ([67.103.45.218]) by MI8NYCMAIL06.Mi8.com ( [172.16.1.219]) via Exchange Front-End Server mi8owa.mi8.com ( [172.16.1.105]) with Microsoft Exchange Server HTTP-DAV ; Wed, 16 Nov 2005 12:49:30 -0500 User-Agent: Microsoft-Entourage/11.2.1.051004 Date: Wed, 16 Nov 2005 09:49:28 -0800 Subject: Re: Hardware/OS recommendations for large databases ( From: "Luke Lonergan" To: "Scott Marlowe" , "William Yu" cc: pgsql-performance@postgresql.org Message-ID: Thread-Topic: [PERFORM] Hardware/OS recommendations for large databases ( Thread-Index: AcXq0SzleDDBZmahTU6pSm6FUY2s3wABKFlIAAASLus= In-Reply-To: MIME-Version: 1.0 X-OriginalArrivalTime: 16 Nov 2005 17:49:31.0061 (UTC) FILETIME=[18D79650:01C5EAD6] X-WSS-ID: 6F65AEBF31S12457262-01-01 Content-Type: multipart/alternative; boundary=B_3214979369_23551637 X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=1.254 required=5 tests=[HTML_MESSAGE=0.001, RCVD_NUMERIC_HELO=1.253] X-Spam-Score: 1.254 X-Spam-Level: * X-Archive-Number: 200511/288 X-Sequence-Number: 15545 > This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. --B_3214979369_23551637 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Oops, Last point should be worded: =B3All CPUs on all machines used by a parallel database=B2 - Luke=20 On 11/16/05 9:47 AM, "Luke Lonergan" wrote: > Scott, >=20 > On 11/16/05 9:09 AM, "Scott Marlowe" wrote: >=20 >> The biggest gain is going from 1 to 2 CPUs (real cpus, like the DC >> Opterons or genuine dual CPU mobo, not "hyperthreaded"). Part of the >> issue isn't just raw CPU processing power. The second CPU allows the >> machine to be more responsive because it doesn't have to context switch >> as much. >>=20 >> While I've seen plenty of single CPU servers start to bog under load >> running one big query, the dual CPU machines always seem more than just >> twice as snappy under similar loads. >>=20 > I agree, 2 CPUs are better than one in most cases. >=20 > The discussion was kicked off by the suggestion to get 8 dual core CPUs t= o > process a large database with postgres. Say your decision support query = takes > 15 minutes to run with one CPU. Add another and it still takes 15 minute= s. > Add 15 and the same ... >=20 > OLTP is so different from Business intelligence and Decision Support that= very > little of this thread=B9s discussion is relevant IMO. >=20 > The job is to design a system that can process sequential scan as fast as > possible and uses all resources (CPUs, mem, disk channels) on each query. > Sequential scan is 100x more important than random seeks. >=20 > Here are the facts so far: > * Postgres can only use 1 CPU on each query > * Postgres I/O for sequential scan is CPU limited to 110-120 MB/s on the > fastest modern CPUs > * Postgres disk-based sort speed is 1/10 or more slower than commercial > databases and memory doesn=B9t improve it (much) >=20 > These are the conclusions that follow about decision support / BI system > architecture for normal Postgres: > * I/O hardware with more than 110MB/s of read bandwidth is not useful > * More than 1 CPU is not useful > * More RAM than a nominal amount for small table caching is not useful >=20 > In other words, big SMP doesn=B9t address the problem at all. By contrast, > having all CPUs on multiple machines, or even on a big SMP with lots of I= /O > channels, solves all of the above issues. >=20 > Regards, >=20 - Luke=20 --B_3214979369_23551637 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Re: [PERFORM] Hardware/OS recommendations for large databases (</TIT= LE> </HEAD> <BODY> <FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'font-size:14.0px'>Oops,= <BR> <BR> Last point should be worded: “All CPUs on all machines used by a para= llel database”<BR> <BR> - Luke <BR> <BR> <BR> On 11/16/05 9:47 AM, "Luke Lonergan" <llonergan@greenplum.com&= gt; wrote:<BR> <BR> </SPAN></FONT><BLOCKQUOTE><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYL= E=3D'font-size:14.0px'>Scott,<BR> <BR> On 11/16/05 9:09 AM, "Scott Marlowe" <smarlowe@g2switchworks.c= om> wrote:<BR> <BR> </SPAN></FONT><BLOCKQUOTE><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYL= E=3D'font-size:14.0px'>The biggest gain is going from 1 to 2 CPUs (real cpus, = like the DC<BR> Opterons or genuine dual CPU mobo, not "hyperthreaded").  Pa= rt of the<BR> issue isn't just raw CPU processing power.  The second CPU allows the<= BR> machine to be more responsive because it doesn't have to context switch<BR> as much.<BR> <BR> While I've seen plenty of single CPU servers start to bog under load<BR> running one big query, the dual CPU machines always seem more than just<BR> twice as snappy under similar loads.<BR> <BR> </SPAN></FONT></BLOCKQUOTE><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STY= LE=3D'font-size:14.0px'>I agree, 2 CPUs are better than one in most cases.<BR> <BR> The discussion was kicked off by the suggestion to get 8 dual core CPUs to = process a large database with postgres.  Say your decision support quer= y takes 15 minutes to run with one CPU.  Add another and it still takes= 15 minutes.  Add 15 and the same ...<BR> <BR> OLTP is <B>so</B> different from Business intelligence and Decision Support= that very little of this thread’s discussion is relevant IMO.<BR> <BR> The job is to design a system that can process sequential scan as fast as p= ossible and uses all resources (CPUs, mem, disk channels) on each query. &nb= sp;Sequential scan is 100x more important than random seeks.<BR> <BR> Here are the facts so far:<BR> </SPAN></FONT><UL><LI><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'f= ont-size:14.0px'>Postgres can only use 1 CPU on each query=20 </SPAN></FONT><LI><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'font-= size:14.0px'>Postgres I/O for sequential scan is CPU limited to 110-120 MB/s= on the fastest modern CPUs=20 </SPAN></FONT><LI><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'font-= size:14.0px'>Postgres disk-based sort speed is 1/10 or more slower than comm= ercial databases and memory doesn’t improve it (much)<BR> </SPAN></FONT></UL><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'font= -size:14.0px'><BR> These are the conclusions that follow about decision support / BI system ar= chitecture for normal Postgres:<BR> </SPAN></FONT><UL><LI><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'f= ont-size:14.0px'>I/O hardware with more than 110MB/s of read bandwidth is no= t useful=20 </SPAN></FONT><LI><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'font-= size:14.0px'>More than 1 CPU is not useful=20 </SPAN></FONT><LI><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'font-= size:14.0px'>More RAM than a nominal amount for small table caching is not u= seful<BR> </SPAN></FONT></UL><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STYLE=3D'font= -size:14.0px'><BR> In other words, big SMP doesn’t address the problem at all.  By = contrast, having all CPUs on multiple machines, or even on a big SMP with lo= ts of I/O channels, solves all of the above issues.<BR> <BR> Regards,<BR> <BR> </SPAN></FONT></BLOCKQUOTE><FONT FACE=3D"Verdana, Helvetica, Arial"><SPAN STY= LE=3D'font-size:14.0px'>- Luke <BR> </SPAN></FONT> </BODY> </HTML> --B_3214979369_23551637--