Connections to the Database

Поиск
Список
Период
Сортировка
Искать

Connections to the Database

От:
Reinhard Asmus <reinhard.asmus@spdfraktion.de>
Дата:
I install a new database and want to check which connections will be used.

How can i see which application from which host is connecting the database?

Any help is appreciated.

Re: Connections to the Database

От:
Adarsh Sharma <adarsh.sharma@orkash.com>
Дата:
Issue the below command :-

select * from pg_stat_activity


& check the results.



Reinhard Asmus wrote:
> I install a new database and want to check which connections will be 
> used.
>
> How can i see which application from which host is connecting the 
> database?
>
> Any help is appreciated.
>
>

Re: Connections to the Database

От:
lst_hoe02@kwsoft.de
Дата:
Вложения:
Zitat von Reinhard Asmus :

> I install a new database and want to check which connections will be used.
>
> How can i see which application from which host is connecting the database?
>
> Any help is appreciated.

Hello

if you only want to check from time to time use something like PGAdmin  
(http://www.pgadmin.org/). The connections are shown in the statistics  
pane for the database in question.

Regards

Andreas


Re: Connections to the Database

От:
Reinhard Asmus <reinhard.asmus@spdfraktion.de>
Дата:
select * from pg_stat_activity show me informations to working connections

but i will see informations (application and ip-address) to failed 
connections

in this situation i can see problems in my pg_log but not the 
information to application and ip-address

Re: Connections to the Database

От:
Raghavendra <raghavendra.rao@enterprisedb.com>
Дата:

On Fri, Feb 17, 2012 at 2:18 PM, Reinhard Asmus <reinhard.asmus@spdfraktion.de> wrote:
select * from pg_stat_activity show me informations to working connections

but i will see informations (application and ip-address) to failed connections

in this situation i can see problems in my pg_log but not the information to application and ip-address


 
pg_stat_activity is standard statistic view which is dynamically updated.

Very true, failed connection's information can be pull from pg_logs. However, you need to tune your logging setting to write information about connections. See log_connections & log_disconnections

---
Regards,
Raghavendra
EnterpriseDB Corporation



 

--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

FAQ