log_disconnections

A configuration parameter determining whether to log disconnections.

log_disconnections is a configuration parameter determining whether to log database disconnections.

log_disconnections was added in PostgreSQL 8.0.

Default value

The default value for log_disconnections is: off.

Change history

Examples

Sample log output for a disconnection when log_disconnections is on:

[2021-11-14 08:10:03 UTC] psql postgres postgres LOG:  00000: disconnection: session time: 0:15:01.081 user=postgres database=postgres host=127.0.0.1 port=54310

Categories

GUC configuration item, Logging

See also

log_connections