mirror of
https://github.com/postgres/postgres.git
synced 2025-09-02 04:21:28 +03:00
Add option to include WAL in base backup
When included, this makes the base backup a complete working "clone" of the initial database, ready to have a postmaster started against it without the need to set up any log archiving or similar. Magnus Hagander, reviewed by Fujii Masao and Heikki Linnakangas
This commit is contained in:
@@ -71,6 +71,7 @@ Node *replication_parse_result;
|
||||
%token K_LABEL
|
||||
%token K_PROGRESS
|
||||
%token K_FAST
|
||||
%token K_WAL
|
||||
%token K_START_REPLICATION
|
||||
|
||||
%type <node> command
|
||||
@@ -106,7 +107,7 @@ identify_system:
|
||||
;
|
||||
|
||||
/*
|
||||
* BASE_BACKUP [LABEL <label>] [PROGRESS] [FAST]
|
||||
* BASE_BACKUP [LABEL '<label>'] [PROGRESS] [FAST] [WAL]
|
||||
*/
|
||||
base_backup:
|
||||
K_BASE_BACKUP base_backup_opt_list
|
||||
@@ -136,7 +137,12 @@ base_backup_opt:
|
||||
$$ = makeDefElem("fast",
|
||||
(Node *)makeInteger(TRUE));
|
||||
}
|
||||
|
||||
| K_WAL
|
||||
{
|
||||
$$ = makeDefElem("wal",
|
||||
(Node *)makeInteger(TRUE));
|
||||
}
|
||||
;
|
||||
|
||||
/*
|
||||
* START_REPLICATION %X/%X
|
||||
|
Reference in New Issue
Block a user