@ -2961,7 +2961,7 @@ SELECT * FROM parent WHERE key = 2400;
value</> (<acronym>CSV</>) format, which is convenient for
value</> (<acronym>CSV</>) format, which is convenient for
loading logs into programs.
loading logs into programs.
See <xref linkend="runtime-config-logging-csvlog"> for details.
See <xref linkend="runtime-config-logging-csvlog"> for details.
<varname>logging_collector</varname > must be enabled to generate
<xref linkend="guc-logging-collector" > must be enabled to generate
CSV-format log output.
CSV-format log output.
</para>
</para>
@ -2993,24 +2993,39 @@ local0.* /var/log/postgresql
</indexterm>
</indexterm>
<listitem>
<listitem>
<para>
<para>
This parameter captures plain and CSV-format log messages
This parameter enables the <firstterm>logging collector</>, which
sent to <application>stderr</> and redirects them into log files.
is a background process that captures log messages
sent to <systemitem>stderr</> and redirects them into log files.
This approach is often more useful than
This approach is often more useful than
logging to <application>syslog</>, since some types of messages
logging to <application>syslog</>, since some types of messages
might not appear in <application>syslog</> output (a common example
might not appear in <application>syslog</> output. (One common
is dynamic-linker failure messages).
example is dynamic-linker failure messages; another is error messages
produced by scripts such as <varname>archive_command</>.)
This parameter can only be set at server start.
This parameter can only be set at server start.
</para>
</para>
<note>
<para>
It is possible to log to <systemitem>stderr</> without using the
logging collector; the log messages will just go to wherever the
server's <systemitem>stderr</> is directed. However, that method is
only suitable for low log volumes, since it provides no convenient
way to rotate log files. Also, on some platforms not using the
logging collector can result in lost or garbled log output, because
multiple processes writing concurrently to the same log file can
overwrite each other's output.
</para>
</note>
<note>
<note>
<para>
<para>
The logging collector is designed to never lose messages. This means
The logging collector is designed to never lose messages. This means
that in case of extremely high load, server processes could be
that in case of extremely high load, server processes could be
blocked due to trying to send additional log messages when the
blocked while trying to send additional log messages when the
collector has fallen behind. In contrast, <application>syslog</>
collector has fallen behind. In contrast, <application>syslog</>
prefers to drop messages if it cannot write them, which means it's
prefers to drop messages if it cannot write them, which means it
less reliable in those cases but it will not block the rest of the
may fail to log some messages in such cases but it will not block
system.
the rest of the system.
</para>
</para>
</note>
</note>