From: | Andrew Sullivan <andrew(at)libertyrms(dot)info> |
---|---|
To: | pgsql-admin(at)postgresql(dot)org |
Subject: | Re: database running slow |
Date: | 2003-05-14 17:46:06 |
Message-ID: | 20030514174606.GR20729@libertyrms.info |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
On Tue, May 13, 2003 at 10:19:55AM -0700, Shankar K wrote:
>
> Define "run-away". You can look for long-running
> transactions; that might be helpful.
>
> ++ i meant a backend process taking most of the cpu
> cycles and running for ever. so i wanted to figure out
> what those processes were doing and what made them to
> hog the cpu cycles.
You can use the pid of a process to look it up in the system tables.
There's no simple way to identify long-running ones, except to look
for back ends that have been hanging around for a long time (but if
you're using pooling, it won't help you). Tools like top will be
helpful in identifying processor hogs.
> ++ how to identify those queries. once i have the
If you can identify the process, then you can identify the pid, and
use the pid in the stats tables to get the query.
A
--
----
Andrew Sullivan 204-4141 Yonge Street
Liberty RMS Toronto, Ontario Canada
<andrew(at)libertyrms(dot)info> M2P 2A8
+1 416 646 3304 x110
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Sullivan | 2003-05-14 17:48:59 | Re: No flamefest please, MySQL vs. PostgreSQL AGAIN |
Previous Message | Ericson Smith | 2003-05-14 17:43:33 | Trying to profile my function, but... |