Re: Postmaster hogs CPU

From: Gaetano Mendola <mendola(at)bigfoot(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Chris Gamache <cgg007(at)yahoo(dot)com>, pgsql-admin(at)postgresql(dot)org
Subject: Re: Postmaster hogs CPU
Date: 2004-05-06 01:57:36
Message-ID: 40999B90.5080004@bigfoot.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Tom Lane wrote:

| Gaetano Mendola <mendola(at)bigfoot(dot)com> writes:
|
|>You can basically renice the process that is performing the query.
|
|
| However, that's unlikely to do anything very pleasant, since you'll have
| priority-inversion problems. "nice" has no idea when the process is
| holding a lock that someone else wants ...

That can be true, however in order to have a priority-inversion problem
I think are necessary 3 different level of priority, you have carefully
choose the postmaster and good value of nice in order to have it happen.

I was wandering about do the same work done with vacuum ( the sleep
trick each n records) in order to slow some expensive but not crucial
queries:

test> set query_delay = 10; <-- 10 ms
test> select * from <very expensive query >;

Regards
Gaetano Mendola

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFAmZuP7UpzwH2SGd4RAvVxAKCfvQDk2CkdcC2dCFtgg7nLzf7qTwCgt8/w
F0zVE0HYoI9lb9l7u9qwZIo=
=/mFq
-----END PGP SIGNATURE-----

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Ludek Finstrle 2004-05-06 07:52:03 Re: initdb: FATAL: conversion between LATIN2 and UNICODE
Previous Message Tom Lane 2004-05-06 01:42:34 Re: Postmaster hogs CPU