I changed PostgreSQL cluster configuration to log ALL statements and its duration, and it work correct, but periodically I see records like this:
2020-12-08 09:31:42.175 +05 [19041:app_name] LOG: 00000: duration: 0.046 ms
2020-12-08 09:31:42.175 +05 [19041:app_name] LOCATION: exec_execute_message, postgres.c:2086
What could it be? log_line_prefix = '%m [%p:%a] '
Also, it's standby node and replicates primary.
You are seeing output from log_duration
. That just emits the duration without the statement and is somewhat useless.
Set log_duration = off
, log_statement = 'none'
and log_min_duration_statement = 0
, and you will get all statements logged along with their duration, which is usually the most useful setting.