Skip site navigation (1) Skip section navigation (2)

Re: [Dbdpg-general] [ANNOUNCE] pgtop, display PostgreSQL processes in `top' style

From: David Wheeler <david(at)kineticode(dot)com>
To: Cosimo Streppone <cosimo(at)streppone(dot)it>
Cc: pgsql-sql(at)postgresql(dot)org,Pg list <dbdpg-general(at)gborg(dot)postgresql(dot)org>
Subject: Re: [Dbdpg-general] [ANNOUNCE] pgtop, display PostgreSQL processes in `top' style
Date: 2005-05-02 23:23:29
Message-ID: 066EC6F2-CB44-44E9-AE40-6969D3851F8C@kineticode.com (view raw or flat)
Thread:
Lists: pgsql-announcepgsql-sql
On Apr 30, 2005, at 15:10 , Cosimo Streppone wrote:

> 1) is it possible to know Pg backend uptime with
>    SQL queries? Or must I look at postmaster.pid file?
>    or even something else?

I think that the PID file is your best bet.

> 2) how can I know the ip addresses/hostnames of clients
>    connecting to server?

I believe that that information is in pg_stat_activity. See:

   http://www.postgresql.org/docs/current/static/monitoring.html

> 3) Is there a way to know the number of queries performed
>    against Pg backend (by each client)? Can I distinguish
>    between selects / updates / inserts / copy / ... ?

I think so, but you have to enable some postgresql.conf settings to  
get that information logged.

   http://www.postgresql.org/docs/8.0/static/runtime-config.html

Regards,

David

In response to

pgsql-announce by date

Next:From: Tatsuo IshiiDate: 2005-05-03 03:08:58
Subject: Re: [ANNOUNCE] IMPORTANT: two new PostgreSQL security problems
Previous:From: Markus SchaberDate: 2005-05-02 22:09:56
Subject: Re: [ANNOUNCE] pgtop, display PostgreSQL processes in `top' style

pgsql-sql by date

Next:From: ogjunk-pgjedanDate: 2005-05-03 04:35:31
Subject: Trimming the cost of ORDER BY in a simple query
Previous:From: Markus SchaberDate: 2005-05-02 22:09:56
Subject: Re: [ANNOUNCE] pgtop, display PostgreSQL processes in `top' style

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group