Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
doc: Add note about I/O timing information in EXPLAIN and pg_stat_database.
authorFujii Masao <fujii@postgresql.org>
Fri, 22 May 2020 14:33:58 +0000 (23:33 +0900)
committerFujii Masao <fujii@postgresql.org>
Fri, 22 May 2020 14:33:58 +0000 (23:33 +0900)
Explain that the followings are tracked only when track_io_timing GUC
is enabled.

- blk_read_time and blk_write_time in pg_stat_database
- time spent reading and writing data file blocks in EXPLAIN output
   with BUFFERS option

Whther track_io_timing is enabled affects also blk_read_time and
blk_write_time in pg_stat_statements, but which was already documented.

Author: Atsushi Torikoshi
Reviewed-by: Fujii Masao
Discussion: https://postgr.es/m/CACZ0uYHo_NwbxpLH76OGF-O=13tkR0ZM0zeyGEhZ+JEXZVRyCA@mail.gmail.com

doc/src/sgml/monitoring.sgml
doc/src/sgml/ref/explain.sgml

index acc6e2bc3160254e027e23921af944e29b4a690f..49d4bb13b9e26b2aa1e4fa135d23a72253eff4e7 100644 (file)
@@ -3390,7 +3390,8 @@ SELECT pid, wait_event_type, wait_event FROM pg_stat_activity WHERE wait_event i
       </para>
       <para>
        Time spent reading data file blocks by backends in this database,
-       in milliseconds
+       in milliseconds (if <xref linkend="guc-track-io-timing"/> is enabled,
+       otherwise zero)
       </para></entry>
      </row>
 
@@ -3400,7 +3401,8 @@ SELECT pid, wait_event_type, wait_event FROM pg_stat_activity WHERE wait_event i
       </para>
       <para>
        Time spent writing data file blocks by backends in this database,
-       in milliseconds
+       in milliseconds (if <xref linkend="guc-track-io-timing"/> is enabled,
+       otherwise zero)
       </para></entry>
      </row>
 
index 7ddb5a05c65dcb4a4c76e2f94af864046e4784ab..1c19e254dc240b497df39bcf42d2e7b8ff6f8d37 100644 (file)
@@ -171,8 +171,9 @@ ROLLBACK;
      <para>
       Include information on buffer usage. Specifically, include the number of
       shared blocks hit, read, dirtied, and written, the number of local blocks
-      hit, read, dirtied, and written, and the number of temp blocks read and
-      written.
+      hit, read, dirtied, and written, the number of temp blocks read and
+      written, and the time spent reading and writing data file blocks
+      (in milliseconds) if <xref linkend="guc-track-io-timing"/> is enabled.
       A <emphasis>hit</emphasis> means that a read was avoided because the block was
       found already in cache when needed.
       Shared blocks contain data from regular tables and indexes;