|
| 1 | +<!-- |
| 2 | +doc/src/sgml/ref/pg_walsummary.sgml |
| 3 | +PostgreSQL documentation |
| 4 | +--> |
| 5 | + |
| 6 | +<refentry id="app-pgwalsummary"> |
| 7 | + <indexterm zone="app-pgwalsummary"> |
| 8 | + <primary>pg_walsummary</primary> |
| 9 | + </indexterm> |
| 10 | + |
| 11 | + <refmeta> |
| 12 | + <refentrytitle><application>pg_walsummary</application></refentrytitle> |
| 13 | + <manvolnum>1</manvolnum> |
| 14 | + <refmiscinfo>Application</refmiscinfo> |
| 15 | + </refmeta> |
| 16 | + |
| 17 | + <refnamediv> |
| 18 | + <refname>pg_walsummary</refname> |
| 19 | + <refpurpose>print contents of WAL summary files</refpurpose> |
| 20 | + </refnamediv> |
| 21 | + |
| 22 | + <refsynopsisdiv> |
| 23 | + <cmdsynopsis> |
| 24 | + <command>pg_walsummary</command> |
| 25 | + <arg rep="repeat" choice="opt"><replaceable>option</replaceable></arg> |
| 26 | + <arg rep="repeat"><replaceable>file</replaceable></arg> |
| 27 | + </cmdsynopsis> |
| 28 | + </refsynopsisdiv> |
| 29 | + |
| 30 | + <refsect1> |
| 31 | + <title>Description</title> |
| 32 | + <para> |
| 33 | + <application>pg_walsummary</application> is used to print the contents of |
| 34 | + WAL summary files. These binary files are found with the |
| 35 | + <literal>pg_wal/summaries</literal> subdirectory of the data directory, |
| 36 | + and can be converted to text using this tool. This is not ordinarily |
| 37 | + necessary, since WAL summary files primarily exist to support |
| 38 | + <link linkend="backup-incremental-backup">incremental backup</link>, |
| 39 | + but it may be useful for debugging purposes. |
| 40 | + </para> |
| 41 | + |
| 42 | + <para> |
| 43 | + A WAL summary file is indexed by tablespace OID, relation OID, and relation |
| 44 | + fork. For each relation fork, it stores the list of blocks that were |
| 45 | + modified by WAL within the range summarized in the file. It can also |
| 46 | + store a "limit block," which is 0 if the relation fork was created or |
| 47 | + truncated within the relevant WAL range, and otherwise the shortest length |
| 48 | + to which the relation fork was truncated. If the relation fork was not |
| 49 | + created, deleted, or truncated within the relevant WAL range, the limit |
| 50 | + block is undefined or infinite and will not be printed by this tool. |
| 51 | + </para> |
| 52 | + </refsect1> |
| 53 | + |
| 54 | + <refsect1> |
| 55 | + <title>Options</title> |
| 56 | + |
| 57 | + <para> |
| 58 | + <variablelist> |
| 59 | + <varlistentry> |
| 60 | + <term><option>-i</option></term> |
| 61 | + <term><option>--indivudual</option></term> |
| 62 | + <listitem> |
| 63 | + <para> |
| 64 | + By default, <literal>pg_walsummary</literal> prints one line of output |
| 65 | + for each range of one or more consecutive modified blocks. This can |
| 66 | + make the output a lot briefer, since a relation where all blocks from |
| 67 | + 0 through 999 were modified will produce only one line of output rather |
| 68 | + than 1000 separate lines. This option requests a separate line of |
| 69 | + output for every modified block. |
| 70 | + </para> |
| 71 | + </listitem> |
| 72 | + </varlistentry> |
| 73 | + |
| 74 | + <varlistentry> |
| 75 | + <term><option>-q</option></term> |
| 76 | + <term><option>--quiet</option></term> |
| 77 | + <listitem> |
| 78 | + <para> |
| 79 | + Do not print any output, except for errors. This can be useful |
| 80 | + when you want to know whether a WAL summary file can be successfully |
| 81 | + parsed but don't care about the contents. |
| 82 | + </para> |
| 83 | + </listitem> |
| 84 | + </varlistentry> |
| 85 | + |
| 86 | + <varlistentry> |
| 87 | + <term><option>-?</option></term> |
| 88 | + <term><option>--help</option></term> |
| 89 | + <listitem> |
| 90 | + <para> |
| 91 | + Shows help about <application>pg_walsummary</application> command line |
| 92 | + arguments, and exits. |
| 93 | + </para> |
| 94 | + </listitem> |
| 95 | + </varlistentry> |
| 96 | + |
| 97 | + </variablelist> |
| 98 | + </para> |
| 99 | + |
| 100 | + </refsect1> |
| 101 | + |
| 102 | + <refsect1> |
| 103 | + <title>Environment</title> |
| 104 | + |
| 105 | + <para> |
| 106 | + The environment variable <envar>PG_COLOR</envar> specifies whether to use |
| 107 | + color in diagnostic messages. Possible values are |
| 108 | + <literal>always</literal>, <literal>auto</literal> and |
| 109 | + <literal>never</literal>. |
| 110 | + </para> |
| 111 | + </refsect1> |
| 112 | + |
| 113 | + <refsect1> |
| 114 | + <title>See Also</title> |
| 115 | + |
| 116 | + <simplelist type="inline"> |
| 117 | + <member><xref linkend="app-pgbasebackup"/></member> |
| 118 | + <member><xref linkend="app-pgcombinebackup"/></member> |
| 119 | + </simplelist> |
| 120 | + </refsect1> |
| 121 | + |
| 122 | +</refentry> |
0 commit comments