mirror of
https://github.com/postgres/postgres.git
synced 2025-09-02 04:21:28 +03:00
Create a "relation mapping" infrastructure to support changing the relfilenodes
of shared or nailed system catalogs. This has two key benefits: * The new CLUSTER-based VACUUM FULL can be applied safely to all catalogs. * We no longer have to use an unsafe reindex-in-place approach for reindexing shared catalogs. CLUSTER on nailed catalogs now works too, although I left it disabled on shared catalogs because the resulting pg_index.indisclustered update would only be visible in one database. Since reindexing shared system catalogs is now fully transactional and crash-safe, the former special cases in REINDEX behavior have been removed; shared catalogs are treated the same as non-shared. This commit does not do anything about the recently-discussed problem of deadlocks between VACUUM FULL/CLUSTER on a system catalog and other concurrent queries; will address that in a separate patch. As a stopgap, parallel_schedule has been tweaked to run vacuum.sql by itself, to avoid such failures during the regression tests.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<!--
|
||||
$PostgreSQL: pgsql/doc/src/sgml/ref/cluster.sgml,v 1.47 2009/09/19 10:23:26 petere Exp $
|
||||
$PostgreSQL: pgsql/doc/src/sgml/ref/cluster.sgml,v 1.48 2010/02/07 20:48:09 tgl Exp $
|
||||
PostgreSQL documentation
|
||||
-->
|
||||
|
||||
@@ -30,12 +30,12 @@ CLUSTER [VERBOSE]
|
||||
<title>Description</title>
|
||||
|
||||
<para>
|
||||
<command>CLUSTER</command> instructs <productname>PostgreSQL</productname>
|
||||
<command>CLUSTER</command> instructs <productname>PostgreSQL</productname>
|
||||
to cluster the table specified
|
||||
by <replaceable class="parameter">table_name</replaceable>
|
||||
based on the index specified by
|
||||
<replaceable class="parameter">index_name</replaceable>. The index must
|
||||
already have been defined on
|
||||
already have been defined on
|
||||
<replaceable class="parameter">table_name</replaceable>.
|
||||
</para>
|
||||
|
||||
@@ -46,9 +46,9 @@ CLUSTER [VERBOSE]
|
||||
not clustered. That is, no attempt is made to store new or
|
||||
updated rows according to their index order. (If one wishes, one can
|
||||
periodically recluster by issuing the command again. Also, setting
|
||||
the table's <literal>FILLFACTOR</literal> storage parameter to less than 100% can aid
|
||||
in preserving cluster ordering during updates, since updated rows
|
||||
are preferentially kept on the same page.)
|
||||
the table's <literal>FILLFACTOR</literal> storage parameter to less than
|
||||
100% can aid in preserving cluster ordering during updates, since updated
|
||||
rows are kept on the same page if enough space is available there.)
|
||||
</para>
|
||||
|
||||
<para>
|
||||
|
Reference in New Issue
Block a user