Re: Database connection log - Mailing list pgsql-general

From Christoph Moench-Tegeder
Subject Re: Database connection log
Date
Msg-id 20180614145157.GA99890@elch.exwg.net
Whole thread Raw
In response to Database connection log  (Tiffany Thang <tiffanythang@gmail.com>)
List pgsql-general
## Tiffany Thang (tiffanythang@gmail.com):

> Does PostgreSQL keep a log of client connections to the database like
> Oracle's listener.log? I would like to extract information such as how many
> connections are made to the database daily, the IP addresses they
> originated from and the schemas they are connected to. Would it be possible
> to extract the above information in PostgreSQL?

Set "log_connections" to "on":
https://www.postgresql.org/docs/10/static/runtime-config-logging.html#RUNTIME-CONFIG-LOGGING-WHAT

Regards,
Christoph

-- 
Spare Space


pgsql-general by date:

Previous
From: Tiffany Thang
Date:
Subject: Database connection log
Next
From: Pierre Timmermans
Date:
Subject: Re: Database connection log