1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2025-09-16 09:06:18 +02:00

v2.00: Performance Improvements for Archive Push

Features:

* The archive-push command is now partially coded in C which allows the PostgreSQL archive_command to run significantly faster when processing status messages from the asynchronous archive process. (Reviewed by Cynthia Shang.)

Improvements:

* Improve check command to verify that the backup manifest can be built. (Contributed by Cynthia Shang.)
* Improve performance of HTTPS client. Buffering now takes the pending bytes on the socket into account (when present) rather than relying entirely on select(). In some instances the final bytes would not be flushed until the connection was closed.
* Improve S3 delete performance. The constant S3_BATCH_MAX had been replaced with a hard-coded value of 2, probably during testing.
* Allow any non-command-line option to be reset to default on the command-line. This allows options in pgbackrest.conf to be reset to default which reduces the need to write new configuration files for specific needs.
* The C library is now required. This eliminates conditional loading and eases development of new library features.
* The pgbackrest executable is now a C binary instead of Perl. This allows certain time-critical commands (like async archive-push) to run more quickly.
* Rename db-* options to pg-* and backup-* options to repo-* to improve consistency. repo-* options are now indexed although currently only one is allowed.
This commit is contained in:
David Steele
2018-02-23 22:38:45 -05:00
parent ed5876810d
commit 13cdb75ac5
8 changed files with 1772 additions and 1728 deletions

View File

@@ -6,7 +6,9 @@ pgBackRest aims to be a simple, reliable backup and restore system that can seam
Instead of relying on traditional backup tools like tar and rsync, pgBackRest implements all backup features internally and uses a custom protocol for communicating with remote systems. Removing reliance on tar and rsync allows for better solutions to database-specific backup challenges. The custom remote protocol allows for more flexibility and limits the types of connections that are required to perform a backup which increases security. Instead of relying on traditional backup tools like tar and rsync, pgBackRest implements all backup features internally and uses a custom protocol for communicating with remote systems. Removing reliance on tar and rsync allows for better solutions to database-specific backup challenges. The custom remote protocol allows for more flexibility and limits the types of connections that are required to perform a backup which increases security.
pgBackRest [v1.28](https://github.com/pgbackrest/pgbackrest/releases/tag/release/1.28) is the current stable release. Release notes are on the [Releases](http://www.pgbackrest.org/release.html) page. pgBackRest [v2.00](https://github.com/pgbackrest/pgbackrest/releases/tag/release/2.00) is the current stable release. Release notes are on the [Releases](http://www.pgbackrest.org/release.html) page.
pgBackRest v1 will receive bugs fixes only until EOL. Documentation for v1 can be found [here](http://www.pgbackrest.org/1).
## Features ## Features

File diff suppressed because it is too large Load Diff

View File

@@ -35,6 +35,8 @@
<p>Instead of relying on traditional backup tools like tar and rsync, <backrest/> implements all backup features internally and uses a custom protocol for communicating with remote systems. Removing reliance on tar and rsync allows for better solutions to database-specific backup challenges. The custom remote protocol allows for more flexibility and limits the types of connections that are required to perform a backup which increases security.</p> <p>Instead of relying on traditional backup tools like tar and rsync, <backrest/> implements all backup features internally and uses a custom protocol for communicating with remote systems. Removing reliance on tar and rsync allows for better solutions to database-specific backup challenges. The custom remote protocol allows for more flexibility and limits the types of connections that are required to perform a backup which increases security.</p>
<p><backrest/> <link url="{[github-url-base]}/releases/tag/release/{[version-stable]}">v{[version-stable]}</link> is the current stable release. Release notes are on the <link page="{[backrest-page-release]}">Releases</link> page.</p> <p><backrest/> <link url="{[github-url-base]}/releases/tag/release/{[version-stable]}">v{[version-stable]}</link> is the current stable release. Release notes are on the <link page="{[backrest-page-release]}">Releases</link> page.</p>
<p><backrest/> <proper>v1</proper> will receive bugs fixes only until EOL. Documentation for <proper>v1</proper> can be found <link url="{[backrest-url-base]}/1">here</link>.</p>
</section> </section>
<section id="features"> <section id="features">

View File

@@ -4,13 +4,15 @@
<description>The {[project]} Releases detail each version of the software and lists the changes made in each version.</description> <description>The {[project]} Releases detail each version of the software and lists the changes made in each version.</description>
<intro> <intro>
<text><backrest/> release numbers consist of two parts, major and minor. A major release may break compatibility with the prior major release, for instance the 1.XX releases are not compatible with the 0.XX releases. Minor releases can include bug fixes and features but do not change the repository format and strive to avoid changing options and naming. <text><backrest/> release numbers consist of two parts, major and minor. A major release <i>may</i> break compatibility with the prior major release, but <proper>v2</proper> releases are fully compatible with <proper>v1</proper> repositories and will accept all <proper>v1</proper> options. Minor releases can include bug fixes and features but do not change the repository format and strive to avoid changing options and naming.
Documentation for the <proper>v1</proper> release can be found <link url="{[backrest-url-base]}/1">here</link>.
The notes for a release may also contain <quote>Additional Notes</quote> but changes in this section are only to documentation or the test suite and have no direct impact the on the <backrest/> codebase.</text> The notes for a release may also contain <quote>Additional Notes</quote> but changes in this section are only to documentation or the test suite and have no direct impact the on the <backrest/> codebase.</text>
</intro> </intro>
<release-list> <release-list>
<release date="XXXX-XX-XX" version="2.00dev" title="UNDER DEVELOPMENT"> <release date="2018-02-23" version="2.00" title="Performance Improvements for Archive Push">
<release-core-list> <release-core-list>
<release-feature-list> <release-feature-list>
<release-item> <release-item>
@@ -52,7 +54,7 @@
</release-item> </release-item>
<release-item> <release-item>
<p>Rename <id>db-*</id> options to <id>pg-*</id> and <id>backup-*</id> options to <id>repo-*</id> to improve consistency. <id>repo-*</id> options are now indexed although only one is allowed.</p> <p>Rename <id>db-*</id> options to <id>pg-*</id> and <id>backup-*</id> options to <id>repo-*</id> to improve consistency. <id>repo-*</id> options are now indexed although currently only one is allowed.</p>
</release-item> </release-item>
</release-improvement-list> </release-improvement-list>
@@ -1030,7 +1032,7 @@
<release date="2017-06-27" version="1.20" title="Critical 8.3/8.4 Bug Fix"> <release date="2017-06-27" version="1.20" title="Critical 8.3/8.4 Bug Fix">
<release-core-list> <release-core-list>
<p><b>IMPORTANT NOTE</b>: <postgres/> <proper>8.3</proper> and <proper>8.4</proper> installations utilizing tablespaces should upgrade immediately from any <id>1.XX</id> release and run a full backup. A bug prevented tablespaces from being backed up on these versions only. <postgres/> &amp;ge; <proper>9.0</proper> is not affected.</p> <p><b>IMPORTANT NOTE</b>: <postgres/> <proper>8.3</proper> and <proper>8.4</proper> installations utilizing tablespaces should upgrade immediately from any <proper>v1</proper> release and run a full backup. A bug prevented tablespaces from being backed up on these versions only. <postgres/> &amp;ge; <proper>9.0</proper> is not affected.</p>
<release-bug-list> <release-bug-list>
<release-item> <release-item>
@@ -1540,7 +1542,7 @@
<release-item-ideator id="golpayegani.navid"/> <release-item-ideator id="golpayegani.navid"/>
</release-item-contributor-list> </release-item-contributor-list>
<p>Fixed a regression introduced in <id>v1.13</id> that could cause backups to fail if files were removed (e.g. tables dropped) while the manifest was being built.</p> <p>Fixed a regression introduced in <proper>v1.13</proper> that could cause backups to fail if files were removed (e.g. tables dropped) while the manifest was being built.</p>
</release-item> </release-item>
</release-bug-list> </release-bug-list>
@@ -1978,7 +1980,7 @@
</release-item> </release-item>
<release-item> <release-item>
<p>Fixed regression in section links introduced in <id>v1.10</id>.</p> <p>Fixed regression in section links introduced in <proper>v1.10</proper>.</p>
</release-item> </release-item>
</release-bug-list> </release-bug-list>
@@ -2072,7 +2074,7 @@
<release-item-ideator id="frost.stephen"/> <release-item-ideator id="frost.stephen"/>
</release-item-contributor-list> </release-item-contributor-list>
<p>Fixed an issue where asynchronous archiving was transferring one file per execution instead of transferring files in batches. This regression was introduced in <id>v1.09</id> and affected efficiency only, all WAL segments were correctly archived in asynchronous mode.</p> <p>Fixed an issue where asynchronous archiving was transferring one file per execution instead of transferring files in batches. This regression was introduced in <proper>v1.09</proper> and affected efficiency only, all WAL segments were correctly archived in asynchronous mode.</p>
</release-item> </release-item>
</release-bug-list> </release-bug-list>
</release-core-list> </release-core-list>

View File

@@ -222,7 +222,7 @@
<execute user="root"> <execute user="root">
<exe-cmd>yum install perl perl-Time-HiRes perl-parent perl-JSON <exe-cmd>yum install perl perl-Time-HiRes perl-parent perl-JSON
perl-Digest-SHA perl-DBD-Pg perl-XML-LibXML perl-IO-Socket-SSL</exe-cmd> perl-Digest-SHA perl-DBD-Pg perl-XML-LibXML perl-IO-Socket-SSL</exe-cmd>
<exe-cmd-extra>-y</exe-cmd-extra> <exe-cmd-extra>-y 2>&amp;1</exe-cmd-extra>
</execute> </execute>
</execute-list> </execute-list>
@@ -405,7 +405,7 @@
<section id="v1-v2"> <section id="v1-v2">
<title>Upgrading {[project]} from v1 to v2</title> <title>Upgrading {[project]} from v1 to v2</title>
<p>Upgrading from 1.xx (v1) to 2.xx (v2) is fairly straight-forward. The repository format has not changed and all non-deprecated options from v1 are accepted, so for most installations it is simply a matter of installing the new version.</p> <p>Upgrading from v1.xx to v2.xx (v2) is fairly straight-forward. The repository format has not changed and all non-deprecated options from v1 are accepted, so for most installations it is simply a matter of installing the new version.</p>
<p>However, there are a few caveats:</p> <p>However, there are a few caveats:</p>

View File

@@ -39,7 +39,7 @@ push @EXPORT, qw(backrestBin backrestBinSet);
# Defines the current version of the BackRest executable. The version number is used to track features but does not affect what # Defines the current version of the BackRest executable. The version number is used to track features but does not affect what
# repositories or manifests can be read - that's the job of the format number. # repositories or manifests can be read - that's the job of the format number.
#----------------------------------------------------------------------------------------------------------------------------------- #-----------------------------------------------------------------------------------------------------------------------------------
use constant BACKREST_VERSION => '2.00dev'; use constant BACKREST_VERSION => '2.00';
push @EXPORT, qw(BACKREST_VERSION); push @EXPORT, qw(BACKREST_VERSION);
# Format Format Number # Format Format Number

View File

@@ -6,7 +6,7 @@ package pgBackRest::LibCAuto;
# Library version (.999 indicates development version) # Library version (.999 indicates development version)
sub libcAutoVersion sub libcAutoVersion
{ {
return '2.00.999'; return '2.00';
} }
# Configuration option value constants # Configuration option value constants

View File

@@ -17,6 +17,6 @@ Standard binary name
/*********************************************************************************************************************************** /***********************************************************************************************************************************
Version of the software. Currently this value is maintained in Version.pm and updated by test.pl. Version of the software. Currently this value is maintained in Version.pm and updated by test.pl.
***********************************************************************************************************************************/ ***********************************************************************************************************************************/
#define PGBACKREST_VERSION "2.00dev" #define PGBACKREST_VERSION "2.00"
#endif #endif