Re: database running slow

Поиск
Список
Период
Сортировка
От Andrew Sullivan
Тема Re: database running slow
Дата
Msg-id 20030514174606.GR20729@libertyrms.info
обсуждение исходный текст
Ответ на Re: database running slow  (Shankar K <shan0075@yahoo.com>)
Список 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@libertyrms.info>                              M2P 2A8
                                         +1 416 646 3304 x110


В списке pgsql-admin по дате отправления:

Предыдущее
От: Bruno Wolff III
Дата:
Сообщение: Re: Grant Question
Следующее
От: Andrew Sullivan
Дата:
Сообщение: Re: No flamefest please, MySQL vs. PostgreSQL AGAIN