diff --git a/doc/pgprobackup.xml b/doc/pgprobackup.xml
index 95dd1a1d..f8f269b7 100644
--- a/doc/pgprobackup.xml
+++ b/doc/pgprobackup.xml
@@ -1146,7 +1146,7 @@ pg_probackup add-instance -B backup_dir -D backup_dir directory and at least read-only
access to data_dir directory. If you
specify the path to the backup catalog in the
- BACKUP_DIR environment variable, you can
+ BACKUP_PATH environment variable, you can
omit the corresponding option when running pg_probackup
commands.
@@ -5205,14 +5205,14 @@ pg_probackup catchup -b catchup_mode
-BACKUP_DIR
+BACKUP_PATH
Specifies the absolute path to the backup catalog. Backup
catalog is a directory where all backup files and meta
information are stored. Since this option is required for most
of the pg_probackup commands, you are recommended to specify
- it once in the BACKUP_DIR environment variable. In this case,
+ it once in the BACKUP_PATH environment variable. In this case,
you do not need to use this option each time on the command
line.
@@ -5672,7 +5672,7 @@ pg_probackup catchup -b catchup_mode
lazily, when the first log message is written.
- Default: $BACKUP_DIR/log/
+ Default: $BACKUP_PATH/log/
@@ -5755,7 +5755,7 @@ pg_probackup catchup -b catchup_mode
reached, the log file is rotated once a pg_probackup command
is launched, except help and version commands. The time of the
last log file creation is stored in
- $BACKUP_DIR/log/log_rotation. The zero value disables
+ $BACKUP_PATH/log/log_rotation. The zero value disables
time-based rotation. Supported units: ms, s, min, h, d (min by
default).
diff --git a/po/ru.po b/po/ru.po
index 30f50f79..1263675c 100644
--- a/po/ru.po
+++ b/po/ru.po
@@ -811,7 +811,7 @@ msgstr ""
#: src/help.c:360 src/help.c:521 src/help.c:588 src/help.c:635 src/help.c:715
#: src/help.c:761 src/help.c:833
#, c-format
-msgid " directory for file logging (default: BACKUP_DIR/log)\n"
+msgid " directory for file logging (default: BACKUP_PATH/log)\n"
msgstr ""
#: src/help.c:361 src/help.c:522 src/help.c:589 src/help.c:636 src/help.c:716
diff --git a/src/archive.c b/src/archive.c
index e97a1ade..7d753c8b 100644
--- a/src/archive.c
+++ b/src/archive.c
@@ -113,7 +113,7 @@ static parray *setup_push_filelist(const char *archive_status_dir,
* set archive_command to
* 'pg_probackup archive-push -B /home/anastasia/backup --wal-file-name %f',
* to move backups into arclog_path.
- * Where archlog_path is $BACKUP_DIR/wal/instance_name
+ * Where archlog_path is $BACKUP_PATH/wal/instance_name
*/
void
do_archive_push(InstanceState *instanceState, InstanceConfig *instance, char *pg_xlog_dir,
@@ -1126,7 +1126,7 @@ do_archive_get(InstanceState *instanceState, InstanceConfig *instance, const cha
join_path_components(absolute_wal_file_path, current_dir, wal_file_path);
/* full filepath to WAL file in archive directory.
- * $BACKUP_DIR/wal/instance_name/000000010000000000000001 */
+ * $BACKUP_PATH/wal/instance_name/000000010000000000000001 */
join_path_components(backup_wal_file_path, instanceState->instance_wal_subdir_path, wal_file_name);
INSTR_TIME_SET_CURRENT(start_time);
diff --git a/src/catalog.c b/src/catalog.c
index 4da406af..b2909078 100644
--- a/src/catalog.c
+++ b/src/catalog.c
@@ -1437,7 +1437,7 @@ get_multi_timeline_parent(parray *backup_list, parray *tli_list,
}
/*
- * Create backup directory in $BACKUP_DIR
+ * Create backup directory in $BACKUP_PATH
* (with proposed backup->backup_id)
* and initialize this directory.
* If creation of directory fails, then
diff --git a/src/help.c b/src/help.c
index 48cc1f52..e18706a1 100644
--- a/src/help.c
+++ b/src/help.c
@@ -372,7 +372,7 @@ help_backup(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -548,7 +548,7 @@ help_restore(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -621,7 +621,7 @@ help_validate(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -674,7 +674,7 @@ help_checkdb(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -760,7 +760,7 @@ help_delete(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -814,7 +814,7 @@ help_merge(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -890,7 +890,7 @@ help_set_config(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -1002,7 +1002,7 @@ help_add_instance(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -1072,7 +1072,7 @@ help_archive_push(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -1131,7 +1131,7 @@ help_archive_get(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
@@ -1221,7 +1221,7 @@ help_catchup(void)
printf(_(" --error-log-filename=error-log-filename\n"));
printf(_(" filename for error logging (default: none)\n"));
printf(_(" --log-directory=log-directory\n"));
- printf(_(" directory for file logging (default: BACKUP_DIR/log)\n"));
+ printf(_(" directory for file logging (default: BACKUP_PATH/log)\n"));
printf(_(" --log-rotation-size=log-rotation-size\n"));
printf(_(" rotate logfile if its size exceeds this value; 0 disables; (default: 0)\n"));
printf(_(" available units: 'kB', 'MB', 'GB', 'TB' (default: kB)\n"));
diff --git a/src/pg_probackup.c b/src/pg_probackup.c
index e50b0599..fa67ddff 100644
--- a/src/pg_probackup.c
+++ b/src/pg_probackup.c
@@ -468,10 +468,10 @@ main(int argc, char *argv[])
if (backup_path == NULL)
{
/*
- * If command line argument is not set, try to read BACKUP_DIR
+ * If command line argument is not set, try to read BACKUP_PATH
* from environment variable
*/
- backup_path = getenv("BACKUP_DIR");
+ backup_path = getenv("BACKUP_PATH");
}
if (backup_path != NULL)
@@ -498,7 +498,7 @@ main(int argc, char *argv[])
backup_subcmd != CATCHUP_CMD)
elog(ERROR,
"No backup catalog path specified.\n"
- "Please specify it either using environment variable BACKUP_DIR or\n"
+ "Please specify it either using environment variable BACKUP_PATH or\n"
"command line option --backup-path (-B)");
/* ===== catalogState (END) ======*/
diff --git a/src/pg_probackup.h b/src/pg_probackup.h
index 1f4780f5..668f183a 100644
--- a/src/pg_probackup.h
+++ b/src/pg_probackup.h
@@ -837,13 +837,13 @@ typedef struct InstanceState
CatalogState *catalog_state;
char instance_name[MAXPGPATH]; //previously global var instance_name
- /* $BACKUP_DIR/backups/instance_name */
+ /* $BACKUP_PATH/backups/instance_name */
char instance_backup_subdir_path[MAXPGPATH];
- /* $BACKUP_DIR/backups/instance_name/BACKUP_CATALOG_CONF_FILE */
+ /* $BACKUP_PATH/backups/instance_name/BACKUP_CATALOG_CONF_FILE */
char instance_config_path[MAXPGPATH];
-
- /* $BACKUP_DIR/backups/instance_name */
+
+ /* $BACKUP_PATH/backups/instance_name */
char instance_wal_subdir_path[MAXPGPATH]; // previously global var arclog_path
/* TODO: Make it more specific */
diff --git a/src/pg_probackup_state.h b/src/pg_probackup_state.h
index 1d1ff88d..56d85253 100644
--- a/src/pg_probackup_state.h
+++ b/src/pg_probackup_state.h
@@ -13,11 +13,11 @@
typedef struct CatalogState
{
- /* $BACKUP_DIR */
+ /* $BACKUP_PATH */
char catalog_path[MAXPGPATH]; //previously global var backup_path
- /* $BACKUP_DIR/backups */
+ /* $BACKUP_PATH/backups */
char backup_subdir_path[MAXPGPATH];
- /* $BACKUP_DIR/wal */
+ /* $BACKUP_PATH/wal */
char wal_subdir_path[MAXPGPATH]; // previously global var arclog_path
} CatalogState;
diff --git a/tests/option_test.py b/tests/option_test.py
index e97da1ef..d1e8cb3a 100644
--- a/tests/option_test.py
+++ b/tests/option_test.py
@@ -25,7 +25,7 @@ class OptionTest(ProbackupTest, unittest.TestCase):
except ProbackupException as e:
self.assertIn(
'ERROR: No backup catalog path specified.\n' + \
- 'Please specify it either using environment variable BACKUP_DIR or\n' + \
+ 'Please specify it either using environment variable BACKUP_PATH or\n' + \
'command line option --backup-path (-B)',
e.message,
'\n Unexpected Error Message: {0}\n CMD: {1}'.format(repr(e.message), self.cmd))