Re: High SYS CPU - need advise

From: Vlad <marchenko(at)gmail(dot)com>
To: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
Cc: Merlin Moncure <mmoncure(at)gmail(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: High SYS CPU - need advise
Date: 2012-11-21 16:34:56
Message-ID: CAKeSUqV4V5RXHz3B-EthcresrxLtQzhAyTPobOcCPdP6k6MEhw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

nothing changes if I increase number of threads.
pgbouncer doesn't change much.

also, I think the nature of high-sys-cpu during stall and and when I run
pgbench is different.
During pgbench it's constantly at 30-40%, while during stall it sits at low
5-15% and then spikes to 90% after a while, with no apparent reason (i.e.:
no increased load or anything), then goes down in a few secs, or stays
until postgres restarted.

at this point the only thing that does help on app side is when I force
frequent re-connection to postgresql (i.e. not letting postmaster live too
long)

-- Vlad

On Wed, Nov 21, 2012 at 10:18 AM, Jeff Janes <jeff(dot)janes(at)gmail(dot)com> wrote:

> On Wed, Nov 21, 2012 at 8:14 AM, Vlad <marchenko(at)gmail(dot)com> wrote:
> >
> >
> > '-M prepared' produces normal results, while '-M simple' results in 40%
> sys
> > cpu. '-M extended' is somewhere in between.
> > I'm running it as 60 clients, 2 threads.
>
> 2 threads is pretty low for 60 clients. What happens if you increase
> -j to either 30 or 60? (What I'm wondering here is if perhaps in this
> case it is pgbench which is triggering the scheduling issue)
>
> Also, what happens if you channel pgbench through pgbouncer?
>
> Cheers,
>
> Jeff
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Jeff Janes 2012-11-21 16:43:55 Re: High SYS CPU - need advise
Previous Message Jeff Janes 2012-11-21 16:18:44 Re: High SYS CPU - need advise