Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5b2ebe9

Browse files
committed
Wow, it actually worked for the regression database. More testing needed.
1 parentf5bbcfb commit5b2ebe9

File tree

2 files changed

+370
-356
lines changed

2 files changed

+370
-356
lines changed

‎doc/src/sgml/ref/pg_upgrade.sgml

Lines changed: 20 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$Header: /cvsroot/pgsql/doc/src/sgml/ref/Attic/pg_upgrade.sgml,v 1.19 2002/01/11 20:48:47 momjian Exp $
2+
$Header: /cvsroot/pgsql/doc/src/sgml/ref/Attic/pg_upgrade.sgml,v 1.20 2002/01/13 01:13:59 momjian Exp $
33
PostgreSQL documentation
44
-->
55

@@ -23,9 +23,10 @@ PostgreSQL documentation
2323
<refsynopsisdivinfo>
2424
<date>1999-07-31</date>
2525
</refsynopsisdivinfo>
26-
<synopsis>
27-
pg_upgrade -s <replaceable class="parameter">filename</replaceable> <replaceable class="parameter">old_data_dir</replaceable>
28-
</synopsis>
26+
<cmdsynopsis>
27+
<command>pg_upgrade</command>
28+
<group choice="plain"><arg>-1</arg><arg>-2</arg></group>
29+
</cmdsynopsis>
2930
</refsynopsisdiv>
3031

3132
<refsect1 id="R1-APP-PG-UPGRADE-1">
@@ -56,31 +57,20 @@ pg_upgrade -s <replaceable class="parameter">filename</replaceable> <replaceable
5657

5758
<step performance="required">
5859
<para>
59-
Then do:
60-
<programlisting>
61-
$ pg_dumpall -s > schema.out
62-
</programlisting>
63-
to dump out your old database's table definitions without any data.
64-
</para>
65-
</step>
66-
67-
<step performance="required">
68-
<para>
69-
<command>VACUUM</command> your entire database using
70-
<command>vacuumdb -a</command.>
60+
Copy the program <filename>pgsql/src/bin/pg_dump/pg_upgrade</filename>
61+
from the current PostgreSQL distribution into somewhere in your path.
7162
</para>
7263
</step>
7364

7465
<step performance="required">
7566
<para>
76-
Stop the old postmaster and all backends.
77-
</para>
78-
</step>
79-
80-
<step performance="required">
81-
<para>
82-
Rename (using mv) your old pgsql <filename>data/</filename> directory to
83-
<filename>data.old/</filename>.
67+
Change your working directory to the
68+
pgsql main directory, and type:
69+
<programlisting>
70+
$ pg_upgrade -1
71+
</programlisting>
72+
to collect information about the old database needed for the
73+
upgrade.
8474
</para>
8575
</step>
8676

@@ -109,14 +99,15 @@ $ make install
10999
<step performance="required">
110100
<para>
111101
Run <application>initdb</application> to create a new template1 database
112-
containing the system tables for the new release.
102+
containing the system tables for the new release. Make sure you use
103+
settings similar to those used in your previous version.
113104
</para>
114105
</step>
115106

116107
<step performance="required">
117108
<para>
118109
Start the new postmaster. (Note: it is critical that no users connect
119-
to thedatabase until the upgrade is complete. You may wish to start
110+
to theserver until the upgrade is complete. You may wish to start
120111
the postmaster without -i and/or alter <filename>pg_hba.conf</filename>
121112
temporarily.)
122113
</para>
@@ -127,7 +118,7 @@ $ make install
127118
Change your working directory to the
128119
pgsql main directory, and type:
129120
<programlisting>
130-
$ pg_upgrade -s schema.out data.old
121+
$ pg_upgrade -2
131122
</programlisting>
132123
The program will do some checking to make sure everything is properly
133124
configured, and will run your db.out script to recreate all the databases
@@ -149,7 +140,7 @@ $ pg_upgrade -s schema.out data.old
149140
<step performance="required">
150141
<para>
151142
<emphasis>Carefully</emphasis> examine the contents of the upgraded
152-
database. If you detect problems, you'll need to recover by restoring
143+
databases. If you detect problems, you'll need to recover by restoring
153144
from your full pg_dump backup.
154145
You can delete the <filename>data.old/</filename> directory when you
155146
are satisfied.
@@ -158,18 +149,11 @@ $ pg_upgrade -s schema.out data.old
158149

159150
<step performance="required">
160151
<para>
161-
The upgradeddatabase will be in an un-vacuumed state. You will probably
152+
The upgradeddatabases will be in an un-vacuumed state. You will probably
162153
want to run a <command>VACUUM ANALYZE</command> before beginning
163154
production work.
164155
</para>
165156
</step>
166-
167-
<note>
168-
<para>
169-
pg_upgrade does not handle custom tables/indexes/sequences in template1.
170-
It does handle other template1 object customizations.
171-
</para>
172-
</note>
173157
</procedure>
174158
</refsect1>
175159
</refentry>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp