From 1c81e7569930723aa8167e7de7e43fcfe010e3ca Mon Sep 17 00:00:00 2001 From: Grigory Smolkin Date: Wed, 29 Apr 2020 14:27:36 +0300 Subject: [PATCH] minor improvements --- src/data.c | 5 ++++- tests/expected/option_help.out | 21 +++++++++++++++------ 2 files changed, 19 insertions(+), 7 deletions(-) diff --git a/src/data.c b/src/data.c index aa3c0a6e..7628c37e 100644 --- a/src/data.c +++ b/src/data.c @@ -821,8 +821,11 @@ backup_non_data_file(pgFile *file, pgFile *prev_file, { /* special treatment for global/pg_control */ if (file->external_dir_num == 0 && strcmp(file->rel_path, XLOG_CONTROL_FILE) == 0) - return copy_pgcontrol_file(from_fullpath, FIO_DB_HOST, + { + copy_pgcontrol_file(from_fullpath, FIO_DB_HOST, to_fullpath, FIO_BACKUP_HOST, file); + return; + } /* * If non-data file exists in previous backup diff --git a/tests/expected/option_help.out b/tests/expected/option_help.out index da7ebcd1..aaf66353 100644 --- a/tests/expected/option_help.out +++ b/tests/expected/option_help.out @@ -32,7 +32,8 @@ pg_probackup - utility to manage backup/recovery of PostgreSQL database. [--help] pg_probackup set-backup -B backup-path --instance=instance_name - -i backup-id [--ttl] [--expire-time] + -i backup-id [--ttl=interval] [--expire-time=timestamp] + [--note=text] [--help] pg_probackup show-config -B backup-path --instance=instance_name @@ -45,6 +46,7 @@ pg_probackup - utility to manage backup/recovery of PostgreSQL database. [--backup-pg-log] [-j num-threads] [--progress] [--no-validate] [--skip-block-validation] [--external-dirs=external-directories-paths] + [--no-sync] [--log-level-console=log-level-console] [--log-level-file=log-level-file] [--log-filename=log-filename] @@ -65,7 +67,7 @@ pg_probackup - utility to manage backup/recovery of PostgreSQL database. [--remote-proto] [--remote-host] [--remote-port] [--remote-path] [--remote-user] [--ssh-options] - [--ttl] [--expire-time] + [--ttl=interval] [--expire-time=timestamp] [--note=text] [--help] pg_probackup restore -B backup-path --instance=instance_name @@ -77,10 +79,13 @@ pg_probackup - utility to manage backup/recovery of PostgreSQL database. [--recovery-target-name=target-name] [--recovery-target-action=pause|promote|shutdown] [--restore-as-replica] [--force] + [--primary-conninfo=primary_conninfo] + [-S | --primary-slot-name=slotname] [--no-validate] [--skip-block-validation] [-T OLDDIR=NEWDIR] [--progress] [--external-mapping=OLDDIR=NEWDIR] [--skip-external-dirs] [--restore-command=cmdline] + [--no-sync] [--db-include | --db-exclude] [--remote-proto] [--remote-host] [--remote-port] [--remote-path] [--remote-user] @@ -114,7 +119,8 @@ pg_probackup - utility to manage backup/recovery of PostgreSQL database. [--retention-redundancy=retention-redundancy] [--retention-window=retention-window] [--wal-depth=wal-depth] - [--delete-wal] [-i backup-id | --delete-expired | --merge-expired] + [-i backup-id | --delete-expired | --merge-expired | --status=backup_status] + [--delete-wal] [--dry-run] [--help] @@ -135,10 +141,11 @@ pg_probackup - utility to manage backup/recovery of PostgreSQL database. [--help] pg_probackup archive-push -B backup-path --instance=instance_name - --wal-file-path=wal-file-path --wal-file-name=wal-file-name - [--overwrite] - [--compress] + [-j num-threads] [--batch-size=batch_size] + [--archive-timeout=timeout] + [--no-ready-rename] [--no-sync] + [--overwrite] [--compress] [--compress-algorithm=compress-algorithm] [--compress-level=compress-level] [--remote-proto] [--remote-host] @@ -149,6 +156,8 @@ pg_probackup - utility to manage backup/recovery of PostgreSQL database. pg_probackup archive-get -B backup-path --instance=instance_name --wal-file-path=wal-file-path --wal-file-name=wal-file-name + [-j num-threads] [--batch-size=batch_size] + [--no-validate-wal] [--remote-proto] [--remote-host] [--remote-port] [--remote-path] [--remote-user] [--ssh-options]