summaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorItagaki Takahiro <itagaki.takahiro@gmail.com>2010-01-06 05:31:14 +0000
committerItagaki Takahiro <itagaki.takahiro@gmail.com>2010-01-06 05:31:14 +0000
commit946cf229e89fda779161d707f3ba1f4d3cd024a1 (patch)
tree9fc0f7018b101fd1daf84ea2c819a3156de7f07c /doc/src
parent28f6cab61ab8958b1a7dfb019724687d92722538 (diff)
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.
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/ref/vacuum.sgml25
-rw-r--r--doc/src/sgml/ref/vacuumdb.sgml14
2 files changed, 36 insertions, 3 deletions
diff --git a/doc/src/sgml/ref/vacuum.sgml b/doc/src/sgml/ref/vacuum.sgml
index 3b5d241703d..07559e38c42 100644
--- a/doc/src/sgml/ref/vacuum.sgml
+++ b/doc/src/sgml/ref/vacuum.sgml
@@ -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>
diff --git a/doc/src/sgml/ref/vacuumdb.sgml b/doc/src/sgml/ref/vacuumdb.sgml
index ad6f3a8cf3d..2d891c56cf6 100644
--- a/doc/src/sgml/ref/vacuumdb.sgml
+++ b/doc/src/sgml/ref/vacuumdb.sgml
@@ -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>
@@ -130,6 +132,16 @@ PostgreSQL documentation
</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>
<listitem>