log_executor_stats
A configuration parameter determining whether to log executor statistics for a statement
log_executor_stats
is a configuration parameter determining whether to log detailed executor statistics for a statement.
log_executor_stats
was added in PostgreSQL 7.4.
Usage
If log_executor_stats
is set to "on", a DETAIL
line will be emitted containing details about the statement execution, including execution time and memory / i/o usage.
log_executor_stats
cannot be enabled at the same time as log_statement_stats
.
Default value
The default value for log_executor_stats
is: off
.
Change history
- PostgreSQL 11
- memory usage displayed in output (commit c039ba07)
- PostgreSQL 7.4
- added (commit d36aa2e8)
Examples
Log output from issuing a simple statement ("SELECT 1
"):
[2021-03-29 17:54:55 UTC] psql postgres postgres STATEMENT: SELECT 1; [2021-03-29 17:54:55 UTC] psql postgres postgres LOG: 00000: EXECUTOR STATISTICS [2021-03-29 17:54:55 UTC] psql postgres postgres DETAIL: ! system usage stats: ! 0.000007 s user, 0.000000 s system, 0.000007 s elapsed ! [0.000618 s user, 0.002449 s system total] ! 14368 kB max resident size ! 0/0 [0/0] filesystem blocks in/out ! 0/0 [0/494] page faults/reclaims, 0 [0] swaps ! 0 [0] signals rcvd, 0/0 [0/0] messages rcvd/sent ! 0/0 [7/0] voluntary/involuntary context switches
References
- PostgreSQL documentation: Statistics Monitoring