ok
Direktori : /opt/alt/postgresql11/usr/share/doc/alt-postgresql11-9.2.24/html/ |
Current File : //opt/alt/postgresql11/usr/share/doc/alt-postgresql11-9.2.24/html/runtime-config-statistics.html |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <HTML ><HEAD ><TITLE >Run-time Statistics</TITLE ><META NAME="GENERATOR" CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK REV="MADE" HREF="mailto:pgsql-docs@postgresql.org"><LINK REL="HOME" TITLE="PostgreSQL 9.2.24 Documentation" HREF="index.html"><LINK REL="UP" TITLE="Server Configuration" HREF="runtime-config.html"><LINK REL="PREVIOUS" TITLE="Error Reporting and Logging" HREF="runtime-config-logging.html"><LINK REL="NEXT" TITLE="Automatic Vacuuming" HREF="runtime-config-autovacuum.html"><LINK REL="STYLESHEET" TYPE="text/css" HREF="stylesheet.css"><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1"><META NAME="creation" CONTENT="2017-11-06T22:43:11"></HEAD ><BODY CLASS="SECT1" ><DIV CLASS="NAVHEADER" ><TABLE SUMMARY="Header navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TH COLSPAN="5" ALIGN="center" VALIGN="bottom" ><A HREF="index.html" >PostgreSQL 9.2.24 Documentation</A ></TH ></TR ><TR ><TD WIDTH="10%" ALIGN="left" VALIGN="top" ><A TITLE="Error Reporting and Logging" HREF="runtime-config-logging.html" ACCESSKEY="P" >Prev</A ></TD ><TD WIDTH="10%" ALIGN="left" VALIGN="top" ><A HREF="runtime-config.html" ACCESSKEY="U" >Up</A ></TD ><TD WIDTH="60%" ALIGN="center" VALIGN="bottom" >Chapter 18. Server Configuration</TD ><TD WIDTH="20%" ALIGN="right" VALIGN="top" ><A TITLE="Automatic Vacuuming" HREF="runtime-config-autovacuum.html" ACCESSKEY="N" >Next</A ></TD ></TR ></TABLE ><HR ALIGN="LEFT" WIDTH="100%"></DIV ><DIV CLASS="SECT1" ><H1 CLASS="SECT1" ><A NAME="RUNTIME-CONFIG-STATISTICS" >18.9. Run-time Statistics</A ></H1 ><DIV CLASS="SECT2" ><H2 CLASS="SECT2" ><A NAME="RUNTIME-CONFIG-STATISTICS-COLLECTOR" >18.9.1. Query and Index Statistics Collector</A ></H2 ><P > These parameters control server-wide statistics collection features. When statistics collection is enabled, the data that is produced can be accessed via the <TT CLASS="STRUCTNAME" >pg_stat</TT > and <TT CLASS="STRUCTNAME" >pg_statio</TT > family of system views. Refer to <A HREF="monitoring.html" >Chapter 27</A > for more information. </P ><P ></P ><DIV CLASS="VARIABLELIST" ><DL ><DT ><A NAME="GUC-TRACK-ACTIVITIES" ></A ><TT CLASS="VARNAME" >track_activities</TT > (<TT CLASS="TYPE" >boolean</TT >)</DT ><DD ><P > Enables the collection of information on the currently executing command of each session, along with the time when that command began execution. This parameter is on by default. Note that even when enabled, this information is not visible to all users, only to superusers and the user owning the session being reported on, so it should not represent a security risk. Only superusers can change this setting. </P ></DD ><DT ><A NAME="GUC-TRACK-ACTIVITY-QUERY-SIZE" ></A ><TT CLASS="VARNAME" >track_activity_query_size</TT > (<TT CLASS="TYPE" >integer</TT >)</DT ><DD ><P > Specifies the number of bytes reserved to track the currently executing command for each active session, for the <TT CLASS="STRUCTNAME" >pg_stat_activity</TT >.<TT CLASS="STRUCTFIELD" >query</TT > field. The default value is 1024. This parameter can only be set at server start. </P ></DD ><DT ><A NAME="GUC-TRACK-COUNTS" ></A ><TT CLASS="VARNAME" >track_counts</TT > (<TT CLASS="TYPE" >boolean</TT >)</DT ><DD ><P > Enables collection of statistics on database activity. This parameter is on by default, because the autovacuum daemon needs the collected information. Only superusers can change this setting. </P ></DD ><DT ><A NAME="GUC-TRACK-IO-TIMING" ></A ><TT CLASS="VARNAME" >track_io_timing</TT > (<TT CLASS="TYPE" >boolean</TT >)</DT ><DD ><P > Enables timing of database I/O calls. This parameter is off by default, because it will repeatedly query the operating system for the current time, which may cause significant overhead on some platforms. You can use the <A HREF="pgtesttiming.html" ><SPAN CLASS="APPLICATION" >pg_test_timing</SPAN ></A > tool to measure the overhead of timing on your system. I/O timing information is displayed in <A HREF="monitoring-stats.html#PG-STAT-DATABASE-VIEW" >pg_stat_database</A >, in the output of <A HREF="sql-explain.html" >EXPLAIN</A > when the <TT CLASS="LITERAL" >BUFFERS</TT > option is used, and by <A HREF="pgstatstatements.html" >pg_stat_statements</A >. Only superusers can change this setting. </P ></DD ><DT ><A NAME="GUC-TRACK-FUNCTIONS" ></A ><TT CLASS="VARNAME" >track_functions</TT > (<TT CLASS="TYPE" >enum</TT >)</DT ><DD ><P > Enables tracking of function call counts and time used. Specify <TT CLASS="LITERAL" >pl</TT > to track only procedural-language functions, <TT CLASS="LITERAL" >all</TT > to also track SQL and C language functions. The default is <TT CLASS="LITERAL" >none</TT >, which disables function statistics tracking. Only superusers can change this setting. </P ><DIV CLASS="NOTE" ><BLOCKQUOTE CLASS="NOTE" ><P ><B >Note: </B > SQL-language functions that are simple enough to be <SPAN CLASS="QUOTE" >"inlined"</SPAN > into the calling query will not be tracked, regardless of this setting. </P ></BLOCKQUOTE ></DIV ></DD ><DT ><A NAME="GUC-UPDATE-PROCESS-TITLE" ></A ><TT CLASS="VARNAME" >update_process_title</TT > (<TT CLASS="TYPE" >boolean</TT >)</DT ><DD ><P > Enables updating of the process title every time a new SQL command is received by the server. The process title is typically viewed by the <TT CLASS="COMMAND" >ps</TT > command, or in Windows by using the <SPAN CLASS="APPLICATION" >Process Explorer</SPAN >. Only superusers can change this setting. </P ></DD ><DT ><A NAME="GUC-STATS-TEMP-DIRECTORY" ></A ><TT CLASS="VARNAME" >stats_temp_directory</TT > (<TT CLASS="TYPE" >string</TT >)</DT ><DD ><P > Sets the directory to store temporary statistics data in. This can be a path relative to the data directory or an absolute path. The default is <TT CLASS="FILENAME" >pg_stat_tmp</TT >. Pointing this at a RAM-based file system will decrease physical I/O requirements and can lead to improved performance. This parameter can only be set in the <TT CLASS="FILENAME" >postgresql.conf</TT > file or on the server command line. </P ></DD ></DL ></DIV ></DIV ><DIV CLASS="SECT2" ><H2 CLASS="SECT2" ><A NAME="RUNTIME-CONFIG-STATISTICS-MONITOR" >18.9.2. Statistics Monitoring</A ></H2 ><P ></P ><DIV CLASS="VARIABLELIST" ><DL ><DT ><TT CLASS="VARNAME" >log_statement_stats</TT > (<TT CLASS="TYPE" >boolean</TT >)<BR><TT CLASS="VARNAME" >log_parser_stats</TT > (<TT CLASS="TYPE" >boolean</TT >)<BR><TT CLASS="VARNAME" >log_planner_stats</TT > (<TT CLASS="TYPE" >boolean</TT >)<BR><TT CLASS="VARNAME" >log_executor_stats</TT > (<TT CLASS="TYPE" >boolean</TT >)</DT ><DD ><P > For each query, output performance statistics of the respective module to the server log. This is a crude profiling instrument, similar to the Unix <CODE CLASS="FUNCTION" >getrusage()</CODE > operating system facility. <TT CLASS="VARNAME" >log_statement_stats</TT > reports total statement statistics, while the others report per-module statistics. <TT CLASS="VARNAME" >log_statement_stats</TT > cannot be enabled together with any of the per-module options. All of these options are disabled by default. Only superusers can change these settings. </P ></DD ></DL ></DIV ></DIV ></DIV ><DIV CLASS="NAVFOOTER" ><HR ALIGN="LEFT" WIDTH="100%"><TABLE SUMMARY="Footer navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" ><A HREF="runtime-config-logging.html" ACCESSKEY="P" >Prev</A ></TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="index.html" ACCESSKEY="H" >Home</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" ><A HREF="runtime-config-autovacuum.html" ACCESSKEY="N" >Next</A ></TD ></TR ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" >Error Reporting and Logging</TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="runtime-config.html" ACCESSKEY="U" >Up</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" >Automatic Vacuuming</TD ></TR ></TABLE ></DIV ></BODY ></HTML >