Received: from localhost.localdomain (postgresql.org [64.49.215.8]) by localhost (Postfix) with ESMTP id AABBF475973; Fri, 10 May 2002 16:52:45 -0400 (EDT) Received: from davinci.ethosmedia.com (davinci.ethosmedia.com [209.10.40.250]) by postgresql.org (Postfix) with ESMTP id 4D51F47595F; Fri, 10 May 2002 16:52:39 -0400 (EDT) Received: from [209.122.114.82] (account ) by davinci.ethosmedia.com (CommuniGate Pro WebUser 3.5.9) with HTTP id 1456567; Fri, 10 May 2002 13:52:40 -0700 From: "Josh Berkus" Subject: Re: [SQL] Why very high CPU usage To: "Samuel J. Sutjiono" , , X-Mailer: CommuniGate Pro Web Mailer v.3.5.9 Date: Fri, 10 May 2002 13:52:40 -0700 Message-ID: In-Reply-To: <395901c1f85a$38cf2850$110a010a@headquarters.wcgroup.com> MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit X-Archive-Number: 200205/390 X-Sequence-Number: 24370 Samuel, > I ran a search query against two tables keywords and catalog. > Keywords table has about 765,000 records and catalog hase about > 147,000 records. The query returns 9,000 records. This query had 70 - > 80% of CPU usage. Are there any configuration parameter(s) that I > need to check and change ? And this is a problem because .... ? High CPU usage is a *good* thing. Under perfect tuning, Postgres would hit about 97% CPU usage ... for about 0.1 seconds (or less, depending on your processor). The more CPU power used, the faster the query is solved. If you're having performaince problems, I suspect that they are located somewhere other than your CPU. -Josh Berkus