|
1 | 1 | /*------------------------------------------------------------------------- |
2 | 2 | * |
3 | | - * archive.c: - pg_probackup specific archive commands for archive backups. |
| 3 | + * archive.c: - pg_backup specific archive commands for archive backups. |
4 | 4 | * |
5 | 5 | * |
6 | 6 | * Portions Copyright (c) 2018-2022, Postgres Professional |
@@ -106,9 +106,9 @@ static parray *setup_push_filelist(const char *archive_status_dir, |
106 | 106 | * At this point, we already done one roundtrip to archive server |
107 | 107 | * to get instance config. |
108 | 108 | * |
109 | | - * pg_probackup specific archive command for archive backups |
| 109 | + * pg_backup specific archive command for archive backups |
110 | 110 | * set archive_command to |
111 | | - * 'pg_probackup archive-push -B /home/anastasia/backup --wal-file-name %f', |
| 111 | + * 'pg_backup archive-push -B /home/anastasia/backup --wal-file-name %f', |
112 | 112 | * to move backups into arclog_path. |
113 | 113 | * Where archlog_path is $BACKUP_PATH/wal/instance_name |
114 | 114 | */ |
@@ -154,9 +154,9 @@ do_archive_push(InstanceState *instanceState, InstanceConfig *instance, char *pg |
154 | 154 | if (num_threads > parray_num(batch_files)) |
155 | 155 | n_threads = parray_num(batch_files); |
156 | 156 |
|
157 | | - elog(INFO, "pg_probackup archive-push WAL file: %s, " |
| 157 | + elog(INFO, "%s archive-push WAL file: %s, " |
158 | 158 | "threads: %i/%i, batch: %lu/%i, compression: %s", |
159 | | - wal_file_name, n_threads, num_threads, |
| 159 | + PROGRAM_NAME, wal_file_name, n_threads, num_threads, |
160 | 160 | parray_num(batch_files), batch_size, |
161 | 161 | is_compress ? "zlib" : "none"); |
162 | 162 |
|
@@ -265,13 +265,13 @@ do_archive_push(InstanceState *instanceState, InstanceConfig *instance, char *pg |
265 | 265 |
|
266 | 266 | if (push_isok) |
267 | 267 | /* report number of files pushed into archive */ |
268 | | - elog(INFO, "pg_probackup archive-push completed successfully, " |
| 268 | + elog(INFO, "%s archive-push completed successfully, " |
269 | 269 | "pushed: %u, skipped: %u, time elapsed: %s", |
270 | | - n_total_pushed, n_total_skipped, pretty_time_str); |
| 270 | + PROGRAM_NAME, n_total_pushed, n_total_skipped, pretty_time_str); |
271 | 271 | else |
272 | | - elog(ERROR, "pg_probackup archive-push failed, " |
| 272 | + elog(ERROR, "%s archive-push failed, " |
273 | 273 | "pushed: %i, skipped: %u, failed: %u, time elapsed: %s", |
274 | | - n_total_pushed, n_total_skipped, n_total_failed, |
| 274 | + PROGRAM_NAME, n_total_pushed, n_total_skipped, n_total_failed, |
275 | 275 | pretty_time_str); |
276 | 276 | } |
277 | 277 |
|
@@ -968,7 +968,7 @@ setup_push_filelist(const char *archive_status_dir, const char *first_file, |
968 | 968 | } |
969 | 969 |
|
970 | 970 | /* |
971 | | - * pg_probackup specific restore command. |
| 971 | + * pg_backup specific restore command. |
972 | 972 | * Move files from arclog_path to pgdata/wal_file_path. |
973 | 973 | * |
974 | 974 | * The problem with archive-get: we must be very careful about |
@@ -1027,8 +1027,8 @@ do_archive_get(InstanceState *instanceState, InstanceConfig *instance, const cha |
1027 | 1027 | INSTR_TIME_SET_CURRENT(start_time); |
1028 | 1028 | if (num_threads > batch_size) |
1029 | 1029 | n_actual_threads = batch_size; |
1030 | | - elog(INFO, "pg_probackup archive-get WAL file: %s, remote: %s, threads: %i/%i, batch: %i", |
1031 | | - wal_file_name, IsSshProtocol() ? "ssh" : "none", n_actual_threads, num_threads, batch_size); |
| 1030 | + elog(INFO, "%s archive-get WAL file: %s, remote: %s, threads: %i/%i, batch: %i", |
| 1031 | + PROGRAM_NAME, wal_file_name, IsSshProtocol() ? "ssh" : "none", n_actual_threads, num_threads, batch_size); |
1032 | 1032 |
|
1033 | 1033 | num_threads = n_actual_threads; |
1034 | 1034 |
|
@@ -1084,8 +1084,8 @@ do_archive_get(InstanceState *instanceState, InstanceConfig *instance, const cha |
1084 | 1084 | validate_wal)) |
1085 | 1085 | { |
1086 | 1086 | n_files_in_prefetch--; |
1087 | | - elog(INFO, "pg_probackup archive-get used prefetched WAL segment %s, prefetch state: %u/%u", |
1088 | | - wal_file_name, n_files_in_prefetch, batch_size); |
| 1087 | + elog(INFO, "%s archive-get used prefetched WAL segment %s, prefetch state: %u/%u", |
| 1088 | + PROGRAM_NAME, wal_file_name, n_files_in_prefetch, batch_size); |
1089 | 1089 | goto get_done; |
1090 | 1090 | } |
1091 | 1091 | else |
@@ -1122,8 +1122,8 @@ do_archive_get(InstanceState *instanceState, InstanceConfig *instance, const cha |
1122 | 1122 | instance->xlog_seg_size, validate_wal)) |
1123 | 1123 | { |
1124 | 1124 | n_files_in_prefetch--; |
1125 | | - elog(INFO, "pg_probackup archive-get copied WAL file %s, prefetch state: %u/%u", |
1126 | | - wal_file_name, n_files_in_prefetch, batch_size); |
| 1125 | + elog(INFO, "%s archive-get copied WAL file %s, prefetch state: %u/%u", |
| 1126 | + PROGRAM_NAME, wal_file_name, n_files_in_prefetch, batch_size); |
1127 | 1127 | goto get_done; |
1128 | 1128 | } |
1129 | 1129 | // else |
@@ -1154,7 +1154,7 @@ do_archive_get(InstanceState *instanceState, InstanceConfig *instance, const cha |
1154 | 1154 | if (get_wal_file(wal_file_name, backup_wal_file_path, absolute_wal_file_path, false)) |
1155 | 1155 | { |
1156 | 1156 | fail_count = 0; |
1157 | | - elog(LOG, "pg_probackup archive-get copied WAL file %s", wal_file_name); |
| 1157 | + elog(LOG, "%s archive-get copied WAL file %s", PROGRAM_NAME, wal_file_name); |
1158 | 1158 | n_fetched++; |
1159 | 1159 | break; |
1160 | 1160 | } |
@@ -1182,11 +1182,11 @@ do_archive_get(InstanceState *instanceState, InstanceConfig *instance, const cha |
1182 | 1182 | pretty_time_interval(get_time, pretty_time_str, 20); |
1183 | 1183 |
|
1184 | 1184 | if (fail_count == 0) |
1185 | | - elog(INFO, "pg_probackup archive-get completed successfully, fetched: %i/%i, time elapsed: %s", |
1186 | | - n_fetched, batch_size, pretty_time_str); |
| 1185 | + elog(INFO, "%s archive-get completed successfully, fetched: %i/%i, time elapsed: %s", |
| 1186 | + PROGRAM_NAME, n_fetched, batch_size, pretty_time_str); |
1187 | 1187 | else |
1188 | | - elog(ERROR, "pg_probackup archive-get failed to deliver WAL file: %s, time elapsed: %s", |
1189 | | - wal_file_name, pretty_time_str); |
| 1188 | + elog(ERROR, "%s archive-get failed to deliver WAL file: %s, time elapsed: %s", |
| 1189 | + PROGRAM_NAME, wal_file_name, pretty_time_str); |
1190 | 1190 | } |
1191 | 1191 |
|
1192 | 1192 | /* |
|
0 commit comments