mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2025-01-30 05:39:12 +02:00
Clarify restore --type behavior in command reference.
This commit is contained in:
parent
d791bb7298
commit
a6691c6f61
@ -1542,7 +1542,7 @@
|
||||
|
||||
<text>The restore command automatically defaults to selecting the latest backup from the first repository where backups exist (see <link page="user-guide" section="/quickstart/perform-restore">Quick Start - Restore a Backup</link>). The order in which the repositories are checked is dictated by the <file>pgbackrest.conf</file> (e.g. repo1 will be checked before repo2). To select from a specific repository, the <br-option>{[dash]}-repo</br-option> option can be passed (e.g. <br-option>{[dash]}-repo=1</br-option>). The <br-option>{[dash]}-set</br-option> option can be passed if a backup other than the latest is desired.
|
||||
|
||||
For PITR, <br-option>{[dash]}-type=time</br-option> must be provided and the target time specified with the <br-option>{[dash]}-target</br-option> option. If a backup is not specified via the <br-option>{[dash]}-set</br-option> option, then the configured repositories will be checked, in order, for a backup that contains the requested time. If no backup can be found, the latest backup from the first repository containing backups will be used. See <link page="user-guide" section="/pitr">Point-in-Time Recovery</link> for more details and examples.</text>
|
||||
When PITR of <br-option>{[dash]}-type=time</br-option> is specified, then the target time must be specified with the <br-option>{[dash]}-target</br-option> option. If a backup is not specified via the <br-option>{[dash]}-set</br-option> option, then the configured repositories will be checked, in order, for a backup that contains the requested time. If no backup can be found, the latest backup from the first repository containing backups will be used. For other types of PITR, e.g. <id>xid</id>, the <br-option>{[dash]}-set</br-option> option must be provided if the target is prior to the latest backup. See <link page="user-guide" section="/pitr">Point-in-Time Recovery</link> for more details and examples.</text>
|
||||
|
||||
<option-list>
|
||||
<!-- OPERATION - RESTORE COMMAND - SET OPTION -->
|
||||
@ -1584,7 +1584,7 @@
|
||||
<option id="target" name="Target">
|
||||
<summary>Recovery target.</summary>
|
||||
|
||||
<text>Defines the recovery target when <br-option>--type</br-option> is <id>name</id>, <id>xid</id>, or <id>time</id>.</text>
|
||||
<text>Defines the recovery target when <br-option>--type</br-option> is <id>name</id>, <id>xid</id>, or <id>time</id>. If the target is prior to the latest backup and <br-option>--type</br-option> is not <id>time</id>, then use the <br-option>--set</br-option> option to specify the backup set.</text>
|
||||
<example>2015-01-30 14:15:11 EST</example>
|
||||
</option>
|
||||
|
||||
|
@ -112,6 +112,15 @@
|
||||
|
||||
<release-doc-list>
|
||||
<release-improvement-list>
|
||||
<release-item>
|
||||
<release-item-contributor-list>
|
||||
<release-item-contributor id="cynthia.shang"/>
|
||||
<release-item-reviewer id="david.steele"/>
|
||||
</release-item-contributor-list>
|
||||
|
||||
<p>Clarify <cmd>restore</cmd> <br-option>--type</br-option> behavior in command reference.</p>
|
||||
</release-item>
|
||||
|
||||
<release-item>
|
||||
<github-pull-request id="1446"/>
|
||||
|
||||
|
@ -598,7 +598,7 @@ static const unsigned char helpDataPack[] =
|
||||
0x79, 0x1B, // Summary
|
||||
0x52, 0x65, 0x73, 0x74, 0x6F, 0x72, 0x65, 0x20, 0x61, 0x20, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x20, 0x63,
|
||||
0x6C, 0x75, 0x73, 0x74, 0x65, 0x72, 0x2E,
|
||||
0x78, 0xDF, 0x06, // Description
|
||||
0x78, 0xDA, 0x07, // Description
|
||||
0x54, 0x68, 0x65, 0x20, 0x72, 0x65, 0x73, 0x74, 0x6F, 0x72, 0x65, 0x20, 0x63, 0x6F, 0x6D, 0x6D, 0x61, 0x6E, 0x64, 0x20,
|
||||
0x61, 0x75, 0x74, 0x6F, 0x6D, 0x61, 0x74, 0x69, 0x63, 0x61, 0x6C, 0x6C, 0x79, 0x20, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6C,
|
||||
0x74, 0x73, 0x20, 0x74, 0x6F, 0x20, 0x73, 0x65, 0x6C, 0x65, 0x63, 0x74, 0x69, 0x6E, 0x67, 0x20, 0x74, 0x68, 0x65, 0x20,
|
||||
@ -622,27 +622,33 @@ static const unsigned char helpDataPack[] =
|
||||
0x64, 0x20, 0x69, 0x66, 0x20, 0x61, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x6F, 0x74, 0x68, 0x65, 0x72, 0x20,
|
||||
0x74, 0x68, 0x61, 0x6E, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6C, 0x61, 0x74, 0x65, 0x73, 0x74, 0x20, 0x69, 0x73, 0x20, 0x64,
|
||||
0x65, 0x73, 0x69, 0x72, 0x65, 0x64, 0x2E, 0x0A, 0x0A,
|
||||
0x46, 0x6F, 0x72, 0x20, 0x50, 0x49, 0x54, 0x52, 0x2C, 0x20, 0x2D, 0x2D, 0x74, 0x79, 0x70, 0x65, 0x3D, 0x74, 0x69, 0x6D,
|
||||
0x65, 0x20, 0x6D, 0x75, 0x73, 0x74, 0x20, 0x62, 0x65, 0x20, 0x70, 0x72, 0x6F, 0x76, 0x69, 0x64, 0x65, 0x64, 0x20, 0x61,
|
||||
0x6E, 0x64, 0x20, 0x74, 0x68, 0x65, 0x20, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x20, 0x74, 0x69, 0x6D, 0x65, 0x20, 0x73,
|
||||
0x70, 0x65, 0x63, 0x69, 0x66, 0x69, 0x65, 0x64, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x2D, 0x2D,
|
||||
0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x20, 0x6F, 0x70, 0x74, 0x69, 0x6F, 0x6E, 0x2E, 0x20, 0x49, 0x66, 0x20, 0x61, 0x20,
|
||||
0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x69, 0x73, 0x20, 0x6E, 0x6F, 0x74, 0x20, 0x73, 0x70, 0x65, 0x63, 0x69, 0x66,
|
||||
0x69, 0x65, 0x64, 0x20, 0x76, 0x69, 0x61, 0x20, 0x74, 0x68, 0x65, 0x20, 0x2D, 0x2D, 0x73, 0x65, 0x74, 0x20, 0x6F, 0x70,
|
||||
0x74, 0x69, 0x6F, 0x6E, 0x2C, 0x20, 0x74, 0x68, 0x65, 0x6E, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x6F, 0x6E, 0x66, 0x69,
|
||||
0x67, 0x75, 0x72, 0x65, 0x64, 0x20, 0x72, 0x65, 0x70, 0x6F, 0x73, 0x69, 0x74, 0x6F, 0x72, 0x69, 0x65, 0x73, 0x20, 0x77,
|
||||
0x69, 0x6C, 0x6C, 0x20, 0x62, 0x65, 0x20, 0x63, 0x68, 0x65, 0x63, 0x6B, 0x65, 0x64, 0x2C, 0x20, 0x69, 0x6E, 0x20, 0x6F,
|
||||
0x72, 0x64, 0x65, 0x72, 0x2C, 0x20, 0x66, 0x6F, 0x72, 0x20, 0x61, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x74,
|
||||
0x68, 0x61, 0x74, 0x20, 0x63, 0x6F, 0x6E, 0x74, 0x61, 0x69, 0x6E, 0x73, 0x20, 0x74, 0x68, 0x65, 0x20, 0x72, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x65, 0x64, 0x20, 0x74, 0x69, 0x6D, 0x65, 0x2E, 0x20, 0x49, 0x66, 0x20, 0x6E, 0x6F, 0x20, 0x62,
|
||||
0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x63, 0x61, 0x6E, 0x20, 0x62, 0x65, 0x20, 0x66, 0x6F, 0x75, 0x6E, 0x64, 0x2C, 0x20,
|
||||
0x74, 0x68, 0x65, 0x20, 0x6C, 0x61, 0x74, 0x65, 0x73, 0x74, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x66, 0x72,
|
||||
0x6F, 0x6D, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69, 0x72, 0x73, 0x74, 0x20, 0x72, 0x65, 0x70, 0x6F, 0x73, 0x69, 0x74,
|
||||
0x6F, 0x72, 0x79, 0x20, 0x63, 0x6F, 0x6E, 0x74, 0x61, 0x69, 0x6E, 0x69, 0x6E, 0x67, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75,
|
||||
0x70, 0x73, 0x20, 0x77, 0x69, 0x6C, 0x6C, 0x20, 0x62, 0x65, 0x20, 0x75, 0x73, 0x65, 0x64, 0x2E, 0x20, 0x53, 0x65, 0x65,
|
||||
0x20, 0x50, 0x6F, 0x69, 0x6E, 0x74, 0x2D, 0x69, 0x6E, 0x2D, 0x54, 0x69, 0x6D, 0x65, 0x20, 0x52, 0x65, 0x63, 0x6F, 0x76,
|
||||
0x65, 0x72, 0x79, 0x20, 0x66, 0x6F, 0x72, 0x20, 0x6D, 0x6F, 0x72, 0x65, 0x20, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6C, 0x73,
|
||||
0x20, 0x61, 0x6E, 0x64, 0x20, 0x65, 0x78, 0x61, 0x6D, 0x70, 0x6C, 0x65, 0x73, 0x2E,
|
||||
0x57, 0x68, 0x65, 0x6E, 0x20, 0x50, 0x49, 0x54, 0x52, 0x20, 0x6F, 0x66, 0x20, 0x2D, 0x2D, 0x74, 0x79, 0x70, 0x65, 0x3D,
|
||||
0x74, 0x69, 0x6D, 0x65, 0x20, 0x69, 0x73, 0x20, 0x73, 0x70, 0x65, 0x63, 0x69, 0x66, 0x69, 0x65, 0x64, 0x2C, 0x20, 0x74,
|
||||
0x68, 0x65, 0x6E, 0x20, 0x74, 0x68, 0x65, 0x20, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x20, 0x74, 0x69, 0x6D, 0x65, 0x20,
|
||||
0x6D, 0x75, 0x73, 0x74, 0x20, 0x62, 0x65, 0x20, 0x73, 0x70, 0x65, 0x63, 0x69, 0x66, 0x69, 0x65, 0x64, 0x20, 0x77, 0x69,
|
||||
0x74, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x2D, 0x2D, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x20, 0x6F, 0x70, 0x74, 0x69,
|
||||
0x6F, 0x6E, 0x2E, 0x20, 0x49, 0x66, 0x20, 0x61, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x69, 0x73, 0x20, 0x6E,
|
||||
0x6F, 0x74, 0x20, 0x73, 0x70, 0x65, 0x63, 0x69, 0x66, 0x69, 0x65, 0x64, 0x20, 0x76, 0x69, 0x61, 0x20, 0x74, 0x68, 0x65,
|
||||
0x20, 0x2D, 0x2D, 0x73, 0x65, 0x74, 0x20, 0x6F, 0x70, 0x74, 0x69, 0x6F, 0x6E, 0x2C, 0x20, 0x74, 0x68, 0x65, 0x6E, 0x20,
|
||||
0x74, 0x68, 0x65, 0x20, 0x63, 0x6F, 0x6E, 0x66, 0x69, 0x67, 0x75, 0x72, 0x65, 0x64, 0x20, 0x72, 0x65, 0x70, 0x6F, 0x73,
|
||||
0x69, 0x74, 0x6F, 0x72, 0x69, 0x65, 0x73, 0x20, 0x77, 0x69, 0x6C, 0x6C, 0x20, 0x62, 0x65, 0x20, 0x63, 0x68, 0x65, 0x63,
|
||||
0x6B, 0x65, 0x64, 0x2C, 0x20, 0x69, 0x6E, 0x20, 0x6F, 0x72, 0x64, 0x65, 0x72, 0x2C, 0x20, 0x66, 0x6F, 0x72, 0x20, 0x61,
|
||||
0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x63, 0x6F, 0x6E, 0x74, 0x61, 0x69, 0x6E,
|
||||
0x73, 0x20, 0x74, 0x68, 0x65, 0x20, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x65, 0x64, 0x20, 0x74, 0x69, 0x6D, 0x65,
|
||||
0x2E, 0x20, 0x49, 0x66, 0x20, 0x6E, 0x6F, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x63, 0x61, 0x6E, 0x20, 0x62,
|
||||
0x65, 0x20, 0x66, 0x6F, 0x75, 0x6E, 0x64, 0x2C, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6C, 0x61, 0x74, 0x65, 0x73, 0x74, 0x20,
|
||||
0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x66, 0x72, 0x6F, 0x6D, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69, 0x72, 0x73,
|
||||
0x74, 0x20, 0x72, 0x65, 0x70, 0x6F, 0x73, 0x69, 0x74, 0x6F, 0x72, 0x79, 0x20, 0x63, 0x6F, 0x6E, 0x74, 0x61, 0x69, 0x6E,
|
||||
0x69, 0x6E, 0x67, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x73, 0x20, 0x77, 0x69, 0x6C, 0x6C, 0x20, 0x62, 0x65, 0x20,
|
||||
0x75, 0x73, 0x65, 0x64, 0x2E, 0x20, 0x46, 0x6F, 0x72, 0x20, 0x6F, 0x74, 0x68, 0x65, 0x72, 0x20, 0x74, 0x79, 0x70, 0x65,
|
||||
0x73, 0x20, 0x6F, 0x66, 0x20, 0x50, 0x49, 0x54, 0x52, 0x2C, 0x20, 0x65, 0x2E, 0x67, 0x2E, 0x20, 0x78, 0x69, 0x64, 0x2C,
|
||||
0x20, 0x74, 0x68, 0x65, 0x20, 0x2D, 0x2D, 0x73, 0x65, 0x74, 0x20, 0x6F, 0x70, 0x74, 0x69, 0x6F, 0x6E, 0x20, 0x6D, 0x75,
|
||||
0x73, 0x74, 0x20, 0x62, 0x65, 0x20, 0x70, 0x72, 0x6F, 0x76, 0x69, 0x64, 0x65, 0x64, 0x20, 0x69, 0x66, 0x20, 0x74, 0x68,
|
||||
0x65, 0x20, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x20, 0x69, 0x73, 0x20, 0x70, 0x72, 0x69, 0x6F, 0x72, 0x20, 0x74, 0x6F,
|
||||
0x20, 0x74, 0x68, 0x65, 0x20, 0x6C, 0x61, 0x74, 0x65, 0x73, 0x74, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x2E, 0x20,
|
||||
0x53, 0x65, 0x65, 0x20, 0x50, 0x6F, 0x69, 0x6E, 0x74, 0x2D, 0x69, 0x6E, 0x2D, 0x54, 0x69, 0x6D, 0x65, 0x20, 0x52, 0x65,
|
||||
0x63, 0x6F, 0x76, 0x65, 0x72, 0x79, 0x20, 0x66, 0x6F, 0x72, 0x20, 0x6D, 0x6F, 0x72, 0x65, 0x20, 0x64, 0x65, 0x74, 0x61,
|
||||
0x69, 0x6C, 0x73, 0x20, 0x61, 0x6E, 0x64, 0x20, 0x65, 0x78, 0x61, 0x6D, 0x70, 0x6C, 0x65, 0x73, 0x2E,
|
||||
|
||||
// stanza-create command
|
||||
// -------------------------------------------------------------------------------------------------------------------------
|
||||
@ -4184,11 +4190,18 @@ static const unsigned char helpDataPack[] =
|
||||
0x5C, 0x01, // Command restore override begin
|
||||
0x79, 0x10, // Summary
|
||||
0x52, 0x65, 0x63, 0x6F, 0x76, 0x65, 0x72, 0x79, 0x20, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x2E,
|
||||
0x78, 0x3E, // Description
|
||||
0x78, 0xB7, 0x01, // Description
|
||||
0x44, 0x65, 0x66, 0x69, 0x6E, 0x65, 0x73, 0x20, 0x74, 0x68, 0x65, 0x20, 0x72, 0x65, 0x63, 0x6F, 0x76, 0x65,
|
||||
0x72, 0x79, 0x20, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x20, 0x77, 0x68, 0x65, 0x6E, 0x20, 0x2D, 0x2D, 0x74,
|
||||
0x79, 0x70, 0x65, 0x20, 0x69, 0x73, 0x20, 0x6E, 0x61, 0x6D, 0x65, 0x2C, 0x20, 0x78, 0x69, 0x64, 0x2C, 0x20,
|
||||
0x6F, 0x72, 0x20, 0x74, 0x69, 0x6D, 0x65, 0x2E,
|
||||
0x6F, 0x72, 0x20, 0x74, 0x69, 0x6D, 0x65, 0x2E, 0x20, 0x49, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x74, 0x61,
|
||||
0x72, 0x67, 0x65, 0x74, 0x20, 0x69, 0x73, 0x20, 0x70, 0x72, 0x69, 0x6F, 0x72, 0x20, 0x74, 0x6F, 0x20, 0x74,
|
||||
0x68, 0x65, 0x20, 0x6C, 0x61, 0x74, 0x65, 0x73, 0x74, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x61,
|
||||
0x6E, 0x64, 0x20, 0x2D, 0x2D, 0x74, 0x79, 0x70, 0x65, 0x20, 0x69, 0x73, 0x20, 0x6E, 0x6F, 0x74, 0x20, 0x74,
|
||||
0x69, 0x6D, 0x65, 0x2C, 0x20, 0x74, 0x68, 0x65, 0x6E, 0x20, 0x75, 0x73, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20,
|
||||
0x2D, 0x2D, 0x73, 0x65, 0x74, 0x20, 0x6F, 0x70, 0x74, 0x69, 0x6F, 0x6E, 0x20, 0x74, 0x6F, 0x20, 0x73, 0x70,
|
||||
0x65, 0x63, 0x69, 0x66, 0x79, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x61, 0x63, 0x6B, 0x75, 0x70, 0x20, 0x73,
|
||||
0x65, 0x74, 0x2E,
|
||||
0x00, // Command restore override end
|
||||
|
||||
0x00, // Command overrides end
|
||||
|
@ -173,12 +173,13 @@ testRun(void)
|
||||
"specific repository, the --repo option can be passed (e.g. --repo=1). The --set\n"
|
||||
"option can be passed if a backup other than the latest is desired.\n"
|
||||
"\n"
|
||||
"For PITR, --type=time must be provided and the target time specified with the\n"
|
||||
"--target option. If a backup is not specified via the --set option, then the\n"
|
||||
"configured repositories will be checked, in order, for a backup that contains\n"
|
||||
"the requested time. If no backup can be found, the latest backup from the first\n"
|
||||
"repository containing backups will be used. See Point-in-Time Recovery for more\n"
|
||||
"details and examples.\n"
|
||||
"When PITR of --type=time is specified, then the target time must be specified\n"
|
||||
"with the --target option. If a backup is not specified via the --set option,\n"
|
||||
"then the configured repositories will be checked, in order, for a backup that\n"
|
||||
"contains the requested time. If no backup can be found, the latest backup from\n"
|
||||
"the first repository containing backups will be used. For other types of PITR,\n"
|
||||
"e.g. xid, the --set option must be provided if the target is prior to the\n"
|
||||
"latest backup. See Point-in-Time Recovery for more details and examples.\n"
|
||||
"\n"
|
||||
"Command Options:\n"
|
||||
"\n"
|
||||
|
Loading…
x
Reference in New Issue
Block a user