Re: Controlling CPU Usage in PostgreSQL

From: "Aaron Bono" <postgresql(at)aranya(dot)com>
To: "Chris Mair" <list(at)1006(dot)org>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Controlling CPU Usage in PostgreSQL
Date: 2006-08-02 17:43:01
Message-ID: bf05e51c0608021043n4bf13f4ch3214ad224937eb31@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On 8/1/06, Chris Mair <list(at)1006(dot)org> wrote:
>
> On Tue, 2006-08-01 at 14:22 -0500, Scott Marlowe wrote:
> > On Tue, 2006-08-01 at 13:59, Aaron Bono wrote:
> > > Is there a way to tell PostgreSQL to change the nice value of a
> > > particular connection? I guess I could use renice but that means a
> > > lot of shell scripting to determine what PID to change - I am not a
> > > shell script expert and would rather not pursue that option.
> >
> > This is one of those things that only seems like a good idea at the
> > time.
> >
> > While nice-ing the whole of a postgresql server is doable, nice-ing
> > individual connections is no advisable.
> >
> > You can reach a bad state caused by "priority inversion". Search the
> > lists (not just admin) for that phrase and you should find out what I
> > mean. This should probably be a FAQ, as it shows up every few months.
>
> I started going down that same road in May... here's the thread from
> then explaining why it's a bad idea after all:
> http://archives.postgresql.org/pgsql-performance/2006-05/msg00462.php

I didn't really have my heart set on doing this, just was wondering if I
could and how.

This has been a good eye opener though. It will definitely have an impact
on my future design of both the database and multi-threaded applications.

Thanks guys!

==================================================================
Aaron Bono
Aranya Software Technologies, Inc.
http://www.aranya.com
==================================================================

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message adey 2006-08-02 23:23:11 Re: What's using all my RAM?
Previous Message Scott Marlowe 2006-08-02 16:34:59 Re: What's using all my RAM?