pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: David Wheeler <david@kineticode.com>
To: Cosimo Streppone <cosimo@streppone.it>
Cc: pgsql-sql@postgresql.org, Pg list <dbdpg-general@gborg.postgresql.org>
Subject: Re: [Dbdpg-general] [ANNOUNCE] pgtop, display PostgreSQL processes in `top' style
Date: Mon, 2 May 2005 16:23:29 -0700
Message-ID: <066EC6F2-CB44-44E9-AE40-6969D3851F8C@kineticode.com> (raw)
In-Reply-To: <42740256.4090200@streppone.it>
References: <42740256.4090200@streppone.it>

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



view thread (6+ messages)  latest in thread

Message-ID: <066EC6F2-CB44-44E9-AE40-6969D3851F8C@kineticode.com>
Permalink:  ../066EC6F2-CB44-44E9-AE40-6969D3851F8C@kineticode.com/
Also on:    postgresql.org/message-id/066EC6F2-CB44-44E9-AE40-6969D3851F8C@kineticode.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: david@kineticode.com, cosimo@streppone.it, dbdpg-general@gborg.postgresql.org
  Subject: Re: [Dbdpg-general] [ANNOUNCE] pgtop, display PostgreSQL processes in `top' style
  In-Reply-To: <066EC6F2-CB44-44E9-AE40-6969D3851F8C@kineticode.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox