mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2024-12-14 10:13:05 +02:00
Merge branch 'dev-0.30' of https://github.com/dwsteele/pg_backrest into dev
This commit is contained in:
commit
5f30ae3c46
@ -85,7 +85,7 @@ use constant
|
||||
CONFIG_KEY_HARDLINK => 'hardlink',
|
||||
CONFIG_KEY_ARCHIVE_REQUIRED => 'archive-required',
|
||||
CONFIG_KEY_ARCHIVE_MAX_MB => 'archive-max-mb',
|
||||
CONFIG_KEY_START_FAST => 'start_fast',
|
||||
CONFIG_KEY_START_FAST => 'start-fast',
|
||||
CONFIG_KEY_COMPRESS_ASYNC => 'compress-async',
|
||||
|
||||
CONFIG_KEY_LEVEL_FILE => 'level-file',
|
||||
@ -591,7 +591,7 @@ if ($strOperation eq OP_ARCHIVE_GET)
|
||||
&log(INFO, 'getting archive log ' . $ARGV[1]);
|
||||
|
||||
# Get the archive file
|
||||
remote_exit(archive_get($ARGV[1], $ARGV[2]));
|
||||
remote_exit(archive_get(config_key_load(CONFIG_SECTION_STANZA, CONFIG_KEY_PATH), $ARGV[1], $ARGV[2]));
|
||||
}
|
||||
|
||||
####################################################################################################################################
|
||||
|
@ -229,9 +229,21 @@ sub backup_thread_complete
|
||||
####################################################################################################################################
|
||||
sub archive_get
|
||||
{
|
||||
my $strDbClusterPath = shift;
|
||||
my $strSourceArchive = shift;
|
||||
my $strDestinationFile = shift;
|
||||
|
||||
# If the destination file path is not absolute then it is relative to the data path
|
||||
if (index($strDestinationFile, '/',) != 0)
|
||||
{
|
||||
if (!defined($strDbClusterPath))
|
||||
{
|
||||
confess &log(ERROR, 'database path must be set if relative xlog paths are used');
|
||||
}
|
||||
|
||||
$strDestinationFile = "${strDbClusterPath}/${strDestinationFile}";
|
||||
}
|
||||
|
||||
# Determine the path where the requested archive file is located
|
||||
my $strArchivePath = dirname($oFile->path_get(PATH_BACKUP_ARCHIVE, $strSourceArchive));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user