1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2024-12-12 10:04:14 +02:00

Remove integration expect log testing.

Integration expect log testing was originally used as a rough-and-ready way to make sure that certain code paths were being executed before the unit tests existed. Now that we have 100% unit test coverage (with expect log testing) the value of the integration expect tests seems minimal at best.

But they do cause numerous issues:

- Maintenance of the expect code and replacements that are required to keep logs reproducible.
- Even a trivial change can cause massive churn in the expect logs, e.g. d9088b2. These changes should be minutely audited but since the expect logs have little value now it is seldom worth the effort.
- The OS version used to do expect testing (RHEL7) can only be used to test one version of PostgreSQL. This makes it hard to balance the PostgreSQL version testing between OS versions.
- When a commit affects expect logs it is not clear (especially for new developers) how to regenerate them and our contributing guide is silent on the issue.

The goal is to migrate the integration tests to C and expect testing is not part of that plan. It seems best to get rid of them now.
This commit is contained in:
David Steele 2022-05-10 13:18:26 -04:00 committed by GitHub
parent 3a40394472
commit de816a0f57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
34 changed files with 84 additions and 14101 deletions

View File

@ -404,6 +404,21 @@
</release-item>
</release-improvement-list>
</release-doc-list>
<release-test-list>
<release-development-list>
<release-item>
<github-pull-request id="1745"/>
<release-item-contributor-list>
<release-item-contributor id="david.steele"/>
<release-item-reviewer id="reid.thompson"/>
</release-item-contributor-list>
<p>Remove integration expect log testing.</p>
</release-item>
</release-development-list>
</release-test-list>
</release>
<release date="2022-03-06" version="2.38" title="Minor Bug Fixes and Improvements">

View File

@ -1859,10 +1859,6 @@ test/lib/pgBackRestTest/Common/ListTest.pm:
class: test/harness
type: perl
test/lib/pgBackRestTest/Common/LogTest.pm:
class: test/harness
type: perl
test/lib/pgBackRestTest/Common/RunTest.pm:
class: test/harness
type: perl

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,205 +0,0 @@
run 001 - rmt 0, tls 0, storage posix, enc 1, cmp lz4
=====================================================
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 ERROR: [103]: unable to find a valid repository:
repo1: [FileMissingError] unable to load info file '[TEST_PATH]/db-primary/repo/archive/db/archive.info' or '[TEST_PATH]/db-primary/repo/archive/db/archive.info.copy':
FileMissingError: unable to open missing file '[TEST_PATH]/db-primary/repo/archive/db/archive.info' for read
FileMissingError: unable to open missing file '[TEST_PATH]/db-primary/repo/archive/db/archive.info.copy' for read
HINT: archive.info cannot be opened but is required to push/get WAL segments.
HINT: is archive_command configured correctly in postgresql.conf?
HINT: has a stanza-create been performed?
HINT: use --no-archive-check to disable archive checks during backup if you have an alternate archiving scheme.
P00 INFO: archive-push command end: aborted with exception [103]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 WARN: repo1: [FileMissingError] unable to load info file '[TEST_PATH]/db-primary/repo/archive/db/archive.info' or '[TEST_PATH]/db-primary/repo/archive/db/archive.info.copy':
FileMissingError: unable to open missing file '[TEST_PATH]/db-primary/repo/archive/db/archive.info' for read
FileMissingError: unable to open missing file '[TEST_PATH]/db-primary/repo/archive/db/archive.info.copy' for read
HINT: archive.info cannot be opened but is required to push/get WAL segments.
HINT: is archive_command configured correctly in postgresql.conf?
HINT: has a stanza-create been performed?
HINT: use --no-archive-check to disable archive checks during backup if you have an alternate archiving scheme.
P00 ERROR: [103]: unable to find a valid repository
P00 INFO: archive-get command end: aborted with exception [103]
stanza-create db - stanza create (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 INFO: stanza-create command end: completed successfully
+ supplemental file: [TEST_PATH]/db-primary/repo/backup/db/backup.info
----------------------------------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201409291
db-control-version=942
db-id=1
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: [TEST_PATH]/db-primary/repo/archive/db/archive.info
------------------------------------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=1
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push --compress-type=lz4 [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=lz4 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 INFO: pushed WAL file '000000010000000100000001' to the archive
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 700000007000000070000000 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [700000007000000070000000, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 INFO: unable to find 700000007000000070000000 in the archive
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 INFO: found 000000010000000100000001 in the repo1: 9.4-1 archive
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push --compress-type=lz4 --archive-async --process-max=2 [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --archive-async --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=lz4 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --process-max=2 --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: pushed WAL file '000000010000000100000002' to the archive asynchronously
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push --archive-async [TEST_PATH]/db-primary/db/base/pg_xlog/00000002.history
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/00000002.history] --archive-async --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: pushed WAL file '00000002.history' to the archive asynchronously
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 WARN: repo1: [ArchiveMismatchError] unable to retrieve the archive id for database version '9.4' and system-id '1000000000000000094'
P00 ERROR: [103]: unable to find a valid repository
P00 INFO: archive-get command end: aborted with exception [103]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 ERROR: [103]: unable to find a valid repository:
repo1: [ArchiveMismatchError] PostgreSQL version 9.4, system-id 1000000000000000094 do not match repo1 stanza version 9.4, system-id 5000900090001855000
HINT: are you archiving to the correct stanza?
P00 INFO: archive-push command end: aborted with exception [103]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 WARN: repo1: [ArchiveMismatchError] unable to retrieve the archive id for database version '9.4' and system-id '1000000000000000094'
P00 ERROR: [103]: unable to find a valid repository
P00 INFO: archive-get command end: aborted with exception [103]
stop db stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db stop
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stop command begin [BACKREST-VERSION]: --config=[TEST_PATH]/db-primary/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log --no-log-timestamp --stanza=db
P00 INFO: stop command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 ERROR: [062]: stop file exists for stanza db
P00 INFO: archive-push command end: aborted with exception [062]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 ERROR: [062]: stop file exists for stanza db
P00 INFO: archive-get command end: aborted with exception [062]
start db stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db start
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: start command begin [BACKREST-VERSION]: --config=[TEST_PATH]/db-primary/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log --no-log-timestamp --stanza=db
P00 INFO: start command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 WARN: WAL file '000000010000000100000002' already exists in the repo1 archive with the same checksum
HINT: this is valid in some recovery scenarios but may also indicate a problem.
P00 INFO: pushed WAL file '000000010000000100000002' to the archive
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 ERROR: [045]: WAL file '000000010000000100000002' already exists in the repo1 archive with a different checksum
P00 INFO: archive-push command end: aborted with exception [045]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get --archive-async --repo-type=cifs 000000010000000100000002 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000002, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --archive-async --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --repo1-type=cifs --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: found 000000010000000100000002 in the archive asynchronously
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get --archive-async 00000001.history [TEST_PATH]/db-primary/db/base/pg_xlog/00000001.history
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [00000001.history, [TEST_PATH]/db-primary/db/base/pg_xlog/00000001.history] --archive-async --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: unable to find 00000001.history in the archive
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get --archive-async 00000002.history [TEST_PATH]/db-primary/db/base/pg_xlog/00000002.history
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [00000002.history, [TEST_PATH]/db-primary/db/base/pg_xlog/00000002.history] --archive-async --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: found 00000002.history in the repo1: 9.4-1 archive
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 INFO: pushed WAL file '000000010000000100000002.partial' to the archive
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 WARN: WAL file '000000010000000100000002.partial' already exists in the repo1 archive with the same checksum
HINT: this is valid in some recovery scenarios but may also indicate a problem.
P00 INFO: pushed WAL file '000000010000000100000002.partial' to the archive
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=[TEST_PATH]/db-primary/repo --stanza=db
P00 ERROR: [045]: WAL file '000000010000000100000002.partial' already exists in the repo1 archive with a different checksum
P00 INFO: archive-push command end: aborted with exception [045]

View File

@ -1,216 +0,0 @@
run 002 - rmt 1, tls 1, storage s3, enc 0, cmp zst
==================================================
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 ERROR: [103]: unable to find a valid repository:
repo1: [FileMissingError] unable to load info file '/archive/db/archive.info' or '/archive/db/archive.info.copy':
FileMissingError: raised from remote-0 tls protocol on 'backup': unable to open missing file '/archive/db/archive.info' for read
FileMissingError: raised from remote-0 tls protocol on 'backup': unable to open missing file '/archive/db/archive.info.copy' for read
HINT: archive.info cannot be opened but is required to push/get WAL segments.
HINT: is archive_command configured correctly in postgresql.conf?
HINT: has a stanza-create been performed?
HINT: use --no-archive-check to disable archive checks during backup if you have an alternate archiving scheme.
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: aborted with exception [103]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 WARN: repo1: [FileMissingError] unable to load info file '/archive/db/archive.info' or '/archive/db/archive.info.copy':
FileMissingError: raised from remote-0 tls protocol on 'backup': unable to open missing file '/archive/db/archive.info' for read
FileMissingError: raised from remote-0 tls protocol on 'backup': unable to open missing file '/archive/db/archive.info.copy' for read
HINT: archive.info cannot be opened but is required to push/get WAL segments.
HINT: is archive_command configured correctly in postgresql.conf?
HINT: has a stanza-create been performed?
HINT: use --no-archive-check to disable archive checks during backup if you have an alternate archiving scheme.
P00 ERROR: [103]: unable to find a valid repository
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: aborted with exception [103]
stanza-create db - stanza create (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-path=/ --repo1-s3-bucket=pgbackrest-dev --repo1-s3-endpoint=s3.amazonaws.com --repo1-s3-key=<redacted> --repo1-s3-key-secret=<redacted> --repo1-s3-region=us-east-1 --no-repo1-storage-verify-tls --repo1-type=s3 --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-catalog-version=201409291
db-control-version=942
db-id=1
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=1
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push --cmd-ssh=/usr/bin/ssh --compress-type=zst [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001] --buffer-size=[BUFFER-SIZE] --cmd-ssh=/usr/bin/ssh --compress-level=3 --compress-level-network=1 --compress-type=zst --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: pushed WAL file '000000010000000100000001' to the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 700000007000000070000000 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [700000007000000070000000, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: unable to find 700000007000000070000000 in the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: found 000000010000000100000001 in the repo1: 9.4-1 archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push --compress-type=zst --archive-async --process-max=2 [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --archive-async --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=zst --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --process-max=2 --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: pushed WAL file '000000010000000100000002' to the archive asynchronously
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push --archive-async [TEST_PATH]/db-primary/db/base/pg_xlog/00000002.history
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/00000002.history] --archive-async --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: pushed WAL file '00000002.history' to the archive asynchronously
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 WARN: repo1: [ArchiveMismatchError] unable to retrieve the archive id for database version '9.4' and system-id '1000000000000000094'
P00 ERROR: [103]: unable to find a valid repository
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: aborted with exception [103]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 ERROR: [103]: unable to find a valid repository:
repo1: [ArchiveMismatchError] PostgreSQL version 9.4, system-id 1000000000000000094 do not match repo1 stanza version 9.4, system-id 5000900090001855000
HINT: are you archiving to the correct stanza?
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: aborted with exception [103]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 WARN: repo1: [ArchiveMismatchError] unable to retrieve the archive id for database version '9.4' and system-id '1000000000000000094'
P00 ERROR: [103]: unable to find a valid repository
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: aborted with exception [103]
stop db stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db stop
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stop command begin [BACKREST-VERSION]: --config=[TEST_PATH]/db-primary/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log --no-log-timestamp --stanza=db
P00 INFO: stop command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 ERROR: [062]: stop file exists for stanza db
P00 INFO: archive-push command end: aborted with exception [062]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000001 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000001, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 ERROR: [062]: stop file exists for stanza db
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: aborted with exception [062]
start db stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db start
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: start command begin [BACKREST-VERSION]: --config=[TEST_PATH]/db-primary/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log --no-log-timestamp --stanza=db
P00 INFO: start command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 WARN: WAL file '000000010000000100000002' already exists in the repo1 archive with the same checksum
HINT: this is valid in some recovery scenarios but may also indicate a problem.
P00 INFO: pushed WAL file '000000010000000100000002' to the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 ERROR: [045]: WAL file '000000010000000100000002' already exists in the repo1 archive with a different checksum
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: aborted with exception [045]
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get --cmd-ssh=/usr/bin/ssh --archive-async 000000010000000100000002 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000002, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --archive-async --buffer-size=[BUFFER-SIZE] --cmd-ssh=/usr/bin/ssh --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: found 000000010000000100000002 in the archive asynchronously
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get --archive-async 00000001.history [TEST_PATH]/db-primary/db/base/pg_xlog/00000001.history
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [00000001.history, [TEST_PATH]/db-primary/db/base/pg_xlog/00000001.history] --archive-async --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: unable to find 00000001.history in the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get --archive-async 00000002.history [TEST_PATH]/db-primary/db/base/pg_xlog/00000002.history
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [00000002.history, [TEST_PATH]/db-primary/db/base/pg_xlog/00000002.history] --archive-async --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --spool-path=[TEST_PATH]/db-primary/spool --stanza=db
P00 INFO: found 00000002.history in the repo1: 9.4-1 archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: pushed WAL file '000000010000000100000002.partial' to the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 WARN: WAL file '000000010000000100000002.partial' already exists in the repo1 archive with the same checksum
HINT: this is valid in some recovery scenarios but may also indicate a problem.
P00 INFO: pushed WAL file '000000010000000100000002.partial' to the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002.partial] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=none --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 ERROR: [045]: WAL file '000000010000000100000002.partial' already exists in the repo1 archive with a different checksum
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: aborted with exception [045]

View File

@ -1,74 +0,0 @@
run 001 - rmt 0, tls 0, cmp bz2, error version, storage gcs, enc 1
==================================================================
stanza-create db - create required data for stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201409291
db-control-version=942
db-id=1
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=1
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 ERROR: [103]: unable to find a valid repository:
repo1: [ArchiveMismatchError] PostgreSQL version 9.4, system-id 1000000000000000094 do not match repo1 stanza version 8.0, system-id 1000000000000000094
HINT: are you archiving to the correct stanza?
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000003
------------------------------------------------------------------------------------------------------------------------------------
P00 ERROR: [103]: unable to find a valid repository:
repo1: [ArchiveMismatchError] PostgreSQL version 9.4, system-id 1000000000000000094 do not match repo1 stanza version 8.0, system-id 1000000000000000094
HINT: are you archiving to the correct stanza?
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000004 --repo1-host=bogus
------------------------------------------------------------------------------------------------------------------------------------
P00 WARN: dropped WAL file '000000010000000100000004' because archive queue exceeded 32MB
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000005
------------------------------------------------------------------------------------------------------------------------------------

View File

@ -1,66 +0,0 @@
run 002 - rmt 1, tls 0, cmp lz4, error connect, storage azure, enc 0
====================================================================
stanza-create db - create required data for stanza (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-path=/ --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-catalog-version=201409291
db-control-version=942
db-id=1
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=1
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002 --repo1-host=bogus
------------------------------------------------------------------------------------------------------------------------------------
P00 ERROR: [103]: unable to find a valid repository:
repo1: [UnknownError] remote-0 process on 'bogus' terminated unexpectedly [255]: ssh: Could not resolve hostname bogus: Name or service not known
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000003 --repo1-host=bogus
------------------------------------------------------------------------------------------------------------------------------------
P00 ERROR: [103]: unable to find a valid repository:
repo1: [UnknownError] remote-0 process on 'bogus' terminated unexpectedly [255]: ssh: Could not resolve hostname bogus: Name or service not known
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000004 --repo1-host=bogus
------------------------------------------------------------------------------------------------------------------------------------
P00 WARN: dropped WAL file '000000010000000100000004' because archive queue exceeded 32MB
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000005
------------------------------------------------------------------------------------------------------------------------------------

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,560 +0,0 @@
run 001 - remote 0, tls 0, storage gcs, enc 0, cmp zst
======================================================
stanza-create db - fail on missing control file (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online --log-level-file=[LOG-LEVEL-FILE] stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 ERROR: [055]: unable to open missing file '[TEST_PATH]/db-primary/db/base/global/pg_control' for read
P00 INFO: stanza-create command end: aborted with exception [055]
stanza-upgrade db - fail on stanza not initialized since archive.info is missing (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 ERROR: [055]: unable to load info file '/archive/db/archive.info' or '/archive/db/archive.info.copy':
FileMissingError: unable to open missing file '/archive/db/archive.info' for read
FileMissingError: unable to open missing file '/archive/db/archive.info.copy' for read
HINT: archive.info cannot be opened but is required to push/get WAL segments.
HINT: is archive_command configured correctly in postgresql.conf?
HINT: has a stanza-create been performed?
HINT: use --no-archive-check to disable archive checks during backup if you have an alternate archiving scheme.
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: aborted with exception [055]
stanza-create db - successfully create the stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
stanza-create db - do not fail on rerun of stanza-create - info files exist and DB section ok (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 INFO: stanza 'db' already exists on repo1 and is valid
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
stanza-create db - fail on database mismatch and warn force option deprecated (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online --force stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --force --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 WARN: option --force is no longer supported
P00 INFO: stanza-create for stanza 'db' on repo1
P00 ERROR: [028]: backup and archive info files exist but do not match the database
HINT: is this the correct stanza?
HINT: did an error occur during stanza-upgrade?
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: aborted with exception [028]
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
stanza-upgrade db - already up to date (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 INFO: stanza 'db' on repo1 is already up to date
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=zst --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: pushed WAL file '000000010000000100000001' to the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: completed successfully
stanza-create db - fail on archive info file missing from non-empty dir (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 ERROR: [055]: backup.info exists but archive.info is missing on repo1
HINT: this may be a symptom of repository corruption!
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: aborted with exception [055]
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=zst --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: pushed WAL file '000000010000000100000002' to the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
P00 ERROR: [103]: unable to find a valid repository:
repo1: [ArchiveMismatchError] PostgreSQL version 9.4, system-id 1000000000000000094 do not match repo1 stanza version 9.3, system-id 1000000000000000093
HINT: are you archiving to the correct stanza?
stanza-upgrade db - successful upgrade creates additional history (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-catalog-version=201409291
db-control-version=942
db-id=2
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
2={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=2
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
2={"db-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000002 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000002, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: found 000000010000000100000002 in the repo1: 9.3-1 archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
full backup - create first full backup (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo1-retention-full=2 --no-online --type=full --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: backup command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=zst --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --repo1-retention-full=2 --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db --start-fast --type=full
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG (16MB, 33.32%) checksum 51a8525d254c01f5edddda30b7fe697c7e44705c
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002 (16MB, 66.65%) checksum 51a8525d254c01f5edddda30b7fe697c7e44705c
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001 (16MB, 99.98%) checksum f92539dea1f9482e2946c1138eeeecdea29d7f19
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/global/pg_control (8KB, 100.00%) checksum 4c77c900f7af0d9ab13fa9982051a42e0b637f6c
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/archive_status/000000010000000100000002.ready (0B, 100.00%)
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/archive_status/000000010000000100000001.ready (0B, 100.00%)
P00 INFO: new backup label = [BACKUP-FULL-1]
P00 INFO: full backup size = 48MB, file total = 6
P00 DETAIL: statistics: STATISTICS
P00 INFO: backup command end: completed successfully
P00 INFO: expire command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log --no-log-timestamp --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --repo1-retention-full=2 --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 DETAIL: statistics: STATISTICS
P00 INFO: expire command end: completed successfully
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-type=zst
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-gcs-bucket=gcsbucket
repo1-gcs-endpoint=gcs:4443
repo1-gcs-key=testkey
repo1-gcs-key-type=token
repo1-path=/
repo1-storage-verify-tls=n
repo1-type=gcs
spool-path=[TEST_PATH]/db-primary/spool
[global:backup]
archive-copy=y
start-fast=y
stanza-upgrade db - successfully upgrade (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[backup:current]
[BACKUP-FULL-1]={"backrest-format":5,"backrest-version":"[VERSION-1]","backup-archive-start":null,"backup-archive-stop":null,"backup-error":false,"backup-info-repo-size":[SIZE],"backup-info-repo-size-delta":[DELTA],"backup-info-size":[SIZE],"backup-info-size-delta":[DELTA],"backup-timestamp-start":[TIMESTAMP],"backup-timestamp-stop":[TIMESTAMP],"backup-type":"full","db-id":2,"option-archive-check":false,"option-archive-copy":false,"option-backup-standby":false,"option-checksum-page":false,"option-compress":true,"option-hardlink":false,"option-online":false}
[db]
db-catalog-version=201510051
db-control-version=942
db-id=3
db-system-id=1000000000000000095
db-version="9.5"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
2={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
3={"db-catalog-version":201510051,"db-control-version":942,"db-system-id":1000000000000000095,"db-version":"9.5"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=3
db-system-id=1000000000000000095
db-version="9.5"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
2={"db-id":1000000000000000094,"db-version":"9.4"}
3={"db-id":1000000000000000095,"db-version":"9.5"}
[backrest]
backrest-checksum="[CHECKSUM]"
stanza-upgrade db - upgrade fails with mismatched db-ids (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 ERROR: [028]: backup info file and archive info file do not match
archive: id = 2, version = 9.5, system-id = 1000000000000000095
backup : id = 3, version = 9.5, system-id = 1000000000000000095
HINT: this may be a symptom of repository corruption!
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: aborted with exception [028]
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[backup:current]
[BACKUP-FULL-1]={"backrest-format":5,"backrest-version":"[VERSION-1]","backup-archive-start":null,"backup-archive-stop":null,"backup-error":false,"backup-info-repo-size":[SIZE],"backup-info-repo-size-delta":[DELTA],"backup-info-size":[SIZE],"backup-info-size-delta":[DELTA],"backup-timestamp-start":[TIMESTAMP],"backup-timestamp-stop":[TIMESTAMP],"backup-type":"full","db-id":2,"option-archive-check":false,"option-archive-copy":false,"option-backup-standby":false,"option-checksum-page":false,"option-compress":true,"option-hardlink":false,"option-online":false}
[db]
db-catalog-version=201510051
db-control-version=942
db-id=3
db-system-id=1000000000000000095
db-version="9.5"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
2={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
3={"db-catalog-version":201510051,"db-control-version":942,"db-system-id":1000000000000000095,"db-version":"9.5"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
diff backup - diff changed to full backup (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo1-retention-full=2 --no-online --type=diff --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: backup command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-type=zst --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --repo1-retention-full=2 --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db --start-fast --type=diff
P00 WARN: no prior backup exists, diff backup has been changed to full
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG (16MB, 33.32%) checksum 51a8525d254c01f5edddda30b7fe697c7e44705c
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002 (16MB, 66.65%) checksum 51a8525d254c01f5edddda30b7fe697c7e44705c
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001 (16MB, 99.98%) checksum 762dae884fdccb805c5f3283662ea0f8da55f228
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/global/pg_control (8KB, 100.00%) checksum 4969435f3b36bfaa0f5a486bef97f1988a135520
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/archive_status/000000010000000100000002.ready (0B, 100.00%)
P01 DETAIL: backup file [TEST_PATH]/db-primary/db/base/pg_xlog/archive_status/000000010000000100000001.ready (0B, 100.00%)
P00 INFO: new backup label = [BACKUP-FULL-2]
P00 INFO: full backup size = 48MB, file total = 6
P00 DETAIL: statistics: STATISTICS
P00 INFO: backup command end: completed successfully
P00 INFO: expire command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log --no-log-timestamp --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --repo1-retention-full=2 --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 INFO: repo1: remove archive path /archive/db/9.3-1
P00 DETAIL: statistics: STATISTICS
P00 INFO: expire command end: completed successfully
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-type=zst
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-gcs-bucket=gcsbucket
repo1-gcs-endpoint=gcs:4443
repo1-gcs-key=testkey
repo1-gcs-key-type=token
repo1-path=/
repo1-storage-verify-tls=n
repo1-type=gcs
spool-path=[TEST_PATH]/db-primary/spool
[global:backup]
archive-copy=y
start-fast=y
stanza-delete db - fail on missing stop file (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=1 --stanza=db stanza-delete
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-delete command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo=1 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 ERROR: [055]: stop file does not exist for stanza 'db'
HINT: has the pgbackrest stop command been run on this server for this stanza?
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-delete command end: aborted with exception [055]
db must not exist for successful delete
> list backup
------------------------------------------------------------------------------------------------------------------------------------
db
db must not exist for successful delete
> list archive
------------------------------------------------------------------------------------------------------------------------------------
db
stop db stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db stop
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stop command begin [BACKREST-VERSION]: --config=[TEST_PATH]/db-primary/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log --no-log-timestamp --stanza=db
P00 INFO: stop command end: completed successfully
stanza-delete db - successfully delete the stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=1 --stanza=db stanza-delete
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-delete command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo=1 --repo1-gcs-bucket=gcsbucket --repo1-gcs-endpoint=gcs:4443 --repo1-gcs-key=<redacted> --repo1-gcs-key-type=token --repo1-path=/ --no-repo1-storage-verify-tls --repo1-type=gcs --stanza=db
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-delete command end: completed successfully
db must not exist for successful delete
> list backup
------------------------------------------------------------------------------------------------------------------------------------
db must not exist for successful delete
> list archive
------------------------------------------------------------------------------------------------------------------------------------

View File

@ -1,652 +0,0 @@
run 002 - remote 1, tls 1, storage azure, enc 1, cmp lz4
========================================================
stanza-create db - fail on missing control file (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db --no-online --log-level-file=[LOG-LEVEL-FILE] stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 ERROR: [055]: raised from remote-0 tls protocol on 'db-primary': unable to open missing file '[TEST_PATH]/db-primary/db/base/global/pg_control' for read
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: aborted with exception [055]
stanza-upgrade db - fail on stanza not initialized since archive.info is missing (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 ERROR: [055]: unable to load info file '/archive/db/archive.info' or '/archive/db/archive.info.copy':
FileMissingError: unable to open missing file '/archive/db/archive.info' for read
FileMissingError: unable to open missing file '/archive/db/archive.info.copy' for read
HINT: archive.info cannot be opened but is required to push/get WAL segments.
HINT: is archive_command configured correctly in postgresql.conf?
HINT: has a stanza-create been performed?
HINT: use --no-archive-check to disable archive checks during backup if you have an alternate archiving scheme.
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: aborted with exception [055]
stanza-create db - successfully create the stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
stanza-create db - do not fail on rerun of stanza-create - info files exist and DB section ok (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: stanza-create for stanza 'db' on repo1
P00 INFO: stanza 'db' already exists on repo1 and is valid
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
stanza-create db - fail on database mismatch and warn force option deprecated (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db --no-online --force stanza-create
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-create command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --force --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 WARN: option --force is no longer supported
P00 INFO: stanza-create for stanza 'db' on repo1
P00 ERROR: [028]: backup and archive info files exist but do not match the database
HINT: is this the correct stanza?
HINT: did an error occur during stanza-upgrade?
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-create command end: aborted with exception [028]
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
stanza-upgrade db - already up to date (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 INFO: stanza 'db' on repo1 is already up to date
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201306121
db-control-version=937
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=lz4 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: pushed WAL file '000000010000000100000001' to the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-push command begin [BACKREST-VERSION]: [[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002] --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=lz4 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: pushed WAL file '000000010000000100000002' to the archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-push command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
P00 ERROR: [103]: unable to find a valid repository:
repo1: [ArchiveMismatchError] PostgreSQL version 9.4, system-id 1000000000000000094 do not match repo1 stanza version 9.3, system-id 1000000000000000093
HINT: are you archiving to the correct stanza?
stanza-upgrade db - successful upgrade creates additional history (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201409291
db-control-version=942
db-id=2
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
2={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=2
db-system-id=1000000000000000094
db-version="9.4"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
2={"db-id":1000000000000000094,"db-version":"9.4"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get 000000010000000100000002 [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: archive-get command begin [BACKREST-VERSION]: [000000010000000100000002, [TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG] --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: found 000000010000000100000002 in the repo1: 9.3-1 archive
P00 DETAIL: statistics: STATISTICS
P00 INFO: archive-get command end: completed successfully
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
full backup - create first full backup (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --repo1-retention-full=2 --no-online --type=full --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: backup command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=lz4 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-retention-full=2 --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db --start-fast --type=full
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG (16MB, 33.32%) checksum 51a8525d254c01f5edddda30b7fe697c7e44705c
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002 (16MB, 66.65%) checksum 51a8525d254c01f5edddda30b7fe697c7e44705c
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001 (16MB, 99.98%) checksum f92539dea1f9482e2946c1138eeeecdea29d7f19
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/global/pg_control (8KB, 100.00%) checksum 4c77c900f7af0d9ab13fa9982051a42e0b637f6c
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/archive_status/000000010000000100000002.ready (0B, 100.00%)
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/archive_status/000000010000000100000001.ready (0B, 100.00%)
P00 INFO: new backup label = [BACKUP-FULL-1]
P00 INFO: full backup size = 48MB, file total = 6
P00 DETAIL: statistics: STATISTICS
P00 INFO: backup command end: completed successfully
P00 INFO: expire command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/backup/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log --no-log-timestamp --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-retention-full=2 --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 DETAIL: statistics: STATISTICS
P00 INFO: expire command end: completed successfully
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=lz4
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-host=backup
repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key
repo1-host-type=tls
repo1-host-user=[USER-1]
spool-path=[TEST_PATH]/db-primary/spool
+ supplemental file: [TEST_PATH]/backup/pgbackrest.conf
-------------------------------------------------------
[db]
pg1-host=db-primary
pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt
pg1-host-cmd=[BACKREST-BIN]
pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf
pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key
pg1-host-type=tls
pg1-host-user=[USER-1]
pg1-path=[TEST_PATH]/db-primary/db/base
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=lz4
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/backup/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/backup/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-azure-account=azaccount
repo1-azure-container=azcontainer
repo1-azure-host=azure
repo1-azure-key=YXpLZXk=
repo1-azure-uri-style=path
repo1-azure-verify-tls=n
repo1-cipher-pass=x
repo1-cipher-type=aes-256-cbc
repo1-path=/
repo1-type=azure
[global:backup]
archive-copy=y
start-fast=y
stanza-upgrade db - successfully upgrade (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --no-online --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: completed successfully
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[backup:current]
[BACKUP-FULL-1]={"backrest-format":5,"backrest-version":"[VERSION-1]","backup-archive-start":null,"backup-archive-stop":null,"backup-error":false,"backup-info-repo-size":[SIZE],"backup-info-repo-size-delta":[DELTA],"backup-info-size":[SIZE],"backup-info-size-delta":[DELTA],"backup-timestamp-start":[TIMESTAMP],"backup-timestamp-stop":[TIMESTAMP],"backup-type":"full","db-id":2,"option-archive-check":false,"option-archive-copy":false,"option-backup-standby":false,"option-checksum-page":false,"option-compress":true,"option-hardlink":false,"option-online":false}
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201510051
db-control-version=942
db-id=3
db-system-id=1000000000000000095
db-version="9.5"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
2={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
3={"db-catalog-version":201510051,"db-control-version":942,"db-system-id":1000000000000000095,"db-version":"9.5"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=3
db-system-id=1000000000000000095
db-version="9.5"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
2={"db-id":1000000000000000094,"db-version":"9.4"}
3={"db-id":1000000000000000095,"db-version":"9.5"}
[backrest]
backrest-checksum="[CHECKSUM]"
stanza-upgrade db - upgrade fails with mismatched db-ids (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db --no-online stanza-upgrade
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-upgrade command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 INFO: stanza-upgrade for stanza 'db' on repo1
P00 ERROR: [028]: backup info file and archive info file do not match
archive: id = 2, version = 9.5, system-id = 1000000000000000095
backup : id = 3, version = 9.5, system-id = 1000000000000000095
HINT: this may be a symptom of repository corruption!
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-upgrade command end: aborted with exception [028]
+ supplemental file: /backup/db/backup.info
-------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[backup:current]
[BACKUP-FULL-1]={"backrest-format":5,"backrest-version":"[VERSION-1]","backup-archive-start":null,"backup-archive-stop":null,"backup-error":false,"backup-info-repo-size":[SIZE],"backup-info-repo-size-delta":[DELTA],"backup-info-size":[SIZE],"backup-info-size-delta":[DELTA],"backup-timestamp-start":[TIMESTAMP],"backup-timestamp-stop":[TIMESTAMP],"backup-type":"full","db-id":2,"option-archive-check":false,"option-archive-copy":false,"option-backup-standby":false,"option-checksum-page":false,"option-compress":true,"option-hardlink":false,"option-online":false}
[cipher]
cipher-pass=[CIPHER-PASS-1]
[db]
db-catalog-version=201510051
db-control-version=942
db-id=3
db-system-id=1000000000000000095
db-version="9.5"
[db:history]
1={"db-catalog-version":201306121,"db-control-version":937,"db-system-id":1000000000000000093,"db-version":"9.3"}
2={"db-catalog-version":201409291,"db-control-version":942,"db-system-id":1000000000000000094,"db-version":"9.4"}
3={"db-catalog-version":201510051,"db-control-version":942,"db-system-id":1000000000000000095,"db-version":"9.5"}
[backrest]
backrest-checksum="[CHECKSUM]"
+ supplemental file: /archive/db/archive.info
---------------------------------------------
[backrest]
backrest-format=5
backrest-version="[VERSION-1]"
[cipher]
cipher-pass=[CIPHER-PASS-2]
[db]
db-id=1
db-system-id=1000000000000000093
db-version="9.3"
[db:history]
1={"db-id":1000000000000000093,"db-version":"9.3"}
[backrest]
backrest-checksum="[CHECKSUM]"
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --log-level-console=warn --archive-push-queue-max=33554432 --stanza=db archive-push [TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001
------------------------------------------------------------------------------------------------------------------------------------
diff backup - diff changed to full backup (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --repo1-retention-full=2 --no-online --type=diff --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: backup command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level=3 --compress-level-network=1 --compress-type=lz4 --config=[TEST_PATH]/backup/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --job-retry=0 --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log[] --no-log-timestamp --no-online --pg1-host=db-primary --pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --pg1-host-cmd=[BACKREST-BIN] --pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf --pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --pg1-host-type=tls --pg1-host-user=[USER-1] --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-retention-full=2 --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db --start-fast --type=diff
P00 WARN: no prior backup exists, diff backup has been changed to full
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/RECOVERYXLOG (16MB, 33.32%) checksum 51a8525d254c01f5edddda30b7fe697c7e44705c
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000002 (16MB, 66.65%) checksum 51a8525d254c01f5edddda30b7fe697c7e44705c
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/000000010000000100000001 (16MB, 99.98%) checksum 762dae884fdccb805c5f3283662ea0f8da55f228
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/global/pg_control (8KB, 100.00%) checksum 4969435f3b36bfaa0f5a486bef97f1988a135520
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/archive_status/000000010000000100000002.ready (0B, 100.00%)
P01 DETAIL: backup file db-primary:[TEST_PATH]/db-primary/db/base/pg_xlog/archive_status/000000010000000100000001.ready (0B, 100.00%)
P00 INFO: new backup label = [BACKUP-FULL-2]
P00 INFO: full backup size = 48MB, file total = 6
P00 DETAIL: statistics: STATISTICS
P00 INFO: backup command end: completed successfully
P00 INFO: expire command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/backup/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/backup/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/backup/log --no-log-timestamp --repo1-azure-account=<redacted> --repo1-azure-container=azcontainer --repo1-azure-key=<redacted> --repo1-azure-uri-style=path --repo1-cipher-pass=<redacted> --repo1-cipher-type=aes-256-cbc --repo1-path=/ --repo1-retention-full=2 --repo1-storage-host=azure --no-repo1-storage-verify-tls --repo1-type=azure --stanza=db
P00 INFO: repo1: remove archive path /archive/db/9.3-1
P00 DETAIL: statistics: STATISTICS
P00 INFO: expire command end: completed successfully
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=lz4
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-host=backup
repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key
repo1-host-type=tls
repo1-host-user=[USER-1]
spool-path=[TEST_PATH]/db-primary/spool
+ supplemental file: [TEST_PATH]/backup/pgbackrest.conf
-------------------------------------------------------
[db]
pg1-host=db-primary
pg1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt
pg1-host-cmd=[BACKREST-BIN]
pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf
pg1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key
pg1-host-type=tls
pg1-host-user=[USER-1]
pg1-path=[TEST_PATH]/db-primary/db/base
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=lz4
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/backup/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/backup/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-azure-account=azaccount
repo1-azure-container=azcontainer
repo1-azure-host=azure
repo1-azure-key=YXpLZXk=
repo1-azure-uri-style=path
repo1-azure-verify-tls=n
repo1-cipher-pass=x
repo1-cipher-type=aes-256-cbc
repo1-path=/
repo1-type=azure
[global:backup]
archive-copy=y
start-fast=y
stanza-delete db - fail on missing stop file (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=1 --stanza=db stanza-delete
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-delete command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo=1 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 ERROR: [055]: stop file does not exist for stanza 'db'
HINT: has the pgbackrest stop command been run on this server for this stanza?
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-delete command end: aborted with exception [055]
db must not exist for successful delete
> list backup
------------------------------------------------------------------------------------------------------------------------------------
db
db must not exist for successful delete
> list archive
------------------------------------------------------------------------------------------------------------------------------------
db
stop db stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db stop
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stop command begin [BACKREST-VERSION]: --config=[TEST_PATH]/db-primary/pgbackrest.conf --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log --no-log-timestamp --stanza=db
P00 INFO: stop command end: completed successfully
stanza-delete db - successfully delete the stanza (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=1 --stanza=db stanza-delete
------------------------------------------------------------------------------------------------------------------------------------
P00 INFO: stanza-delete command begin [BACKREST-VERSION]: --buffer-size=[BUFFER-SIZE] --compress-level-network=1 --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-timeout=45 --exec-id=[EXEC-ID] --lock-path=[TEST_PATH]/db-primary/lock --log-level-console=detail --log-level-file=[LOG-LEVEL-FILE] --log-level-stderr=off --log-path=[TEST_PATH]/db-primary/log[] --no-log-timestamp --pg1-path=[TEST_PATH]/db-primary/db/base --protocol-timeout=60 --repo=1 --repo1-host=backup --repo1-host-cert-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.crt --repo1-host-cmd=[BACKREST-BIN] --repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf --repo1-host-key-file=[REPO_PATH]/test/certificate/pgbackrest-test-client.key --repo1-host-type=tls --repo1-host-user=[USER-1] --stanza=db
P00 DETAIL: statistics: STATISTICS
P00 INFO: stanza-delete command end: completed successfully
db must not exist for successful delete
> list backup
------------------------------------------------------------------------------------------------------------------------------------
db must not exist for successful delete
> list archive
------------------------------------------------------------------------------------------------------------------------------------

View File

@ -1,909 +0,0 @@
run 001 - bkp 1, sby 1, tls 0, dst backup, cmp none, storage posix, enc 0
=========================================================================
stanza-create db - main create stanza info files (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db stanza-create
------------------------------------------------------------------------------------------------------------------------------------
check db - verify check command runs successfully (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --archive-timeout=5 --stanza=db check
------------------------------------------------------------------------------------------------------------------------------------
check db - verify check command runs successfully (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --archive-timeout=5 --reset-pg2-host --reset-pg2-host-type --reset-pg2-host-cmd --reset-pg2-host-config --reset-pg2-host-user --reset-pg2-path --stanza=db check
------------------------------------------------------------------------------------------------------------------------------------
full backup - fail on backup lock exists (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --type=full --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
full backup - repo1 (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --buffer-size=[BUFFER-SIZE] --type=full --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg1-socket-path=[TEST_PATH]/db-primary/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-primary/spool
+ supplemental file: [TEST_PATH]/db-standby/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-standby/db/base
pg1-port=6544
pg1-socket-path=[TEST_PATH]/db-standby/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-standby/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-standby/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-standby/spool
+ supplemental file: [TEST_PATH]/backup/pgbackrest.conf
-------------------------------------------------------
[db]
pg1-host=db-primary
pg1-host-cmd=[BACKREST-BIN]
pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf
pg1-host-user=[USER-1]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg2-host=bogus
pg2-host-cmd=[BACKREST-BIN]
pg2-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg2-host-user=[USER-1]
pg2-path=[TEST_PATH]/db-standby/db/base
pg256-host=db-standby
pg256-host-cmd=[BACKREST-BIN]
pg256-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg256-host-user=[USER-1]
pg256-path=[TEST_PATH]/db-standby/db/base
pg256-port=6544
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/backup/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/backup/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-path=[TEST_PATH]/backup/repo
repo2-path=[TEST_PATH]/backup/repo2
[global:backup]
archive-copy=y
start-fast=y
full backup - repo2 (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --repo=2 --type=full --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg1-socket-path=[TEST_PATH]/db-primary/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-primary/spool
+ supplemental file: [TEST_PATH]/db-standby/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-standby/db/base
pg1-port=6544
pg1-socket-path=[TEST_PATH]/db-standby/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-standby/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-standby/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-standby/spool
+ supplemental file: [TEST_PATH]/backup/pgbackrest.conf
-------------------------------------------------------
[db]
pg1-host=db-primary
pg1-host-cmd=[BACKREST-BIN]
pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf
pg1-host-user=[USER-1]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg2-host=bogus
pg2-host-cmd=[BACKREST-BIN]
pg2-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg2-host-user=[USER-1]
pg2-path=[TEST_PATH]/db-standby/db/base
pg256-host=db-standby
pg256-host-cmd=[BACKREST-BIN]
pg256-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg256-host-user=[USER-1]
pg256-path=[TEST_PATH]/db-standby/db/base
pg256-port=6544
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/backup/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/backup/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-path=[TEST_PATH]/backup/repo
repo2-path=[TEST_PATH]/backup/repo2
[global:backup]
archive-copy=y
start-fast=y
full backup - with disabled expire-auto (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --repo1-retention-full=1 --no-expire-auto --type=full --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg1-socket-path=[TEST_PATH]/db-primary/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-primary/spool
+ supplemental file: [TEST_PATH]/db-standby/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-standby/db/base
pg1-port=6544
pg1-socket-path=[TEST_PATH]/db-standby/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-standby/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-standby/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-standby/spool
+ supplemental file: [TEST_PATH]/backup/pgbackrest.conf
-------------------------------------------------------
[db]
pg1-host=db-primary
pg1-host-cmd=[BACKREST-BIN]
pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf
pg1-host-user=[USER-1]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg2-host=bogus
pg2-host-cmd=[BACKREST-BIN]
pg2-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg2-host-user=[USER-1]
pg2-path=[TEST_PATH]/db-standby/db/base
pg256-host=db-standby
pg256-host-cmd=[BACKREST-BIN]
pg256-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg256-host-user=[USER-1]
pg256-path=[TEST_PATH]/db-standby/db/base
pg256-port=6544
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/backup/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/backup/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-path=[TEST_PATH]/backup/repo
repo2-path=[TEST_PATH]/backup/repo2
[global:backup]
archive-copy=y
start-fast=y
expire full=1 (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --repo1-retention-full=1 --repo=1 --stanza=db expire
------------------------------------------------------------------------------------------------------------------------------------
restore, type 'standby', remap - restore backup on replica (db-standby host)
> [CONTAINER-EXEC] db-standby [BACKREST-BIN] --config=[TEST_PATH]/db-standby/pgbackrest.conf --recovery-option="primary_conninfo=host=db-primary port=6543 user=replicator" --type=standby --link-map="pg_xlog=[TEST_PATH]/db-standby/db/pg_xlog" --link-all --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-standby/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
primary_conninfo = 'host=db-primary port=6543 user=replicator'
restore_command = '[BACKREST-BIN] --config=[TEST_PATH]/db-standby/pgbackrest.conf --stanza=db archive-get %f "%p"'
standby_mode = 'on'
full backup - backup from standby, failure to access at least one standby (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --pg256-host=bogus --backup-standby --type=full --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
full backup - backup from standby (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --repo1-retention-full=1 --backup-standby --type=full --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg1-socket-path=[TEST_PATH]/db-primary/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-primary/spool
+ supplemental file: [TEST_PATH]/db-standby/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-standby/db/base
pg1-port=6544
pg1-socket-path=[TEST_PATH]/db-standby/db
[db:restore]
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-standby/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-standby/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-standby/spool
+ supplemental file: [TEST_PATH]/backup/pgbackrest.conf
-------------------------------------------------------
[db]
pg1-host=db-primary
pg1-host-cmd=[BACKREST-BIN]
pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf
pg1-host-user=[USER-1]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg2-host=bogus
pg2-host-cmd=[BACKREST-BIN]
pg2-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg2-host-user=[USER-1]
pg2-path=[TEST_PATH]/db-standby/db/base
pg256-host=db-standby
pg256-host-cmd=[BACKREST-BIN]
pg256-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg256-host-user=[USER-1]
pg256-path=[TEST_PATH]/db-standby/db/base
pg256-port=6544
[global]
archive-async=y
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/backup/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/backup/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-path=[TEST_PATH]/backup/repo
repo2-path=[TEST_PATH]/backup/repo2
[global:backup]
archive-copy=y
start-fast=y
check db - verify check command on standby (db-standby host)
> [CONTAINER-EXEC] db-standby [BACKREST-BIN] --config=[TEST_PATH]/db-standby/pgbackrest.conf --reset-pg2-host --reset-pg2-host-type --reset-pg2-host-cmd --reset-pg2-host-config --reset-pg2-host-user --reset-pg2-path --stanza=db check
------------------------------------------------------------------------------------------------------------------------------------
diff backup - backup for adhoc expire (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --type=diff --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg1-socket-path=[TEST_PATH]/db-primary/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-primary/spool
+ supplemental file: [TEST_PATH]/db-standby/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-standby/db/base
pg1-port=6544
pg1-socket-path=[TEST_PATH]/db-standby/db
[db:restore]
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-standby/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-standby/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-standby/spool
+ supplemental file: [TEST_PATH]/backup/pgbackrest.conf
-------------------------------------------------------
[db]
pg1-host=db-primary
pg1-host-cmd=[BACKREST-BIN]
pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf
pg1-host-user=[USER-1]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg2-host=bogus
pg2-host-cmd=[BACKREST-BIN]
pg2-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg2-host-user=[USER-1]
pg2-path=[TEST_PATH]/db-standby/db/base
pg256-host=db-standby
pg256-host-cmd=[BACKREST-BIN]
pg256-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg256-host-user=[USER-1]
pg256-path=[TEST_PATH]/db-standby/db/base
pg256-port=6544
[global]
archive-async=y
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/backup/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/backup/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-path=[TEST_PATH]/backup/repo
repo2-path=[TEST_PATH]/backup/repo2
[global:backup]
archive-copy=y
start-fast=y
stop all stanzas (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf stop
------------------------------------------------------------------------------------------------------------------------------------
incr backup - attempt backup when stopped (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
start all stanzas (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf start
------------------------------------------------------------------------------------------------------------------------------------
incr backup - fail on archive_mode=always (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
expire --set=[BACKUP-DIFF-1] (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --set=[BACKUP-DIFF-1] --repo=1 --stanza=db expire
------------------------------------------------------------------------------------------------------------------------------------
incr backup - delta (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stop-auto --buffer-size=[BUFFER-SIZE] --delta --repo=2 --stanza=db backup
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg1-socket-path=[TEST_PATH]/db-primary/db
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-primary/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-primary/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-primary/spool
+ supplemental file: [TEST_PATH]/db-standby/pgbackrest.conf
-----------------------------------------------------------
[db]
pg1-path=[TEST_PATH]/db-standby/db/base
pg1-port=6544
pg1-socket-path=[TEST_PATH]/db-standby/db
[db:restore]
[global]
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/db-standby/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/db-standby/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-host=backup
repo1-host-cmd=[BACKREST-BIN]
repo1-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo1-host-user=[USER-1]
repo2-host=backup
repo2-host-cmd=[BACKREST-BIN]
repo2-host-config=[TEST_PATH]/backup/pgbackrest.conf
repo2-host-user=[USER-1]
spool-path=[TEST_PATH]/db-standby/spool
+ supplemental file: [TEST_PATH]/backup/pgbackrest.conf
-------------------------------------------------------
[db]
pg1-host=db-primary
pg1-host-cmd=[BACKREST-BIN]
pg1-host-config=[TEST_PATH]/db-primary/pgbackrest.conf
pg1-host-user=[USER-1]
pg1-path=[TEST_PATH]/db-primary/db/base
pg1-port=6543
pg2-host=bogus
pg2-host-cmd=[BACKREST-BIN]
pg2-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg2-host-user=[USER-1]
pg2-path=[TEST_PATH]/db-standby/db/base
pg256-host=db-standby
pg256-host-cmd=[BACKREST-BIN]
pg256-host-config=[TEST_PATH]/db-standby/pgbackrest.conf
pg256-host-user=[USER-1]
pg256-path=[TEST_PATH]/db-standby/db/base
pg256-port=6544
[global]
archive-async=y
buffer-size=[BUFFER-SIZE]
compress-level=3
compress-level-network=1
compress-type=none
db-timeout=45
job-retry=0
lock-path=[TEST_PATH]/backup/lock
log-level-console=detail
log-level-file=[LOG-LEVEL-FILE]
log-level-stderr=off
log-path=[TEST_PATH]/backup/log
log-subprocess=[LOG-SUBPROCESS]
log-timestamp=n
protocol-timeout=60
repo1-bundle=y
repo1-bundle-limit=64KiB
repo1-bundle-size=1MiB
repo1-path=[TEST_PATH]/backup/repo
repo2-path=[TEST_PATH]/backup/repo2
[global:backup]
archive-copy=y
start-fast=y
check db - check command with tablespace (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --archive-timeout=5 --reset-pg2-host --reset-pg2-host-type --reset-pg2-host-cmd --reset-pg2-host-config --reset-pg2-host-user --reset-pg2-path --stanza=db check
------------------------------------------------------------------------------------------------------------------------------------
restore, type 'default', expect exit 38 - pg running (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --link-all --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
restore, type 'default', expect exit 40 - path not empty (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --link-all --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
restore, type 'default' (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --db-include=test2 --db-include=test3 --buffer-size=[BUFFER-SIZE] --link-all --repo=2 --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
restore_command = '[BACKREST-BIN] --buffer-size=[BUFFER-SIZE] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=2 --stanza=db archive-get %f "%p"'
restore, force, backup '[BACKUP-FULL-1]', type 'immediate', target-action=promote (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --force --set=[BACKUP-FULL-1] --type=immediate --link-all --target-action=promote --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
restore_command = '[BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get %f "%p"'
recovery_target = 'immediate'
recovery_target_action = 'promote'
restore, force, backup '[BACKUP-INCR-1]', type 'xid', target '[XID-TARGET-1]', target-action=promote (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --force --set=[BACKUP-INCR-1] --tablespace-map-all=../../tablespace --type=xid --target="[XID-TARGET-1]" --link-all --target-action=promote --repo=2 --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
restore_command = '[BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=2 --stanza=db archive-get %f "%p"'
recovery_target_xid = '[XID-TARGET-1]'
recovery_target_action = 'promote'
restore, type 'preserve' (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --type=preserve --link-all --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
restore_command = '[BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=2 --stanza=db archive-get %f "%p"'
recovery_target_xid = '[XID-TARGET-1]'
recovery_target_action = 'promote'
restore delta, type 'time', target '[TIMESTAMP-TARGET-1]', target-action=promote (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --delta --type=time --target="[TIMESTAMP-TARGET-1]" --link-all --target-action=promote --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
restore_command = '[BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get %f "%p"'
recovery_target_time = '[TIMESTAMP-TARGET-1]'
recovery_target_action = 'promote'
restore delta, backup '[BACKUP-INCR-1]', type 'xid', target '[XID-TARGET-1]', exclusive, target-action=promote (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --delta --set=[BACKUP-INCR-1] --type=xid --target="[XID-TARGET-1]" --target-exclusive --link-all --target-action=promote --repo=2 --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
restore_command = '[BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=2 --stanza=db archive-get %f "%p"'
recovery_target_xid = '[XID-TARGET-1]'
recovery_target_inclusive = 'false'
recovery_target_action = 'promote'
restore delta, force, type 'name', target 'backrest', target-action=promote (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --delta --force --type=name --target="backrest" --link-all --target-action=promote --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
restore_command = '[BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --stanza=db archive-get %f "%p"'
recovery_target_name = 'backrest'
recovery_target_action = 'promote'
restore delta, backup '[BACKUP-INCR-1]', type 'standby', timeline '4' (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --delta --set=[BACKUP-INCR-1] --type=standby --target-timeline="4" --link-all --repo=2 --stanza=db restore
------------------------------------------------------------------------------------------------------------------------------------
+ supplemental file: [TEST_PATH]/db-primary/db/base/recovery.conf
-----------------------------------------------------------------
# Recovery settings generated by pgBackRest restore on [TIMESTAMP]
restore_command = '[BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf --repo=2 --stanza=db archive-get %f "%p"'
standby_mode = 'on'
recovery_target_timeline = '4'
stop all stanzas (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf stop
------------------------------------------------------------------------------------------------------------------------------------
stop db stanza (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --stanza=db stop
------------------------------------------------------------------------------------------------------------------------------------
stanza-delete db - delete stanza with --force when pgbackrest on pg host not accessible (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf --repo=1 --stanza=db --force stanza-delete
------------------------------------------------------------------------------------------------------------------------------------
start all stanzas (db-primary host)
> [CONTAINER-EXEC] db-primary [BACKREST-BIN] --config=[TEST_PATH]/db-primary/pgbackrest.conf start
------------------------------------------------------------------------------------------------------------------------------------
start all stanzas (backup host)
> [CONTAINER-EXEC] backup [BACKREST-BIN] --config=[TEST_PATH]/backup/pgbackrest.conf start
------------------------------------------------------------------------------------------------------------------------------------

View File

@ -62,7 +62,6 @@ sub codeCountScan
$strFile =~ '^test/certificate/' ||
$strFile =~ '^test/code-count/' ||
$strFile =~ '^test/data/' ||
$strFile =~ '^test/expect/' ||
$strFile =~ '^test/patch/' ||
$strFile =~ '^test/result/' ||
$strFile =~ '^test/scratch' ||

View File

@ -48,8 +48,6 @@ use constant TESTDEF_COVERAGE => 'coverage
push @EXPORT, qw(TESTDEF_COVERAGE);
use constant TESTDEF_CORE => 'core';
push @EXPORT, qw(TESTDEF_CORE);
use constant TESTDEF_EXPECT => 'expect';
push @EXPORT, qw(TESTDEF_EXPECT);
use constant TESTDEF_C => 'c';
push @EXPORT, qw(TESTDEF_C);
use constant TESTDEF_DEFINE => 'define';
@ -121,13 +119,11 @@ sub testDefLoad
{
my $hModuleType = $hTestDef->{$strModuleType};
my $bExpect = false; # By default don't run expect tests
my $bContainer = true; # By default run tests in a single container
my $bIndividual = false; # By default runs are all executed in the same container
if ($strModuleType eq TESTDEF_INTEGRATION)
{
$bExpect = true; # Integration tests run expect tests
$bContainer = false; # Integration tests can run in multiple containers
$bIndividual = true; # Integration tests can change containers on each run
}
@ -167,7 +163,6 @@ sub testDefLoad
$hTestDefHash->{$strModule}{$strTest}{&TESTDEF_C} =
$strModuleType ne TESTDEF_INTEGRATION && $strTest !~ /perl$/ ? true : false;
$hTestDefHash->{$strModule}{$strTest}{&TESTDEF_INTEGRATION} = $strModuleType eq TESTDEF_INTEGRATION ? true : false;
$hTestDefHash->{$strModule}{$strTest}{&TESTDEF_EXPECT} = $bExpect;
$hTestDefHash->{$strModule}{$strTest}{&TESTDEF_CONTAINER} = $bContainer;
$hTestDefHash->{$strModule}{$strTest}{&TESTDEF_INDIVIDUAL} = $bIndividual;

View File

@ -211,17 +211,6 @@ sub endRetry
$self->{strErrorLog} .= "${strLine}\n";
}
# Pass the log to the LogTest object
if (defined($self->{oLogTest}))
{
if (defined($self->{strErrorLog}) && $self->{strErrorLog} ne '')
{
$self->{strOutLog} .= "STDERR:\n" . $self->{strErrorLog};
}
$self->{oLogTest}->logAdd($self->{strCommand}, $self->{strComment}, $self->{bLogOutput} ? $self->{strOutLog} : undef);
}
# If an error was expected then return success if that error occurred
if ($self->{iExpectedExitStatus} != 0 && $iExitStatus == $self->{iExpectedExitStatus})
{

View File

@ -27,7 +27,6 @@ use pgBackRestDoc::Common::String;
use pgBackRestTest::Common::ExecuteTest;
use pgBackRestTest::Common::HostGroupTest;
use pgBackRestTest::Common::LogTest;
use pgBackRestTest::Common::RunTest;
use pgBackRestTest::Common::StorageBase;
use pgBackRestTest::Common::VmTest;

View File

@ -62,7 +62,6 @@ sub new
$self->{strLogLevelTest},
$self->{strLogLevelTestFile},
$self->{bLogTimestamp},
$self->{bLogForce},
$self->{bShowOutputAsync},
$self->{bNoCleanup},
$self->{iRetry},
@ -96,7 +95,6 @@ sub new
{name => 'strLogLevelTest'},
{name => 'strLogLevelTestFile'},
{name => 'bLogTimestamp'},
{name => 'bLogForce'},
{name => 'bShowOutputAsync'},
{name => 'bNoCleanup'},
{name => 'iRetry'},
@ -748,7 +746,6 @@ sub run
($self->{bLogTimestamp} ? '' : ' --no-log-timestamp') .
' --pgsql-bin=' . $self->{oTest}->{&TEST_PGSQL_BIN} .
($self->{strTimeZone} ? " --tz='$self->{strTimeZone}'" : '') .
($self->{bLogForce} ? ' --log-force' : '') .
($self->{bDryRun} ? ' --dry-run' : '') .
($self->{bDryRun} ? ' --vm-out' : '') .
($self->{bNoCleanup} ? " --no-cleanup" : '');

View File

@ -1,492 +0,0 @@
####################################################################################################################################
# LogTest.pm - Capture the output of commands to compare them with an expected version
####################################################################################################################################
package pgBackRestTest::Common::LogTest;
####################################################################################################################################
# Perl includes
####################################################################################################################################
use strict;
use warnings FATAL => qw(all);
use Carp qw(confess);
use Cwd qw(abs_path);
use Exporter qw(import);
our @EXPORT = qw();
use File::Basename qw(dirname);
use pgBackRestDoc::Common::Log;
use pgBackRestDoc::ProjectInfo;
use pgBackRestTest::Common::ContainerTest;
use pgBackRestTest::Common::ExecuteTest;
####################################################################################################################################
# Expect log cache for supplemental files so they are only added to expect logs when they have changed
####################################################################################################################################
my $hyExpectCache = undef;
####################################################################################################################################
# new
####################################################################################################################################
sub new
{
my $class = shift; # Class name
# Create the class hash
my $self = {};
bless $self, $class;
# Assign function parameters, defaults, and log debug info
(
my $strOperation,
$self->{strModule},
$self->{strTest},
$self->{iRun},
$self->{bForce},
$self->{strComment},
$self->{strCommandMain},
$self->{strPgSqlBin},
$self->{strTestPath},
$self->{strRepoPath},
) =
logDebugParam
(
__PACKAGE__ . '->new', \@_,
{name => 'strModule', trace => true},
{name => 'strTest', trace => true},
{name => 'iRun', trace => true},
{name => 'bForce', trace => true},
{name => 'strComment', trace => true},
{name => 'strCommandMain', trace => true},
{name => 'strPgSqlBin', required => false, trace => true},
{name => 'strTestPath', trace => true},
{name => 'strRepoPath', trace => true},
);
# Initialize the test log
$self->{strLog} = 'run ' . sprintf('%03d', $self->{iRun}) . ' - ' . $self->{strComment};
$self->{strLog} .= "\n" . ('=' x length($self->{strLog})) . "\n";
# Initialize the filename
$self->{strFileName} = sprintf("expect/$self->{strModule}-$self->{strTest}-%03d.log", $self->{iRun});
# Initialize the replacement hash
$self->{oReplaceHash} = {};
# Return from function and log return values if any
return logDebugReturn
(
$strOperation,
{name => 'self', value => $self, trace => true}
);
}
####################################################################################################################################
# logAdd
####################################################################################################################################
sub logAdd
{
my $self = shift;
# Assign function parameters, defaults, and log debug info
my
(
$strOperation,
$strCommand,
$strComment,
$strLog
) =
logDebugParam
(
__PACKAGE__ . '->logAdd', \@_,
{name => 'strCommand', trace => true},
{name => 'strComment', required => false, trace => true},
{name => 'strLog', required => false, trace => true}
);
$self->{strLog} .= "\n";
if (defined($strComment))
{
$self->{strLog} .= $self->regExpReplaceAll($strComment) . "\n";
}
$self->{strLog} .= '> ' . $self->regExpReplaceAll($strCommand) . "\n" . ('-' x '132') . "\n";
# Make sure there is a log before trying to output it
if (defined($strLog))
{
# Do replacements on each line of the log
foreach my $strLine (split("\n", $strLog))
{
# Remove timestamp from log line
$strLine =~ s/^[0-9]{4}-[0-1][0-9]-[0-3][0-9] [0-2][0-9]:[0-6][0-9]:[0-6][0-9]\.[0-9]{3} //;
# Don't include test points in the final log
if ($strLine !~ /^ TEST/)
{
# Remove spaces that provided padding for the timetamp
$strLine =~ s/^ //;
# Remove any final CRs
$strLine =~ s/\r$//;
# Do other replacements
$strLine = $self->regExpReplaceAll($strLine);
# Add to the log
$self->{strLog} .= "${strLine}\n";
}
}
}
# Return from function and log return values if any
logDebugReturn($strOperation);
}
####################################################################################################################################
# supplementalAdd
####################################################################################################################################
sub supplementalAdd
{
my $self = shift;
my $strFileName = shift;
my $strComment = shift;
my $strContent = shift;
# Get content if it is not defined
if (!defined($strContent))
{
open(my $hFile, '<', $strFileName)
or confess &log(ERROR, "unable to open ${strFileName} for appending to test log");
while (my $strLine = readline($hFile))
{
$strContent .= $strLine;
}
close($hFile);
}
# Only output when the content of this file has changed
if (!defined($hyExpectCache->{$strFileName}) || $hyExpectCache->{$strFileName} ne $strContent)
{
# $hyExpectCache->{$strFileName} = $strContent;
my $strHeader = "+ supplemental file: " . $self->regExpReplaceAll($strFileName);
if (defined($strComment))
{
$self->{strLog} .= "\n" . $self->regExpReplaceAll($strComment) . "\n" . ('=' x '132') . "\n";
}
$self->{strLog} .= "\n${strHeader}\n" . ('-' x length($strHeader)) . "\n";
if (length($strContent) > 0)
{
foreach my $strLine (split("\n", $strContent))
{
$self->{strLog} .= $self->regExpReplaceAll($strLine) . "\n";
}
}
}
}
####################################################################################################################################
# logWrite
####################################################################################################################################
sub logWrite
{
my $self = shift;
# Assign function parameters, defaults, and log debug info
my
(
$strOperation,
$strBasePath,
$strTestPath,
$strFileName
) =
logDebugParam
(
__PACKAGE__ . '->logWrite', \@_,
{name => 'strBasePath', trace => true},
{name => 'strTestPath', trace => true},
{name => 'strFileName', default => $self->{strFileName}, trace => true}
);
my $strReferenceLogFile = "${strBasePath}/test/${strFileName}";
my $strTestLogFile;
if ($self->{bForce})
{
$strTestLogFile = $strReferenceLogFile;
}
else
{
my $strTestLogPath = "${strTestPath}/expect";
if (!-e $strTestLogPath)
{
mkdir($strTestLogPath, 0750) or
confess "unable to create expect log path ${strTestLogPath}";
}
$strTestLogFile = "${strTestPath}/${strFileName}";
}
open(my $hFile, '>', $strTestLogFile)
or confess "unable to open expect log file '${strTestLogFile}': $!";
syswrite($hFile, $self->{strLog})
or confess "unable to write expect log file '${strTestLogFile}': $!";
close($hFile);
if (!$self->{bForce})
{
executeTest("diff ${strReferenceLogFile} ${strTestLogFile}");
}
# Return from function and log return values if any
logDebugReturn($strOperation);
}
####################################################################################################################################
# regExpReplace
####################################################################################################################################
sub regExpReplace
{
my $self = shift;
my $strLine = shift;
my $strType = shift;
my $strExpression = shift;
my $strToken = shift;
my $bIndex = shift;
my @stryReplace = ($strLine =~ /$strExpression/g);
foreach my $strReplace (@stryReplace)
{
my $iIndex;
my $strTypeReplacement;
my $strReplacement;
if (!defined($bIndex) || $bIndex)
{
if (defined($strToken))
{
my @stryReplacement = ($strReplace =~ /$strToken/g);
if (@stryReplacement != 1)
{
my $strError = "'${strToken}'";
if (@stryReplacement == 0)
{
confess &log(ASSERT, $strError . " is not a sub-regexp of '${strExpression}' or" .
" matches " . @stryReplacement . " times on {[${strReplace}]}");
}
confess &log(
ASSERT, $strError . " matches '${strExpression}' " . @stryReplacement . " times on '${strReplace}': " .
join(',', @stryReplacement));
}
$strReplacement = $stryReplacement[0];
}
else
{
$strReplacement = $strReplace;
}
if (defined($strType))
{
if (defined(${$self->{oReplaceHash}}{$strType}{$strReplacement}))
{
$iIndex = ${$self->{oReplaceHash}}{$strType}{$strReplacement}{index};
}
else
{
if (!defined(${$self->{oReplaceHash}}{$strType}{index}))
{
${$self->{oReplaceHash}}{$strType}{index} = 1;
}
$iIndex = ${$self->{oReplaceHash}}{$strType}{index}++;
${$self->{oReplaceHash}}{$strType}{$strReplacement}{index} = $iIndex;
}
}
}
$strTypeReplacement = defined($strType) ? "[${strType}" . (defined($iIndex) ? "-${iIndex}" : '') . ']' : '';
if (defined($strToken))
{
$strReplacement = $strReplace;
$strReplacement =~ s/$strToken/$strTypeReplacement/;
}
else
{
$strReplacement = $strTypeReplacement;
}
$strReplace =~ s/\//\\\//g;
$strReplace =~ s/\+/\\\+/g;
$strLine =~ s/$strReplace/$strReplacement/g;
}
return $strLine;
}
####################################################################################################################################
# regExpReplaceAll
#
# Replaces dynamic test output so that the expected test output can be verified against actual test output.
####################################################################################################################################
sub regExpReplaceAll
{
my $self = shift;
my $strLine = shift;
my $strBinPath = dirname(dirname(abs_path($0))) . '/bin';
# Replace the exe path/file with sh ' prepended
my $strLineBefore = $strLine;
$strLine =~ s/bash -l -c '$self->{strCommandMain}/[BACKREST-BIN]/g;
# Replace the final ' if the previous expression made changes
if ($strLine ne $strLineBefore)
{
$strLine =~ s/'$//g;
}
# Replace the exe path/file with sh ' prepended
$strLine =~ s/$self->{strCommandMain}/[BACKREST-BIN]/g;
# Replace the test path
$strLine =~ s/$self->{strTestPath}/[TEST_PATH]/g;
# Replace the repo path
$strLine =~ s/$self->{strRepoPath}/[REPO_PATH]/g;
# Replace the pgsql path (if exists)
if (defined($self->{strPgSqlBin}))
{
$strLine =~ s/$self->{strPgSqlBin}/[PGSQL_BIN_PATH]/g;
}
$strLine = $self->regExpReplace($strLine, 'BACKREST-NAME-VERSION', '^' . PROJECT_NAME . ' ' . PROJECT_VERSION,
undef, false);
$strLine = $self->regExpReplace(
$strLine, 'BACKREST-VERSION', ' begin ' . PROJECT_VERSION . '\:', PROJECT_VERSION, false);
$strLine = $self->regExpReplace($strLine, undef, '^docker exec -u [a-z]* test-[0-9]+\-', 'test-[0-9]+\-', false);
$strLine = $self->regExpReplace($strLine, 'CONTAINER-EXEC', '^docker exec -u [a-z]*', '^docker exec -u [a-z]*', false);
$strLine = $self->regExpReplace($strLine, 'PROCESS-ID', 'sent term signal to process [0-9]+', '[0-9]+$', false);
$strLine = $self->regExpReplace($strLine, 'YEAR', 'backup\.history\/20[0-9]{2}', '20[0-9]{2}$');
$strLine = $self->regExpReplace($strLine, 'BACKUP-INCR', '[0-9]{8}\-[0-9]{6}F\_[0-9]{8}\-[0-9]{6}I');
$strLine = $self->regExpReplace($strLine, 'BACKUP-DIFF', '[0-9]{8}\-[0-9]{6}F\_[0-9]{8}\-[0-9]{6}D');
$strLine = $self->regExpReplace($strLine, 'BACKUP-FULL', '[0-9]{8}\-[0-9]{6}F');
$strLine = $self->regExpReplace(
$strLine, 'BACKUP-EXPR', 'strExpression \= \_[0-9]{8}\-[0-9]{6}', '\_[0-9]{8}\-[0-9]{6}$', false);
if ($strLine =~ /^P00 DETAIL\: statistics\: /)
{
$strLine = 'P00 DETAIL: statistics: STATISTICS'
}
$strLine = $self->regExpReplace($strLine, 'GROUP', 'strGroup = [^ \n,\[\]]+', '[^ \n,\[\]]+$');
$strLine = $self->regExpReplace($strLine, 'GROUP', 'unknown group in backup manifest mapped to \'[^\']+', '[^\']+$');
$strLine = $self->regExpReplace($strLine, 'GROUP', 'group"[ ]{0,1}:[ ]{0,1}"[^"]+', '[^"]+$');
$strLine = $self->regExpReplace($strLine, 'GROUP', 'group=\"[^"]+', '[^"]+$');
$strLine = $self->regExpReplace($strLine, 'GROUP', 'group for .* was not mapped to a name\, set to .+$', '[^ ]+$');
$strLine = $self->regExpReplace($strLine, 'GROUP', 'set ownership [^\:]+:[^ ]+', '[^\:]+$');
$strLine = $self->regExpReplace($strLine, 'GROUP', TEST_USER . '\, ' . TEST_GROUP, '[^ ]+$');
$strLine = $self->regExpReplace($strLine, 'USER', 'strRemoteHostUser = [^ \n,\[\]]+', '[^ \n,\[\]]+$');
$strLine = $self->regExpReplace($strLine, 'USER', 'unknown user in backup manifest mapped to \'[^\']+', '[^\']+$');
$strLine = $self->regExpReplace($strLine, 'USER', 'strUser = [^ \n,\[\]]+', '[^ \n,\[\]]+$');
$strLine = $self->regExpReplace($strLine, 'USER', 'user"[ ]{0,1}:[ ]{0,1}"[^"]+', '[^"]+$');
$strLine = $self->regExpReplace($strLine, 'USER', 'user=\"[^"]+', '[^"]+$');
$strLine = $self->regExpReplace($strLine, 'USER', '^pg-host-user=.+$', '[^=]+$');
$strLine = $self->regExpReplace($strLine, 'USER', 'user for .* was not mapped to a name\, set to .+$', '[^ ]+$');
$strLine = $self->regExpReplace($strLine, 'USER', 'set ownership [^\:]+', '[^ ]+$');
$strLine = $self->regExpReplace($strLine, 'USER', 'cannot be used for restore\, set to .+$', '[^ ]+$');
$strLine = $self->regExpReplace($strLine, 'USER', '-user=[a-z0-9_]+', '[^=]+$');
$strLine = $self->regExpReplace($strLine, 'USER', '[^ ]+\@db\-primary', '^[^\@]+');
$strLine = $self->regExpReplace($strLine, 'USER', '[\( ]{1}' . TEST_USER . '[\,\)]{1}', TEST_USER);
$strLine = $self->regExpReplace($strLine, 'EXEC-ID', '--exec-id=[^ ]+', '[^=]+$', false);
$strLine = $self->regExpReplace($strLine, 'CIPHER-PASS', '^cipher\-pass\=.+$', '[^\=]+$');
$strLine = $self->regExpReplace($strLine, 'PORT', 'db[1-9]{0,1}-port=[0-9]+', '[0-9]+$');
# Replace year when it falls on a single line when executing ls -1R
$strLine = $self->regExpReplace($strLine, 'YEAR', '^20[0-9]{2}$');
# Replace year when it is the last part of a path when executing ls -1R
$strLine = $self->regExpReplace($strLine, 'YEAR', 'history\/20[0-9]{2}\:$', '20[0-9]{2}');
my $strTimestampRegExp = "[0-9]{4}-[0-1][0-9]-[0-3][0-9] [0-2][0-9]:[0-6][0-9]:[0-6][0-9]";
$strLine = $self->regExpReplace($strLine, 'TS_PATH', "PG\\_[0-9]\\.[0-9]\\_[0-9]{9}");
my $strProjectVersion = PROJECT_VERSION;
$strProjectVersion =~ s/\./\\./g;
$strLine = $self->regExpReplace($strLine, 'VERSION',
"version[\"]{0,1}[ ]{0,1}[\:\=)]{1}[ ]{0,1}[\"]{0,1}" . $strProjectVersion, $strProjectVersion . '$');
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP', 'timestamp"[ ]{0,1}:[ ]{0,1}[0-9]{10}','[0-9]{10}$');
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP',
"timestamp-[a-z-]+[\"]{0,1}[ ]{0,1}[\:\=)]{1}[ ]{0,1}[\"]{0,1}[0-9]{10}", '[0-9]{10}$', false);
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP', "start\" : [0-9]{10}", '[0-9]{10}$', false);
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP', "stop\" : [0-9]{10}", '[0-9]{10}$', false);
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP', TEST_GROUP . '\, [0-9]{10}', '[0-9]{10}$', false);
$strLine = $self->regExpReplace(
$strLine, 'TIMESTAMP', 'generated by pgBackRest restore on .*$',
'[0-9]{4}\-[0-9]{2}\-[0-9]{2} [0-9]{2}\:[0-9]{2}\:[0-9]{2}$', false);
$strLine = $self->regExpReplace($strLine, 'SIZE', "size\"[ ]{0,1}:[ ]{0,1}[0-9]+", '[0-9]+$', false);
$strLine = $self->regExpReplace($strLine, 'DELTA', "delta\"[ ]{0,1}:[ ]{0,1}[0-9]+", '[0-9]+$', false);
$strLine = $self->regExpReplace(
$strLine, 'TIMESTAMP-STR', "timestamp start\/stop: $strTimestampRegExp / $strTimestampRegExp",
"${strTimestampRegExp} / ${strTimestampRegExp}\$", false);
$strLine = $self->regExpReplace($strLine, 'CHECKSUM', 'checksum=[\"]{0,1}[0-f]{40}', '[0-f]{40}$', false);
$strLine = $self->regExpReplace($strLine, 'LOG-LEVEL-FILE', 'log-level-file=[a-z]+', '[a-z]+$', false);
$strLine = $self->regExpReplace($strLine, 'LOG-SUBPROCESS', 'log-subprocess=[a-z]+', '[a-z]+$', false);
$strLine = $self->regExpReplace($strLine, '', ' --log-subprocess', undef, false);
$strLine = $self->regExpReplace($strLine, '', ' --no-log-subprocess', undef, false);
$strLine = $self->regExpReplace($strLine, 'BUFFER-SIZE', 'buffer-size=[0-9a-z]+', '[0-9a-z]+$', false);
$strLine = $self->regExpReplace($strLine, 'REMOTE-PROCESS-TERMINATED-MESSAGE',
'remote process terminated.*: (ssh.*|no output from terminated process)$',
'(ssh.*|no output from terminated process)$', false);
# Full test time-based recovery
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP-TARGET', "\\, target \\'.*UTC", "[^\\']+UTC\$");
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP-TARGET', " \\-\\-target\\=\\\".*UTC", "[^\\\"]+UTC\$");
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP-TARGET', "^recovery_target_time \\= \\'.*UTC", "[^\\']+UTC\$");
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP-TARGET', "\\, target \\'.*\\+00", "[^\\']+\\+00\$");
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP-TARGET', " \\-\\-target\\=\\\".*\\+00", "[^\\\"]+\\+00\$");
$strLine = $self->regExpReplace($strLine, 'TIMESTAMP-TARGET', "^recovery_target_time \\= \\'.*\\+00", "[^\\']+\\+00\$");
# Full test xid-based recovery (this expressions only work when time-based expressions above have already been applied
$strLine = $self->regExpReplace($strLine, 'XID-TARGET', "\\, target \\'[0-9]+", "[0-9]+\$");
$strLine = $self->regExpReplace($strLine, 'XID-TARGET', " \\-\\-target\\=\\\"[0-9]+", "[0-9]+\$");
$strLine = $self->regExpReplace($strLine, 'XID-TARGET', "^recovery_target_xid \\= \\'[0-9]+", "[0-9]+\$");
$strLine = $self->regExpReplace(
$strLine, 'MODIFICATION-TIME', '(' . (substr(time(), 0, 5) - 1) . '[0-9]{5}|' . substr(time(), 0, 5) . '[0-9]{5})',
'^[0-9]{10}$');
return $strLine;
}
1;

View File

@ -23,7 +23,6 @@ use pgBackRestDoc::ProjectInfo;
use pgBackRestTest::Common::BuildTest;
use pgBackRestTest::Common::DefineTest;
use pgBackRestTest::Common::ExecuteTest;
use pgBackRestTest::Common::LogTest;
use pgBackRestTest::Common::Storage;
use pgBackRestTest::Common::StoragePosix;
use pgBackRestTest::Common::VmTest;
@ -124,7 +123,6 @@ sub process
$self->{bOutput},
$self->{bDryRun},
$self->{bCleanup},
$self->{bLogForce},
$self->{strLogLevelTestFile},
$self->{strPgUser},
$self->{strGroup},
@ -146,7 +144,6 @@ sub process
{name => 'bOutput'},
{name => 'bDryRun'},
{name => 'bCleanup'},
{name => 'bLogForce'},
{name => 'strLogLevelTestFile'},
{name => 'strPgUser'},
{name => 'strGroup'},
@ -159,10 +156,9 @@ sub process
$oStorage = new pgBackRestTest::Common::Storage(
$self->testPath(), new pgBackRestTest::Common::StoragePosix({bFileSync => false, bPathSync => false}));
# Init, run, and end the test(s)
# Init, run, and clean the test(s)
$self->initModule();
$self->run();
$self->end();
$self->cleanModule();
# Make sure the correct number of tests ran
@ -193,34 +189,13 @@ sub begin
(
$strOperation,
$strDescription,
$bExpect,
) =
logDebugParam
(
__PACKAGE__ . '->begin', \@_,
{name => 'strDescription'},
{name => 'bExpect', required => false},
);
# Save the previous expect log
$self->end();
# If bExpect is defined then it is an override of the default
$self->{bExpect} = false;
if ($self->vm() eq VM_EXPECT)
{
if (defined($bExpect))
{
$self->{bExpect} = $bExpect;
}
# Else get the default expect setting
else
{
$self->{bExpect} = (testDefModuleTest($self->{strModule}, $self->{strModuleTest}))->{&TESTDEF_EXPECT};
}
}
# Increment the run counter;
$self->{iRun}++;
@ -238,17 +213,6 @@ sub begin
return false;
}
# Create an ExpectTest object
if ($self->doExpect())
{
$self->{oExpect} = new pgBackRestTest::Common::LogTest(
$self->module(), $self->moduleTest(), $self->runCurrent(), $self->doLogForce(), $strDescription,
$self->{strBackRestExe}, $self->pgBinPath(), $self->testPath(), $self->basePath());
&log(INFO, ' expect log: ' . $self->{oExpect}->{strFileName});
}
if (!$self->{bFirstTest})
{
$self->cleanTest();
@ -260,21 +224,6 @@ sub begin
return true;
}
####################################################################################################################################
# end
####################################################################################################################################
sub end
{
my $self = shift;
# Save the previous test log
if (defined($self->expect()))
{
$self->expect()->logWrite($self->basePath(), $self->testPath());
delete($self->{oExpect});
}
}
####################################################################################################################################
# testResult
####################################################################################################################################
@ -290,8 +239,6 @@ sub testResult
$strExpected,
$strDescription,
$iWaitSeconds,
$strLogExpect,
$strLogLevel,
) =
logDebugParam
(
@ -300,8 +247,6 @@ sub testResult
{name => 'strExpected', required => false, trace => true},
{name => 'strDescription', trace => true},
{name => 'iWaitSeconds', optional => true, default => 0, trace => true},
{name => 'strLogExpect', optional => true, trace => true},
{name => 'strLogLevel', optional => true, default => WARN, trace => true},
);
&log(INFO, ' ' . $strDescription);
@ -311,10 +256,6 @@ sub testResult
my $oWait = waitInit($iWaitSeconds);
my $bDone = false;
# Save the current log levels and set the file level to strLogLevel, console to off, and timestamp false
my ($strLogLevelFile, $strLogLevelConsole, $strLogLevelStdErr, $bLogTimestamp) = logLevel();
logLevelSet($strLogLevel, OFF, undef, false);
# Clear the cache for this test
logFileCacheClear();
@ -335,15 +276,10 @@ sub testResult
$strActual = ${logDebugBuild(\@stryResult)};
}
# Restore the log level
logLevelSet($strLogLevelFile, $strLogLevelConsole, $strLogLevelStdErr, $bLogTimestamp);
return true;
}
or do
{
# Restore the log level
logLevelSet($strLogLevelFile, $strLogLevelConsole, $strLogLevelStdErr, $bLogTimestamp);
if (!isException(\$EVAL_ERROR))
{
confess "unexpected standard Perl exception" . (defined($EVAL_ERROR) ? ": ${EVAL_ERROR}" : '');
@ -367,23 +303,6 @@ sub testResult
}
} while (!$bDone);
# If we get here then test any warning message
if (defined($strLogExpect))
{
my $strLogMessage = trim(logFileCache());
# Strip leading Process marker and whitespace from each line
$strLogMessage =~ s/^(P[0-9]{2})*\s+//mg;
# If the expected message does not exactly match the logged message or is not at least contained in it, then error
if (!($strLogMessage eq $strLogExpect || $strLogMessage =~ $strLogExpect))
{
confess &log(ERROR,
"the log message:\n$strLogMessage\ndoes not match or does not contain the expected message:\n" .
$strLogExpect);
}
}
# Return from function and log return values if any
return logDebugReturn
(
@ -392,60 +311,6 @@ sub testResult
);
}
####################################################################################################################################
# testException
####################################################################################################################################
sub testException
{
my $self = shift;
my $fnSub = shift;
my $iCodeExpected = shift;
my $strMessageExpected = shift;
# Output first line of the error message
&log(INFO,
" [${iCodeExpected}] " . (defined($strMessageExpected) ? (split('\n', $strMessageExpected))[0] : 'undef error message'));
my $bError = false;
my $strError =
"exception ${iCodeExpected}, " . (defined($strMessageExpected) ? "'${strMessageExpected}'" : '[UNDEF]') . " was expected";
eval
{
logDisable();
$fnSub->();
logEnable();
return true;
}
or do
{
logEnable();
if (!isException(\$EVAL_ERROR))
{
confess "${strError} but actual was standard Perl exception" . (defined($EVAL_ERROR) ? ": ${EVAL_ERROR}" : '');
}
if (!($EVAL_ERROR->code() == $iCodeExpected &&
(!defined($strMessageExpected) && !defined($EVAL_ERROR->message()) ||
(defined($strMessageExpected) && defined($EVAL_ERROR->message()) &&
($EVAL_ERROR->message() eq $strMessageExpected || $EVAL_ERROR->message() =~ "^${strMessageExpected}" ||
$EVAL_ERROR->message() =~ "^${strMessageExpected} at ")))))
{
confess
"${strError} but actual was " . $EVAL_ERROR->code() . ', ' .
(defined($EVAL_ERROR->message()) ? qw{'} . $EVAL_ERROR->message() . qw{'} : '[UNDEF]');
}
$bError = true;
};
if (!$bError)
{
confess "${strError} but no exception was thrown";
}
}
####################################################################################################################################
# testRunName
#
@ -544,12 +409,9 @@ sub backrestExeHelper {return shift->{strBackRestExeHelper}}
sub basePath {return shift->{strBasePath}}
sub dataPath {return shift->basePath() . '/test/data'}
sub doCleanup {return shift->{bCleanup}}
sub doExpect {return shift->{bExpect}}
sub doLogForce {return shift->{bLogForce}}
sub logLevelTestFile {return shift->{strLogLevelTestFile}}
sub group {return shift->{strGroup}}
sub isDryRun {return shift->{bDryRun}}
sub expect {return shift->{oExpect}}
sub module {return shift->{strModule}}
sub moduleTest {return shift->{strModuleTest}}
sub pgBinPath {return shift->{strPgBinPath}}

View File

@ -93,10 +93,6 @@ use constant VM_U20 => 'u20';
use constant VM_D9 => 'd9';
push @EXPORT, qw(VM_D9);
# Defines the vm that will be used for expect testing
use constant VM_EXPECT => VM_RH7;
push @EXPORT, qw(VM_EXPECT);
# VM aliases for run matrices (numbered oldest to newest)
use constant VM2 => VM_D9;
push @EXPORT, qw(VM2);

View File

@ -49,7 +49,6 @@ sub new
$self->{strBackRestExe},
$self->{oStorageRepo},
$self->{strPgPath},
$self->{oLogTest},
$self->{oRunTest},
) =
logDebugParam
@ -59,7 +58,6 @@ sub new
{name => 'strBackRestExe', trace => true},
{name => 'oStorageRepo', trace => true},
{name => 'strPgPath', trace => true},
{name => 'oLogTest', required => false, trace => true},
{name => 'oRunTest', required => false, trace => true},
);
@ -578,70 +576,6 @@ sub archiveCreate
);
}
####################################################################################################################################
# supplementalLog
####################################################################################################################################
sub supplementalLog
{
my $self = shift;
# Assign function parameters, defaults, and log debug info
my
(
$strOperation,
$strStanza
) =
logDebugParam
(
__PACKAGE__ . '->supplementalLog', \@_,
{name => 'strStanza'}
);
my $oStanza = $self->{oStanzaHash}{$strStanza};
if (defined($self->{oLogTest}))
{
$self->{oLogTest}->supplementalAdd(
$self->{oHostBackup}->repoPath() . "/backup/${strStanza}/backup.info", $$oStanza{strBackupDescription},
${storageRepo->get($self->{oHostBackup}->repoPath() . "/backup/${strStanza}/backup.info")});
# Output backup list
$self->{oLogTest}->logAdd(
'ls ' . $self->{oHostBackup}->repoPath() . "/backup/${strStanza} | grep -v \"backup.*\"", undef,
join("\n", grep(!/^backup\.info.*$/i, storageRepo()->list("backup/${strStanza}"))));
# Output archive manifest
my $rhManifest = storageRepo()->manifest($self->{oHostBackup}->repoArchivePath());
my $strManifest;
my $strPrefix = '';
foreach my $strEntry (sort(keys(%{$rhManifest})))
{
# Skip files
next if $strEntry eq ARCHIVE_INFO_FILE || $strEntry eq ARCHIVE_INFO_FILE . INI_COPY_EXT;
if ($rhManifest->{$strEntry}->{type} eq 'd')
{
$strEntry = $self->{oHostBackup}->repoArchivePath($strEntry eq '.' ? undef : $strEntry);
# &log(WARN, "DIR $strEntry");
$strManifest .= (defined($strManifest) ? "\n" : '') . "${strEntry}:\n";
$strPrefix = $strEntry;
}
else
{
# &log(WARN, "FILE $strEntry");
$strManifest .= basename($strEntry) . "\n";
}
}
$self->{oLogTest}->logAdd(
'ls -R ' . $self->{oHostBackup}->repoPath() . "/archive/${strStanza} | grep -v \"archive.info\"", undef, $strManifest);
}
return logDebugReturn($strOperation);
}
####################################################################################################################################
# process
####################################################################################################################################
@ -673,8 +607,6 @@ sub process
my $oStanza = $self->{oStanzaHash}{$strStanza};
$self->supplementalLog($strStanza);
undef($$oStanza{strBackupDescription});
my $strCommand =
@ -706,9 +638,7 @@ sub process
$strCommand .= ' expire';
$self->{oHostBackup}->executeSimple($strCommand, {strComment => $strDescription, oLogTest => $self->{oLogTest}});
$self->supplementalLog($strStanza);
$self->{oHostBackup}->executeSimple($strCommand, {strComment => $strDescription});
# Return from function and log return values if any
return logDebugReturn($strOperation);

View File

@ -182,9 +182,6 @@ sub new
# Set conf file
$self->{strBackRestConfig} = $self->testPath() . '/' . PROJECT_CONF;
# Set LogTest object
$self->{oLogTest} = $$oParam{oLogTest};
# Set synthetic
$self->{bSynthetic} = defined($$oParam{bSynthetic}) && $$oParam{bSynthetic} ? true : false;
@ -341,8 +338,7 @@ sub backupBegin
(defined($oParam->{iRepo}) ? ' --repo=' . $oParam->{iRepo} : '') .
($strType ne 'incr' ? " --type=${strType}" : '') .
' --stanza=' . (defined($oParam->{strStanza}) ? $oParam->{strStanza} : $self->stanza()) . ' backup',
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus},
oLogTest => $self->{oLogTest}, bLogOutput => $self->synthetic()});
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, bLogOutput => $self->synthetic()});
$oExecuteBackup->begin();
@ -509,39 +505,6 @@ sub backupEnd
}
}
# Add files to expect log
if (defined($self->{oLogTest}) && (!defined($$oParam{bSupplemental}) || $$oParam{bSupplemental}))
{
my $oHostGroup = hostGroupGet();
if (defined($oHostGroup->hostGet(HOST_DB_PRIMARY, true)))
{
$self->{oLogTest}->supplementalAdd($oHostGroup->hostGet(HOST_DB_PRIMARY)->testPath() . '/' . PROJECT_CONF);
}
if (defined($oHostGroup->hostGet(HOST_DB_STANDBY, true)))
{
$self->{oLogTest}->supplementalAdd($oHostGroup->hostGet(HOST_DB_STANDBY)->testPath() . '/' . PROJECT_CONF);
}
if (defined($oHostGroup->hostGet(HOST_BACKUP, true)))
{
$self->{oLogTest}->supplementalAdd($oHostGroup->hostGet(HOST_BACKUP)->testPath() . '/' . PROJECT_CONF);
}
if ($self->synthetic() && $bManifestCompare)
{
$self->{oLogTest}->supplementalAdd(
$self->repoBackupPath("${strBackup}/" . FILE_MANIFEST), undef,
${storageRepo()->get(
storageRepo()->openRead(
$self->repoBackupPath("${strBackup}/" . FILE_MANIFEST),
{strCipherPass => $self->cipherPassManifest()}))});
$self->{oLogTest}->supplementalAdd(
$self->repoBackupPath(FILE_BACKUP_INFO), undef, ${storageRepo->get($self->repoBackupPath(FILE_BACKUP_INFO))});
}
}
# Return from function and log return values if any
return logDebugReturn
(
@ -805,8 +768,7 @@ sub check
(defined($$oParam{iTimeout}) ? " --archive-timeout=$$oParam{iTimeout}" : '') .
(defined($$oParam{strOptionalParam}) ? " $$oParam{strOptionalParam}" : '') .
' --stanza=' . $self->stanza() . ' check',
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, oLogTest => $self->{oLogTest},
bLogOutput => $self->synthetic()});
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, bLogOutput => $self->synthetic()});
# Return from function and log return values if any
return logDebugReturn($strOperation);
@ -850,8 +812,7 @@ sub expire
(defined($$oParam{strOptionalParam}) ? " $$oParam{strOptionalParam}" : '') .
' --repo=' . (defined($oParam->{iRepo}) ? $oParam->{iRepo} : '1') .
' --stanza=' . $self->stanza() . ' expire',
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, oLogTest => $self->{oLogTest},
bLogOutput => $self->synthetic()});
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, bLogOutput => $self->synthetic()});
}
####################################################################################################################################
@ -886,7 +847,7 @@ sub info
' --log-level-console=warn' .
(defined($$oParam{strStanza}) ? " --stanza=$$oParam{strStanza}" : '') .
(defined($$oParam{strOutput}) ? " --output=$$oParam{strOutput}" : '') . ' info',
{strComment => $strComment, oLogTest => $self->{oLogTest}, bLogOutput => $self->synthetic()});
{strComment => $strComment, bLogOutput => $self->synthetic()});
# Return from function and log return values if any
return logDebugReturn($strOperation);
@ -924,30 +885,16 @@ sub stanzaCreate
' --stanza=' . $self->stanza() .
(defined($$oParam{strOptionalParam}) ? " $$oParam{strOptionalParam}" : '') .
' stanza-create',
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, oLogTest => $self->{oLogTest},
bLogOutput => $self->synthetic()});
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, bLogOutput => $self->synthetic()});
if (storageRepo()->exists('backup/' . $self->stanza() . qw{/} . FILE_BACKUP_INFO))
{
# If the info file was created, then add it to the expect log
if (defined($self->{oLogTest}) && $self->synthetic())
{
$self->{oLogTest}->supplementalAdd(
$self->repoBackupPath(FILE_BACKUP_INFO), undef, ${storageRepo()->get($self->repoBackupPath(FILE_BACKUP_INFO))});
}
# Get the passphrase for accessing the manifest file
$self->{strCipherPassManifest} = (new pgBackRestTest::Env::BackupInfo($self->repoBackupPath()))->cipherPassSub();
}
if (storageRepo()->exists('archive/' . $self->stanza() . qw{/} . ARCHIVE_INFO_FILE))
{
# If the info file was created, then add it to the expect log
if (defined($self->{oLogTest}) && $self->synthetic())
{
$self->{oLogTest}->supplementalAdd(
$self->repoArchivePath(ARCHIVE_INFO_FILE), undef, ${storageRepo()->get($self->repoArchivePath(ARCHIVE_INFO_FILE))});
}
# Get the passphrase for accessing the archived files
$self->{strCipherPassArchive} =
@ -990,23 +937,7 @@ sub stanzaUpgrade
' --stanza=' . $self->stanza() .
(defined($$oParam{strOptionalParam}) ? " $$oParam{strOptionalParam}" : '') .
' stanza-upgrade',
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, oLogTest => $self->{oLogTest},
bLogOutput => $self->synthetic()});
# If the info file was created, then add it to the expect log
if (defined($self->{oLogTest}) && $self->synthetic() &&
storageRepo()->exists('backup/' . $self->stanza() . qw{/} . FILE_BACKUP_INFO))
{
$self->{oLogTest}->supplementalAdd(
$self->repoBackupPath(FILE_BACKUP_INFO), undef, ${storageRepo()->get($self->repoBackupPath(FILE_BACKUP_INFO))});
}
if (defined($self->{oLogTest}) && $self->synthetic() &&
storageRepo()->exists('archive/' . $self->stanza() . qw{/} . ARCHIVE_INFO_FILE))
{
$self->{oLogTest}->supplementalAdd(
$self->repoArchivePath(ARCHIVE_INFO_FILE), undef, ${storageRepo()->get($self->repoArchivePath(ARCHIVE_INFO_FILE))});
}
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, bLogOutput => $self->synthetic()});
# Return from function and log return values if any
return logDebugReturn($strOperation);
@ -1045,18 +976,7 @@ sub stanzaDelete
' --stanza=' . $self->stanza() .
(defined($$oParam{strOptionalParam}) ? " $$oParam{strOptionalParam}" : '') .
' stanza-delete',
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, oLogTest => $self->{oLogTest},
bLogOutput => $self->synthetic()});
if (defined($self->{oLogTest}) && $self->synthetic())
{
$self->{oLogTest}->logAdd(
'list backup', $self->stanza() . ' must not exist for successful delete',
join("\n", storageRepo()->list('backup')));
$self->{oLogTest}->logAdd(
'list archive', $self->stanza() . ' must not exist for successful delete',
join("\n", storageRepo()->list('archive')));
}
{strComment => $strComment, iExpectedExitStatus => $$oParam{iExpectedExitStatus}, bLogOutput => $self->synthetic()});
# Return from function and log return values if any
return logDebugReturn($strOperation);
@ -1090,7 +1010,7 @@ sub start
$self->backrestExe() .
' --config=' . $self->backrestConfig() .
(defined($$oParam{strStanza}) ? " --stanza=$$oParam{strStanza}" : '') . ' start',
{strComment => $strComment, oLogTest => $self->{oLogTest}, bLogOutput => $self->synthetic()});
{strComment => $strComment, bLogOutput => $self->synthetic()});
}
####################################################################################################################################
@ -1122,7 +1042,7 @@ sub stop
' --config=' . $self->backrestConfig() .
(defined($$oParam{strStanza}) ? " --stanza=$$oParam{strStanza}" : '') .
(defined($$oParam{bForce}) && $$oParam{bForce} ? ' --force' : '') . ' stop',
{strComment => $strComment, oLogTest => $self->{oLogTest}, bLogOutput => $self->synthetic()});
{strComment => $strComment, bLogOutput => $self->synthetic()});
# Return from function and log return values if any
return logDebugReturn($strOperation);
@ -1904,8 +1824,7 @@ sub restore
(defined($strTargetAction) && $strTargetAction ne 'pause' ? " --target-action=${strTargetAction}" : '') .
(defined($iRepo) ? " --repo=${iRepo}" : '') .
" --stanza=" . $self->stanza() . ' restore',
{strComment => $strComment, iExpectedExitStatus => $iExpectedExitStatus, oLogTest => $self->{oLogTest},
bLogOutput => $self->synthetic()},
{strComment => $strComment, iExpectedExitStatus => $iExpectedExitStatus, bLogOutput => $self->synthetic()},
$strUser);
if (!defined($iExpectedExitStatus))
@ -1916,13 +1835,6 @@ sub restore
{
$self->restoreCompare($strBackupExpected, dclone($rhExpectedManifest), $bTablespace);
}
if (defined($self->{oLogTest}))
{
$self->{oLogTest}->supplementalAdd(
$rhExpectedManifest->{&MANIFEST_SECTION_BACKUP_TARGET}{&MANIFEST_TARGET_PGDATA}{&MANIFEST_SUBKEY_PATH} .
"/recovery.conf");
}
}
}

View File

@ -75,7 +75,6 @@ sub new
strImage => $$oParam{strImage},
bTls => $oParam->{bTls},
strBackupDestination => $$oParam{strBackupDestination},
oLogTest => $$oParam{oLogTest},
bSynthetic => $$oParam{bSynthetic},
bRepoLocal => $oParam->{bRepoLocal},
bRepoEncrypt => $oParam->{bRepoEncrypt},
@ -154,7 +153,7 @@ sub archivePush
($bAsync ? '' : ' --no-archive-async') .
" archive-push" . (defined($strSourceFile) ? " ${strSourceFile}" : '') .
(defined($strOptionalParam) ? " ${strOptionalParam}" : ''),
{iExpectedExitStatus => $iExpectedError, oLogTest => $self->{oLogTest}, bLogOutput => $self->synthetic()});
{iExpectedExitStatus => $iExpectedError, bLogOutput => $self->synthetic()});
# Return from function and log return values if any
return logDebugReturn($strOperation);

View File

@ -57,7 +57,6 @@ sub new
strImage => containerRepo() . ':' . testRunGet()->vm() . "-test",
bTls => $oParam->{bTls},
strBackupDestination => $$oParam{strBackupDestination},
oLogTest => $$oParam{oLogTest},
bSynthetic => true,
bStandby => $$oParam{bStandby},
bRepoLocal => $oParam->{bRepoLocal},

View File

@ -64,7 +64,6 @@ sub new
strImage => containerRepo() . ':' . testRunGet()->vm() . "-test",
bTls => $oParam->{bTls},
strBackupDestination => $$oParam{strBackupDestination},
oLogTest => $$oParam{oLogTest},
bStandby => $$oParam{bStandby},
bRepoLocal => $oParam->{bRepoLocal},
bRepoEncrypt => $oParam->{bRepoEncrypt},

View File

@ -52,7 +52,6 @@ sub setup
{
my $self = shift;
my $bSynthetic = shift;
my $oLogTest = shift;
my $oConfigParam = shift;
# Start object server first since it takes the longest
@ -87,7 +86,7 @@ sub setup
$strBackupDestination = defined($$oConfigParam{strBackupDestination}) ? $$oConfigParam{strBackupDestination} : HOST_BACKUP;
$oHostBackup = new pgBackRestTest::Env::Host::HostBackupTest(
{strBackupDestination => $strBackupDestination, bSynthetic => $bSynthetic, oLogTest => $oLogTest,
{strBackupDestination => $strBackupDestination, bSynthetic => $bSynthetic,
bRepoLocal => $oConfigParam->{strStorage} eq POSIX, bRepoEncrypt => $bRepoEncrypt, bTls => $oConfigParam->{bTls}});
$oHostGroup->hostAdd($oHostBackup);
}
@ -103,14 +102,14 @@ sub setup
if ($bSynthetic)
{
$oHostDbPrimary = new pgBackRestTest::Env::Host::HostDbSyntheticTest(
{strBackupDestination => $strBackupDestination, oLogTest => $oLogTest,
{strBackupDestination => $strBackupDestination,
bRepoLocal => $oConfigParam->{strStorage} eq POSIX, bRepoEncrypt => $bRepoEncrypt, bTls => $oConfigParam->{bTls}});
}
else
{
$oHostDbPrimary = new pgBackRestTest::Env::Host::HostDbTest(
{strBackupDestination => $strBackupDestination, oLogTest => $oLogTest, bRepoLocal =>
$oConfigParam->{strStorage} eq POSIX, bRepoEncrypt => $bRepoEncrypt, bTls => $oConfigParam->{bTls}});
{strBackupDestination => $strBackupDestination, bRepoLocal => $oConfigParam->{strStorage} eq POSIX,
bRepoEncrypt => $bRepoEncrypt, bTls => $oConfigParam->{bTls}});
}
$oHostGroup->hostAdd($oHostDbPrimary);
@ -121,8 +120,8 @@ sub setup
if (defined($$oConfigParam{bStandby}) && $$oConfigParam{bStandby})
{
$oHostDbStandby = new pgBackRestTest::Env::Host::HostDbTest(
{strBackupDestination => $strBackupDestination, bStandby => true, oLogTest => $oLogTest,
bRepoLocal => $oConfigParam->{strStorage} eq POSIX, bTls => $oConfigParam->{bTls}});
{strBackupDestination => $strBackupDestination, bStandby => true, bRepoLocal => $oConfigParam->{strStorage} eq POSIX,
bTls => $oConfigParam->{bTls}});
$oHostGroup->hostAdd($oHostDbStandby);
}

View File

@ -229,7 +229,7 @@ sub run
# Create hosts, file object, and config
my ($oHostDbPrimary, $oHostDbStandby, $oHostBackup) = $self->setup(
true, $self->expect(),
true,
{bHostBackup => $bRemote, bTls => $bTls, strStorage => $strStorage, bRepoEncrypt => $bEncrypt,
strCompressType => NONE});
@ -439,8 +439,8 @@ sub run
#---------------------------------------------------------------------------------------------------------------------------
if ($self->runCurrent() == 1)
{
$oHostDbPrimary->executeSimple($self->backrestExe() . " version", {oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($self->backrestExe() . " help version", {oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($self->backrestExe() . " version");
$oHostDbPrimary->executeSimple($self->backrestExe() . " help version");
}
# Full backup
@ -851,12 +851,6 @@ sub run
$oManifest{&MANIFEST_SECTION_BACKUP_OPTION}{&MANIFEST_KEY_PROCESS_MAX} = $strStorage eq S3 ? 2 : 1;
if (!$bRemote)
{
# Remove the size-changed test file to avoid expect log churn
$oHostDbPrimary->manifestFileRemove(\%oManifest, MANIFEST_TARGET_PGDATA, 'changesize.txt');
}
# Drop tablespace 11
#---------------------------------------------------------------------------------------------------------------------------
$strType = CFGOPTVAL_BACKUP_TYPE_DIFF;
@ -1100,9 +1094,7 @@ sub run
#---------------------------------------------------------------------------------------------------------------------------
if (!$bRemote && $strStorage eq POSIX)
{
executeTest(
'ls -1Rtr ' . $oHostBackup->repoBackupPath(PATH_BACKUP_HISTORY),
{oLogTest => $self->expect(), bRemote => $bRemote});
executeTest('ls -1Rtr ' . $oHostBackup->repoBackupPath(PATH_BACKUP_HISTORY), {bRemote => $bRemote});
}
# Test backup from standby warning that standby not configured so option reset

View File

@ -69,7 +69,7 @@ sub run
# Create hosts, file object, and config
my ($oHostDbPrimary, $oHostDbStandby, $oHostBackup) = $self->setup(
true, $self->expect(),
true,
{bHostBackup => $bRemote, bTls => $bTls, strCompressType => $strCompressType, bArchiveAsync => true,
strStorage => $strStorage, bRepoEncrypt => $bEncrypt});

View File

@ -105,7 +105,7 @@ sub run
# Create hosts, file object, and config
my ($oHostDbPrimary, $oHostDbStandby, $oHostBackup) = $self->setup(
true, $self->expect(),
true,
{bHostBackup => $bRemote, bTls => $bTls, strStorage => $strStorage, bRepoEncrypt => $bEncrypt,
strCompressType => NONE});
@ -136,12 +136,10 @@ sub run
my $strArchiveFile1 = $self->walGenerate($strWalPath, PG_VERSION_94, 1, $strSourceFile1);
$oHostDbPrimary->executeSimple(
$strCommandPush . " ${strWalPath}/${strSourceFile1}",
{iExpectedExitStatus => ERROR_REPO_INVALID, oLogTest => $self->expect()});
$strCommandPush . " ${strWalPath}/${strSourceFile1}", {iExpectedExitStatus => ERROR_REPO_INVALID});
$oHostDbPrimary->executeSimple(
$strCommandGet . " ${strSourceFile1} ${strWalPath}/RECOVERYXLOG",
{iExpectedExitStatus => ERROR_REPO_INVALID, oLogTest => $self->expect()});
$strCommandGet . " ${strSourceFile1} ${strWalPath}/RECOVERYXLOG", {iExpectedExitStatus => ERROR_REPO_INVALID});
#---------------------------------------------------------------------------------------------------------------------------
$oHostBackup->stanzaCreate('stanza create', {strOptionalParam => '--no-online'});
@ -155,8 +153,7 @@ sub run
$oHostDbPrimary->executeSimple(
$strCommandPush . ($bRemote ? ' --cmd-ssh=/usr/bin/ssh' : '') .
" --compress-type=${strCompressType} ${strWalPath}/${strSourceFile}",
{oLogTest => $self->expect()});
" --compress-type=${strCompressType} ${strWalPath}/${strSourceFile}");
push(@stryExpectedWAL, "${strSourceFile}-${strArchiveChecksum}.${strCompressType}");
# Test that the WAL was pushed
@ -172,14 +169,13 @@ sub run
&log(INFO, ' get missing WAL');
$oHostDbPrimary->executeSimple(
$strCommandGet . " 700000007000000070000000 ${strWalPath}/RECOVERYXLOG",
{iExpectedExitStatus => 1, oLogTest => $self->expect()});
$strCommandGet . " 700000007000000070000000 ${strWalPath}/RECOVERYXLOG", {iExpectedExitStatus => 1});
#---------------------------------------------------------------------------------------------------------------------------
&log(INFO, ' get first WAL');
$oHostDbPrimary->executeSimple(
$strCommandGet . " ${strSourceFile} ${strWalPath}/RECOVERYXLOG", {oLogTest => $self->expect()});
$strCommandGet . " ${strSourceFile} ${strWalPath}/RECOVERYXLOG");
# Check that the destination file exists
if (storageTest()->exists("${strWalPath}/RECOVERYXLOG"))
@ -221,9 +217,7 @@ sub run
# Push the WAL
$oHostDbPrimary->executeSimple(
"${strCommandPush} --compress-type=${strCompressType} --archive-async --process-max=2" .
" ${strWalPath}/${strSourceFile}",
{oLogTest => $self->expect()});
"${strCommandPush} --compress-type=${strCompressType} --archive-async --process-max=2 ${strWalPath}/${strSourceFile}");
push(@stryExpectedWAL, "${strSourceFile}-${strArchiveChecksum}.${strCompressType}");
# Make sure the temp file no longer exists if it was created
@ -259,9 +253,7 @@ sub run
storageTest()->put("${strWalPath}/00000002.history", 'HISTORYDATA');
storageTest()->put("${strWalPath}/archive_status/00000002.history.ready", undef);
$oHostDbPrimary->executeSimple(
"${strCommandPush} --archive-async ${strWalPath}/00000002.history",
{oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple("${strCommandPush} --archive-async ${strWalPath}/00000002.history");
if (!storageRepo()->exists($oHostBackup->repoArchivePath(PG_VERSION_94 . '-1/00000002.history')))
{
@ -279,8 +271,7 @@ sub run
{&INFO_ARCHIVE_SECTION_DB_HISTORY => {'1' => {&INFO_ARCHIVE_KEY_DB_VERSION => '8.0'}}});
$oHostDbPrimary->executeSimple(
$strCommandGet . " ${strSourceFile1} ${strWalPath}/RECOVERYXLOG",
{iExpectedExitStatus => ERROR_REPO_INVALID, oLogTest => $self->expect()});
$strCommandGet . " ${strSourceFile1} ${strWalPath}/RECOVERYXLOG", {iExpectedExitStatus => ERROR_REPO_INVALID});
# Restore the file to its original condition
$oHostBackup->infoRestore($oHostBackup->repoArchivePath(ARCHIVE_INFO_FILE));
@ -294,12 +285,10 @@ sub run
&INFO_ARCHIVE_SECTION_DB_HISTORY => {'1' => {&INFO_ARCHIVE_KEY_DB_ID => 5000900090001855000}}});
$oHostDbPrimary->executeSimple(
$strCommandPush . " ${strWalPath}/${strSourceFile}",
{iExpectedExitStatus => ERROR_REPO_INVALID, oLogTest => $self->expect()});
$strCommandPush . " ${strWalPath}/${strSourceFile}", {iExpectedExitStatus => ERROR_REPO_INVALID});
$oHostDbPrimary->executeSimple(
$strCommandGet . " ${strSourceFile1} ${strWalPath}/RECOVERYXLOG",
{iExpectedExitStatus => ERROR_REPO_INVALID, oLogTest => $self->expect()});
$strCommandGet . " ${strSourceFile1} ${strWalPath}/RECOVERYXLOG", {iExpectedExitStatus => ERROR_REPO_INVALID});
# Restore the file to its original condition
$oHostBackup->infoRestore($oHostBackup->repoArchivePath(ARCHIVE_INFO_FILE));
@ -309,13 +298,10 @@ sub run
$oHostDbPrimary->stop({strStanza => $oHostDbPrimary->stanza()});
$oHostDbPrimary->executeSimple(
$strCommandPush . " ${strWalPath}/${strSourceFile}",
{iExpectedExitStatus => ERROR_STOP, oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($strCommandPush . " ${strWalPath}/${strSourceFile}", {iExpectedExitStatus => ERROR_STOP});
$oHostDbPrimary->executeSimple(
$strCommandGet . " ${strSourceFile1} ${strWalPath}/RECOVERYXLOG",
{iExpectedExitStatus => ERROR_STOP, oLogTest => $self->expect()});
$strCommandGet . " ${strSourceFile1} ${strWalPath}/RECOVERYXLOG", {iExpectedExitStatus => ERROR_STOP});
$oHostDbPrimary->start({strStanza => $oHostDbPrimary->stanza()});
@ -324,7 +310,7 @@ sub run
#---------------------------------------------------------------------------------------------------------------------------
&log(INFO, ' WAL duplicate ok');
$oHostDbPrimary->executeSimple($strCommandPush . " ${strWalPath}/${strSourceFile}", {oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($strCommandPush . " ${strWalPath}/${strSourceFile}");
#---------------------------------------------------------------------------------------------------------------------------
&log(INFO, ' WAL duplicate error');
@ -332,8 +318,7 @@ sub run
$strArchiveFile = $self->walGenerate($strWalPath, PG_VERSION_94, 1, $strSourceFile);
$oHostDbPrimary->executeSimple(
$strCommandPush . " ${strWalPath}/${strSourceFile}",
{iExpectedExitStatus => ERROR_ARCHIVE_DUPLICATE, oLogTest => $self->expect()});
$strCommandPush . " ${strWalPath}/${strSourceFile}", {iExpectedExitStatus => ERROR_ARCHIVE_DUPLICATE});
# Remove WAL
storageTest()->remove("${strWalPath}/${strSourceFile}", {bIgnoreMissing => false});
@ -343,8 +328,7 @@ sub run
$oHostDbPrimary->executeSimple(
$strCommandGet . ($bRemote ? ' --cmd-ssh=/usr/bin/ssh' : '') . " --archive-async" .
($strStorage eq POSIX ? " --repo-type=cifs" : '') . " ${strSourceFile} ${strWalPath}/RECOVERYXLOG",
{oLogTest => $self->expect()});
($strStorage eq POSIX ? " --repo-type=cifs" : '') . " ${strSourceFile} ${strWalPath}/RECOVERYXLOG");
# Check that the destination file exists
if (storageTest()->exists("${strWalPath}/RECOVERYXLOG"))
@ -365,12 +349,9 @@ sub run
&log(INFO, " get history file");
$oHostDbPrimary->executeSimple(
$strCommandGet . " --archive-async 00000001.history ${strWalPath}/00000001.history",
{iExpectedExitStatus => 1, oLogTest => $self->expect()});
$strCommandGet . " --archive-async 00000001.history ${strWalPath}/00000001.history", {iExpectedExitStatus => 1});
$oHostDbPrimary->executeSimple(
$strCommandGet . " --archive-async 00000002.history ${strWalPath}/00000002.history",
{oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($strCommandGet . " --archive-async 00000002.history ${strWalPath}/00000002.history");
if (${storageTest()->get("${strWalPath}/00000002.history")} ne 'HISTORYDATA')
{
@ -381,9 +362,7 @@ sub run
&log(INFO, ' .partial WAL');
$strArchiveFile = $self->walGenerate($strWalPath, PG_VERSION_94, 2, "${strSourceFile}.partial");
$oHostDbPrimary->executeSimple(
$strCommandPush . " ${strWalPath}/${strSourceFile}.partial",
{oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($strCommandPush . " ${strWalPath}/${strSourceFile}.partial");
$self->archiveCheck($oHostBackup, "${strSourceFile}.partial", $strArchiveChecksum);
push(@stryExpectedWAL, "${strSourceFile}.partial-${strArchiveChecksum}");
@ -391,8 +370,7 @@ sub run
#---------------------------------------------------------------------------------------------------------------------------
&log(INFO, ' .partial WAL duplicate');
$oHostDbPrimary->executeSimple(
$strCommandPush . " ${strWalPath}/${strSourceFile}.partial", {oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($strCommandPush . " ${strWalPath}/${strSourceFile}.partial");
$self->archiveCheck($oHostBackup, "${strSourceFile}.partial", $strArchiveChecksum);
#---------------------------------------------------------------------------------------------------------------------------
@ -400,8 +378,7 @@ sub run
$strArchiveFile = $self->walGenerate($strWalPath, PG_VERSION_94, 1, "${strSourceFile}.partial");
$oHostDbPrimary->executeSimple(
$strCommandPush . " ${strWalPath}/${strSourceFile}.partial",
{iExpectedExitStatus => ERROR_ARCHIVE_DUPLICATE, oLogTest => $self->expect()});
$strCommandPush . " ${strWalPath}/${strSourceFile}.partial", {iExpectedExitStatus => ERROR_ARCHIVE_DUPLICATE});
#---------------------------------------------------------------------------------------------------------------------------
$self->testResult(

View File

@ -57,21 +57,16 @@ sub run
my $strStorage = $rhRun->{storage};
my $bEncrypt = $rhRun->{encrypt};
if ($strStorage ne POSIX && ($self->vm() eq VM3))
{
confess &log("cannot configure non-posix storage for expect log tests");
}
############################################################################################################################
if ($self->begin("simple, enc ${bEncrypt}, storage ${strStorage}"))
{
# Create hosts, file object, and config
my ($oHostDbPrimary, $oHostDbStandby, $oHostBackup) = $self->setup(
true, $self->expect(), {strStorage => $strStorage, bRepoEncrypt => $bEncrypt});
true, {strStorage => $strStorage, bRepoEncrypt => $bEncrypt});
# Create the test object
my $oExpireTest = new pgBackRestTest::Env::ExpireEnvTest(
$oHostBackup, $self->backrestExe(), storageRepo(), $oHostDbPrimary->dbPath(), $self->expect(), $self);
$oHostBackup, $self->backrestExe(), storageRepo(), $oHostDbPrimary->dbPath(), $self);
$oExpireTest->stanzaCreate($self->stanza(), PG_VERSION_92);
@ -159,11 +154,11 @@ sub run
{
# Create hosts, file object, and config
my ($oHostDbPrimary, $oHostDbStandby, $oHostBackup) = $self->setup(
true, $self->expect(), {strStorage => $strStorage, bRepoEncrypt => $bEncrypt});
true, {strStorage => $strStorage, bRepoEncrypt => $bEncrypt});
# Create the test object
my $oExpireTest = new pgBackRestTest::Env::ExpireEnvTest(
$oHostBackup, $self->backrestExe(), storageRepo(), $oHostDbPrimary->dbPath(), $self->expect(), $self);
$oHostBackup, $self->backrestExe(), storageRepo(), $oHostDbPrimary->dbPath(), $self);
$oExpireTest->stanzaCreate($self->stanza(), PG_VERSION_92);

View File

@ -64,7 +64,7 @@ sub run
# Create hosts, file object, and config
my ($oHostDbPrimary, $oHostDbStandby, $oHostBackup) = $self->setup(
true, $self->expect(),
true,
{bHostBackup => $bRemote, bTls => $bTls, strStorage => $strStorage, bRepoEncrypt => $bEncrypt,
strCompressType => $strCompressType});
@ -129,7 +129,7 @@ sub run
my $strCommand = $oHostDbPrimary->backrestExe() . ' --config=' . $oHostDbPrimary->backrestConfig() .
' --stanza=db archive-push';
$oHostDbPrimary->executeSimple($strCommand . " ${strSourceFile}", {oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($strCommand . " ${strSourceFile}");
# With data existing in the archive dir, move the info files and confirm failure
forceStorageMove(storageRepo(), $strArchiveInfoFile, $strArchiveInfoOldFile, {bRecurse => false});
@ -149,7 +149,7 @@ sub run
#--------------------------------------------------------------------------------------------------------------------------
$strArchiveFile = $self->walSegment(1, 1, 2);
$strSourceFile = $self->walGenerate($strWalPath, PG_VERSION_93, 1, $strArchiveFile);
$oHostDbPrimary->executeSimple($strCommand . " ${strSourceFile}", {oLogTest => $self->expect()});
$oHostDbPrimary->executeSimple($strCommand . " ${strSourceFile}");
# Fail on archive push due to mismatch of DB since stanza not upgraded
#--------------------------------------------------------------------------------------------------------------------------
@ -178,8 +178,7 @@ sub run
# Attempt to get the last archive log that was pushed to this repo
$oHostDbPrimary->executeSimple(
$oHostDbPrimary->backrestExe() . ' --config=' . $oHostDbPrimary->backrestConfig() .
" --stanza=db archive-get ${strArchiveFile} " . $oHostDbPrimary->dbBasePath() . '/pg_xlog/RECOVERYXLOG',
{oLogTest => $self->expect()});
" --stanza=db archive-get ${strArchiveFile} " . $oHostDbPrimary->dbBasePath() . '/pg_xlog/RECOVERYXLOG');
# Copy the new pg_control back so the tests can continue with the upgraded stanza
$self->controlGenerate($oHostDbPrimary->dbBasePath(), PG_VERSION_94);

View File

@ -81,22 +81,20 @@ sub run
my $iRepoTotal = $rhRun->{repo};
my $bBundle = $rhRun->{bnd};
# Use a specific VM and version of PostgreSQL for expect testing. This version will also be used to run tests that are not
# version specific.
my $bExpectVersion = $self->vm() eq VM_EXPECT && $self->pgVersion() eq PG_VERSION_96;
# Some tests are not version specific so only run them on a single version of PostgreSQL
my $bNonVersionSpecific = $self->pgVersion() eq PG_VERSION_96;
# Increment the run, log, and decide whether this unit test should be run
next if (!$self->begin(
next if !$self->begin(
"bkp ${bHostBackup}, sby ${bHostStandby}, tls ${bTls}, dst ${strBackupDestination}, cmp ${strCompressType}" .
", storage ${strStorage}, enc ${bRepoEncrypt}",
$bExpectVersion));
", storage ${strStorage}, enc ${bRepoEncrypt}");
# Create hosts, file object, and config
my ($oHostDbPrimary, $oHostDbStandby, $oHostBackup) = $self->setup(
false, $self->expect(),
false,
{bHostBackup => $bHostBackup, bStandby => $bHostStandby, bTls => $bTls, strBackupDestination => $strBackupDestination,
strCompressType => $strCompressType, bArchiveAsync => false, strStorage => $strStorage,
bRepoEncrypt => $bRepoEncrypt, iRepoTotal => $iRepoTotal, bBundle => $bBundle});
strCompressType => $strCompressType, bArchiveAsync => false, strStorage => $strStorage,
bRepoEncrypt => $bRepoEncrypt, iRepoTotal => $iRepoTotal, bBundle => $bBundle});
# Some commands will fail because of the bogus host created when a standby is present. These options reset the bogus host
# so it won't interfere with commands that won't tolerate a connection failure.
@ -209,9 +207,9 @@ sub run
}
# Make a new backup with expire-auto disabled then run the expire command and compare backup numbers to ensure that expire
# was really disabled. This test is not version specific so is run on only the expect version.
# was really disabled. This test is not version specific so is run on only one version.
#---------------------------------------------------------------------------------------------------------------------------
if ($bExpectVersion)
if ($bNonVersionSpecific)
{
my $oBackupInfo = new pgBackRestTest::Env::BackupInfo($oHostBackup->repoBackupPath());
push(my @backupLst1, $oBackupInfo->list());
@ -350,8 +348,8 @@ sub run
#---------------------------------------------------------------------------------------------------------------------------
# Restart the cluster to check for any errors before continuing since the stop tests will definitely create errors and the
# logs will need to be deleted to avoid causing issues further down the line. This test is not version specific so is run on
# only the expect version.
if ($bExpectVersion)
# only one version.
if ($bNonVersionSpecific)
{
confess "test must be performed on posix storage" if $strStorage ne POSIX;
@ -752,9 +750,9 @@ sub run
$oHostDbPrimary->clusterStop();
# Stanza-delete --force without access to pgbackrest on database host. This test is not version specific so is run on only
# the expect version.
# one version.
#---------------------------------------------------------------------------------------------------------------------------
if ($bExpectVersion)
if ($bNonVersionSpecific)
{
# Make sure this test has a backup host to work with
confess "test must run with backup dst = " . HOST_BACKUP if !$bHostBackup;

View File

@ -70,7 +70,6 @@ test.pl [options]
--clean clean working and result paths for a completely fresh build
--clean-only execute --clean and exit
--pg-version version of postgres to test (all, defaults to minimal)
--log-force force overwrite of current test log files
--build-only build the binary (and honor --build-package) but don't run tests
--build-package build the package
--build-max max processes to use for builds (default 4)
@ -81,7 +80,6 @@ test.pl [options]
--no-gen do not run code generation
--gen-check check that auto-generated files are correct (used in CI to detect changes)
--code-count generate code counts
--expect --vm=rh7 --pg-version=9.6 --log-force
--no-valgrind don't run valgrind on C unit tests (saves time)
--no-coverage don't run coverage on C unit tests (saves time)
--no-coverage-report run coverage but don't generate coverage report (saves time)
@ -143,7 +141,6 @@ my $bVersion = false;
my $bHelp = false;
my $bQuiet = false;
my $strPgVersion = 'minimal';
my $bLogForce = false;
my $strVm;
my $bVmBuild = false;
my $bVmForce = false;
@ -163,7 +160,6 @@ my $bNoGen = false;
my $bCodeCount = false;
my $bBackTrace = false;
my $bProfile = false;
my $bExpect = false;
my $bNoValgrind = false;
my $bNoOptimize = false;
my $bNoDebug = false;
@ -198,7 +194,6 @@ GetOptions ('q|quiet' => \$bQuiet,
'dry-run' => \$bDryRun,
'no-cleanup' => \$bNoCleanup,
'pg-version=s' => \$strPgVersion,
'log-force' => \$bLogForce,
'build-only' => \$bBuildOnly,
'build-package' => \$bBuildPackage,
'build-max=s' => \$iBuildMax,
@ -215,7 +210,6 @@ GetOptions ('q|quiet' => \$bQuiet,
'code-count' => \$bCodeCount,
'backtrace' => \$bBackTrace,
'profile' => \$bProfile,
'expect' => \$bExpect,
'no-valgrind' => \$bNoValgrind,
'no-optimize' => \$bNoOptimize,
'no-debug', => \$bNoDebug,
@ -279,16 +273,6 @@ eval
$bNoCoverage = true;
}
################################################################################################################################
# Update options for --expect
################################################################################################################################
if ($bExpect)
{
$strVm = VM_EXPECT;
$strPgVersion = '9.6';
$bLogForce = true;
}
################################################################################################################################
# Setup
################################################################################################################################
@ -1032,8 +1016,8 @@ eval
my $oJob = new pgBackRestTest::Common::JobTest(
$oStorageTest, $strBackRestBase, $strTestPath, $$oyTestRun[$iTestIdx], $bDryRun, $bVmOut, $iVmIdx, $iVmMax,
$strMakeCmd, $iTestIdx, $iTestMax, $strLogLevel, $strLogLevelTest, $strLogLevelTestFile, !$bNoLogTimestamp,
$bLogForce, $bShowOutputAsync, $bNoCleanup, $iRetry, !$bNoValgrind, !$bNoCoverage, $bCoverageSummary,
!$bNoOptimize, $bBackTrace, $bProfile, $iScale, $strTimeZone, !$bNoDebug, $bDebugTestTrace,
$bShowOutputAsync, $bNoCleanup, $iRetry, !$bNoValgrind, !$bNoCoverage, $bCoverageSummary, !$bNoOptimize,
$bBackTrace, $bProfile, $iScale, $strTimeZone, !$bNoDebug, $bDebugTestTrace,
$iBuildMax / $iVmMax < 1 ? 1 : int($iBuildMax / $iVmMax));
$iTestIdx++;
@ -1096,7 +1080,7 @@ eval
$strPgVersion ne 'minimal' ? $strPgSqlBin: undef, # Pg bin path
$strPgVersion ne 'minimal' ? $strPgVersion: undef, # Pg version
$stryModule[0], $stryModuleTest[0], \@iyModuleTestRun, # Module info
$bVmOut, $bDryRun, $bNoCleanup, $bLogForce, # Test options
$bVmOut, $bDryRun, $bNoCleanup, # Test options
$strLogLevelTestFile, # Log options
TEST_USER, TEST_GROUP); # User/group info