Skip site navigation (1) Skip section navigation (2)

Re: cpu bound postgresql setup. Firstly many thanks for responding. I am concerned because the load averages have increased and users complaining of slowness. I do not change settings frequenly. I was curious if there is any half dead component in th

From: Rajesh Kumar Mallah <mallah(dot)rajesh(at)gmail(dot)com>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, postgres performance list <pgsql-performance(at)postgresql(dot)org>
Subject: Re: cpu bound postgresql setup. Firstly many thanks for responding. I am concerned because the load averages have increased and users complaining of slowness. I do not change settings frequenly. I was curious if there is any half dead component in th
Date: 2010-06-23 17:30:01
Message-ID: AANLkTimYZkyh7njK9QzJnaPJwXIiRrSOgedChwRTHdKL@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-performance
On 6/23/10, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov> wrote:
> Rajesh Kumar Mallah <mallah(dot)rajesh(at)gmail(dot)com> wrote:
>> PasteBin for the vmstat output
>> http://pastebin.com/mpHCW9gt
>>
>> On Wed, Jun 23, 2010 at 8:22 PM, Rajesh Kumar Mallah
>> <mallah(dot)rajesh(at)gmail(dot)com> wrote:
>>> Dear List ,
>>>
>>> I observe that my postgresql (ver 8.4.2) dedicated server has
>>> turned cpu bound and there is a high load average in the server >
>>> 50 usually.
>>> The server has 2 Quad Core CPUs already and there are 6 or 8
>>> drives in raid 10 , there is negligable i/o wait. There is 32GB
>>> ram and no swapping.
>>>
>>> When i strace processes at random i see lot of lseek
>>> (XXX,0,SEEK_END) calls which i feel were not that frequent
>>> before. can any pointers be got for investigating the high cpu
>>> usage by postgresql processes.
>
> I'm not clear on what problem you are experiencing.  Using a lot of
> your hardware's capacity isn't a problem in itself -- are you
> getting poor response time?  Poor throughput?  Some other problem?
> Is it continuous, or only when certain queries run?
>
> One thing that is apparent is that you might want to use a
> connection pool, or if you're already using one you might want to
> configure it to reduce the maximum number of active queries.  With
> eight cores and eight drives, your best throughput is going to be at
> somewhere around 24 active connections, and you appear to be going
> to at least twice that.
>
> If you can provide a copy of your postgresql.conf settings (without
> comments) and an EXPLAIN ANALYZE of a slow query, along with the
> schema information for the tables used by the query, you'll probably
> get useful advice on how to adjust your configuration, indexing, or
> query code to improve performance.
>
> -Kevin
>

-- 
Sent from Gmail for mobile | mobile.google.com

Responses

pgsql-performance by date

Next:From: Kevin GrittnerDate: 2010-06-23 17:43:15
Subject: Re: cpu bound postgresql setup.
Previous:From: Kevin GrittnerDate: 2010-06-23 17:08:08
Subject: Re: slow index lookup

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group