Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
postgres-lambda-diff
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jakob Huber
postgres-lambda-diff
Commits
48fe1374
Commit
48fe1374
authored
18 years ago
by
Neil Conway
Browse files
Options
Downloads
Patches
Plain Diff
Minor additions and typo fixes for the backup documentation. Patch from
Simon Riggs, minor editorialization by Neil Conway.
parent
a676d7f6
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
doc/src/sgml/backup.sgml
+42
-25
42 additions, 25 deletions
doc/src/sgml/backup.sgml
with
42 additions
and
25 deletions
doc/src/sgml/backup.sgml
+
42
−
25
View file @
48fe1374
<!-- $PostgreSQL: pgsql/doc/src/sgml/backup.sgml,v 2.8
6
2006/09/1
6 00:30:11 momjian
Exp $ -->
<!-- $PostgreSQL: pgsql/doc/src/sgml/backup.sgml,v 2.8
7
2006/09/1
9 15:18:41 neilc
Exp $ -->
<chapter id="backup">
<title>Backup and Restore</title>
...
...
@@ -614,10 +614,10 @@ archive_command = 'test ! -f .../%f && cp %p .../%f'
<para>
Also, you can force a segment switch manually with
<function>pg_switch_xlog
()
</>,
if you want to ensure that a
just-finished transaction is archived
immediately. Other utility
functions related to WAL management are
listed in <xref
linkend="functions-admin-backup-table">.
<function>pg_switch_xlog</>,
if you want to ensure that a
just-finished transaction is archived
immediately. Other utility
functions related to WAL management are
listed in <xref
linkend="functions-admin-backup-table">.
</para>
</sect2>
...
...
@@ -666,15 +666,22 @@ SELECT pg_start_backup('label');
<programlisting>
SELECT pg_stop_backup();
</programlisting>
This should return successfully.
This should return successfully; however, the backup is not yet fully
valid. An automatic switch to the next WAL segment occurs, so all
WAL segment files that relate to the backup will now be marked ready for
archiving.
</para>
</listitem>
<listitem>
<para>
Once the WAL segment files used during the backup are archived as part
of normal database activity, you are done. The file identified by
<function>pg_stop_backup</>'s result is the last segment that needs
to be archived to complete the backup.
Once the WAL segment files used during the backup are archived, you are
done. The file identified by <function>pg_stop_backup</>'s result is
the last segment that needs to be archived to complete the backup.
Archival of these files will happen automatically, since you have
already configured <varname>archive_command</>. In many cases, this
happens fairly quickly, but you are advised to monitor your archival
system to ensure this has taken place so that you can be certain you
have a valid backup.
</para>
</listitem>
</orderedlist>
...
...
@@ -701,9 +708,15 @@ SELECT pg_stop_backup();
It is not necessary to be very concerned about the amount of time elapsed
between <function>pg_start_backup</> and the start of the actual backup,
nor between the end of the backup and <function>pg_stop_backup</>; a
few minutes' delay won't hurt anything. You
must however be quite sure that these operations are carried out in
sequence and do not overlap.
few minutes' delay won't hurt anything. However, if you normally run the
server with <varname>full_page_writes</> disabled, you may notice a drop
in performance between <function>pg_start_backup</> and
<function>pg_stop_backup</>. You must ensure that these backup operations
are carried out in sequence without any possible overlap, or you will
invalidate the backup.
</para>
<para>
</para>
<para>
...
...
@@ -1437,20 +1450,22 @@ if (!triggered)
<title>Failover</title>
<para>
If the Primary Server fails then the Standby Server should
take
begin
If the Primary Server fails then the Standby Server should begin
failover procedures.
</para>
<para>
If the Standby Server fails then no failover need take place. If the
Standby Server can be restarted, then the recovery process can also be
immediately restarted, taking advantage of Restartable Recovery.
Standby Server can be restarted, even some time later, then the recovery
process can also be immediately restarted, taking advantage of
Restartable Recovery. If the Standby Server cannot be restarted, then a
full new Standby Server should be created.
</para>
<para>
If the Primary Server fails and then immediately restarts, you must have
a mechanism for informing it that it is no longer the Primary. This is
sometimes known as STONITH (Sho
uld
the Other Node In The Head), which is
sometimes known as STONITH (Sho
ot
the Other Node In The Head), which is
necessary to avoid situations where both systems think they are the
Primary, which can lead to confusion and ultimately data loss.
</para>
...
...
@@ -1479,12 +1494,12 @@ if (!triggered)
</para>
<para>
So, switching from Primary to Standby Server can be fast
,
but requires
So, switching from Primary to Standby Server can be fast but requires
some time to re-prepare the failover cluster. Regular switching from
Primary to Standby is encouraged, since it allows the regular downtime
one
each system require
d
to maintain HA. This also acts as a test of the
failover so that it definitely works when you really need it.
Written
administration procedures are advised.
that
each system require
s
to maintain HA. This also acts as a test of the
failover
mechanism
so that it definitely works when you really need it.
Written
administration procedures are advised.
</para>
</sect2>
...
...
@@ -1492,10 +1507,12 @@ if (!triggered)
<title>Implementing Record-based Log Shipping</title>
<para>
The main features for Log Shipping in this release are based around the
file-based Log Shipping described above. It is also possible to
implement record-based Log Shipping using the pg_xlogfile_name_offset()
function, though this requires custom development.
The main features for Log Shipping in this release are based
around the file-based Log Shipping described above. It is also
possible to implement record-based Log Shipping using the
<function>pg_xlogfile_name_offset</function> function (see <xref
linkend="functions-admin">), though this requires custom
development.
</para>
<para>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment