Re: Help with process list - Mailing list pgsql-general

From Pavel Stehule
Subject Re: Help with process list
Date
Msg-id Pine.LNX.4.44.0504142204450.19405-100000@kix.fsv.cvut.cz
Whole thread Raw
In response to Help with process list  (Cristian Prieto <cristian@clickdiario.com>)
List pgsql-general
On Thu, 14 Apr 2005, Cristian Prieto wrote:

> Hello, I have a couple of bussy pgsql 8 servers running in my office, in
> MySQL I use SHOW PROCESSLIST to show the actual process running in the
> MySQL server (idle time, resources and other statistical data) and a
> little perl app named mytop to show the data like the top unix
> utility... There such way to do the same or similar stuff in PostgreSQL?
>
> Thanks a lot...
>

Hello,

you can use

intra=# SELECT * from pg_stat_activity ;
 datid | datname | procpid | usesysid | usename | current_query |
query_start
-------+---------+---------+----------+---------+---------------+-------------------------------
 17234 | intra   |   10782 |      100 | root    | <IDLE>        |
2005-04-14 22:02:12.952476+02
 17234 | intra   |   16274 |      100 | root    | <IDLE>        |
2005-04-14 22:03:10.109273+02
 17234 | intra   |   19010 |      100 | root    | <IDLE>        |
2005-04-14 22:02:13.216437+02
 17234 | intra   |    9403 |      100 | root    | <IDLE>        |
2005-04-14 22:04:14.739074+02
 17234 | intra   |    8605 |      100 | root    | <IDLE>        |
2005-04-14 22:04:28.406897+02
 17234 | intra   |    1426 |      100 | root    | <IDLE>        |
2005-04-14 22:03:08.89732+02
 17234 | intra   |    5497 |      100 | root    | <IDLE>        |
2005-04-14 22:04:14.506181+02
(7 rows)


Regards
Pavel Stehule


pgsql-general by date:

Previous
From: "Ets ROLLAND"
Date:
Subject: Re: About ERROR: could not convert UTF-8 character 0x00e9
Next
From: Ying Lu
Date:
Subject: use SAVEPOINT function