mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
Support rewritten-based full vacuum as VACUUM FULL. Traditional
VACUUM FULL was renamed to VACUUM FULL INPLACE. Also added a new option -i, --inplace for vacuumdb to perform FULL INPLACE vacuuming. Since the new VACUUM FULL uses CLUSTER infrastructure, we cannot use it for system tables. VACUUM FULL for system tables always fall back into VACUUM FULL INPLACE silently. Itagaki Takahiro, reviewed by Jeff Davis and Simon Riggs.
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
<!--
|
||||
$PostgreSQL: pgsql/doc/src/sgml/ref/vacuum.sgml,v 1.56 2009/11/16 21:32:06 tgl Exp $
|
||||
$PostgreSQL: pgsql/doc/src/sgml/ref/vacuum.sgml,v 1.57 2010/01/06 05:31:13 itagaki Exp $
|
||||
PostgreSQL documentation
|
||||
-->
|
||||
|
||||
@ -21,7 +21,7 @@ PostgreSQL documentation
|
||||
|
||||
<refsynopsisdiv>
|
||||
<synopsis>
|
||||
VACUUM [ ( { FULL | FREEZE | VERBOSE | ANALYZE } [, ...] ) ] [ <replaceable class="PARAMETER">table</replaceable> [ (<replaceable class="PARAMETER">column</replaceable> [, ...] ) ] ]
|
||||
VACUUM [ ( { FULL [ INPLACE ] | FREEZE | VERBOSE | ANALYZE } [, ...] ) ] [ <replaceable class="PARAMETER">table</replaceable> [ (<replaceable class="PARAMETER">column</replaceable> [, ...] ) ] ]
|
||||
VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] [ <replaceable class="PARAMETER">table</replaceable> ]
|
||||
VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] ANALYZE [ <replaceable class="PARAMETER">table</replaceable> [ (<replaceable class="PARAMETER">column</replaceable> [, ...] ) ] ]
|
||||
</synopsis>
|
||||
@ -86,6 +86,27 @@ VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] ANALYZE [ <replaceable class="PARAMETER">
|
||||
Selects <quote>full</quote> vacuum, which can reclaim more
|
||||
space, but takes much longer and exclusively locks the table.
|
||||
</para>
|
||||
<para>
|
||||
For user tables, all table data and indexes are rewritten. This
|
||||
method requires extra disk space in which to write the new data,
|
||||
and is generally useful when a significant amount of space needs
|
||||
to be reclaimed from within the table.
|
||||
</para>
|
||||
<para>
|
||||
For system tables, all table data and indexes are modified in
|
||||
place to reclaim space. This method may require less disk space
|
||||
for the table data than <command>VACUUM FULL</command> on a
|
||||
comparable user table, but the indexes will grow which may
|
||||
counteract that benefit. Additionally, the operation is often
|
||||
slower than <command>VACUUM FULL</command> on a comparable user
|
||||
table.
|
||||
</para>
|
||||
<para>
|
||||
If <literal>FULL INPLACE</literal> is specified, the space is
|
||||
reclaimed in the same manner as a system table, even if it is a
|
||||
user table. Specifying <literal>INPLACE</literal> explicitly is
|
||||
rarely useful.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
<!--
|
||||
$PostgreSQL: pgsql/doc/src/sgml/ref/vacuumdb.sgml,v 1.46 2010/01/06 02:59:44 momjian Exp $
|
||||
$PostgreSQL: pgsql/doc/src/sgml/ref/vacuumdb.sgml,v 1.47 2010/01/06 05:31:13 itagaki Exp $
|
||||
PostgreSQL documentation
|
||||
-->
|
||||
|
||||
@ -24,6 +24,7 @@ PostgreSQL documentation
|
||||
<command>vacuumdb</command>
|
||||
<arg rep="repeat"><replaceable>connection-option</replaceable></arg>
|
||||
<group><arg>--full</arg><arg>-f</arg></group>
|
||||
<group><arg>--inplace</arg><arg>-i</arg></group>
|
||||
<group><arg>--freeze</arg><arg>-F</arg></group>
|
||||
<group><arg>--verbose</arg><arg>-v</arg></group>
|
||||
<group><arg>--analyze</arg><arg>-z</arg></group>
|
||||
@ -37,6 +38,7 @@ PostgreSQL documentation
|
||||
<arg rep="repeat"><replaceable>connection-options</replaceable></arg>
|
||||
<group><arg>--all</arg><arg>-a</arg></group>
|
||||
<group><arg>--full</arg><arg>-f</arg></group>
|
||||
<group><arg>--inplace</arg><arg>-i</arg></group>
|
||||
<group><arg>--freeze</arg><arg>-F</arg></group>
|
||||
<group><arg>--verbose</arg><arg>-v</arg></group>
|
||||
<group><arg>--analyze</arg><arg>-z</arg></group>
|
||||
@ -129,6 +131,16 @@ PostgreSQL documentation
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>-i</option></term>
|
||||
<term><option>--inplace</option></term>
|
||||
<listitem>
|
||||
<para>
|
||||
Perform <quote>full inplace</quote> vacuuming.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><option>-o</option></term>
|
||||
<term><option>--only-analyze</option></term>
|
||||
|
Reference in New Issue
Block a user