diff options
author | Magnus Hagander <magnus@hagander.net> | 2017-02-26 21:27:51 +0100 |
---|---|---|
committer | Magnus Hagander <magnus@hagander.net> | 2017-02-26 21:31:54 +0100 |
commit | 51e26c9c3d2904b65041fc4a19c72c62508f63d4 (patch) | |
tree | 7b681c907c72cd50873a04f9b3ee94c85c4cba6c /src | |
parent | caa6c1f193a9ab4b4fb9b8687f41e6d66bbeaade (diff) | |
download | postgresql-51e26c9c3d2904b65041fc4a19c72c62508f63d4.tar.gz postgresql-51e26c9c3d2904b65041fc4a19c72c62508f63d4.zip |
Clarify the role of checkpoint at the begininng of base backups
Output a message about checkpoint starting in verbose mode of
pg_basebackup, and make the documentation state more clearly that this
happens.
Author: Michael Banck
Diffstat (limited to 'src')
-rw-r--r-- | src/bin/pg_basebackup/pg_basebackup.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/bin/pg_basebackup/pg_basebackup.c b/src/bin/pg_basebackup/pg_basebackup.c index bc997dc9973..761679a4d08 100644 --- a/src/bin/pg_basebackup/pg_basebackup.c +++ b/src/bin/pg_basebackup/pg_basebackup.c @@ -1753,6 +1753,14 @@ BaseBackup(void) if (maxrate > 0) maxrate_clause = psprintf("MAX_RATE %u", maxrate); + if (verbose) + fprintf(stderr, + _("%s: initiating base backup, waiting for checkpoint to complete\n"), + progname); + + if (showprogress && !verbose) + fprintf(stderr, "waiting for checkpoint\n"); + basebkp = psprintf("BASE_BACKUP LABEL '%s' %s %s %s %s %s %s", escaped_label, @@ -1790,6 +1798,9 @@ BaseBackup(void) strlcpy(xlogstart, PQgetvalue(res, 0, 0), sizeof(xlogstart)); + if (verbose) + fprintf(stderr, _("%s: checkpoint completed\n"), progname); + /* * 9.3 and later sends the TLI of the starting point. With older servers, * assume it's the same as the latest timeline reported by |