aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFujii Masao <fujii@postgresql.org>2015-09-24 23:31:17 +0900
committerFujii Masao <fujii@postgresql.org>2015-09-24 23:31:44 +0900
commiteac3b3365e6220ce03bc05914c8e7f5430341373 (patch)
tree2e5327bd4397a5c38f410a55870ebd1a343f49ab /src
parentef4fccd2b6a60bdf89a4300741028218e36461aa (diff)
downloadpostgresql-eac3b3365e6220ce03bc05914c8e7f5430341373.tar.gz
postgresql-eac3b3365e6220ce03bc05914c8e7f5430341373.zip
Make pg_controldata report newest XID with valid commit timestamp
Previously pg_controldata didn't report newestCommitTs and this was an oversight in commit 73c986a. Also this patch changes pg_resetxlog so that it uses the same sentences as pg_controldata does, regarding oldestCommitTs and newestCommitTs, for the sake of consistency. Back-patch to 9.5 where track_commit_timestamp was added. Euler Taveira
Diffstat (limited to 'src')
-rw-r--r--src/bin/pg_controldata/pg_controldata.c2
-rw-r--r--src/bin/pg_resetxlog/pg_resetxlog.c4
2 files changed, 4 insertions, 2 deletions
diff --git a/src/bin/pg_controldata/pg_controldata.c b/src/bin/pg_controldata/pg_controldata.c
index 704f72d3c50..32e1d81bf20 100644
--- a/src/bin/pg_controldata/pg_controldata.c
+++ b/src/bin/pg_controldata/pg_controldata.c
@@ -273,6 +273,8 @@ main(int argc, char *argv[])
ControlFile.checkPointCopy.oldestMultiDB);
printf(_("Latest checkpoint's oldestCommitTs: %u\n"),
ControlFile.checkPointCopy.oldestCommitTs);
+ printf(_("Latest checkpoint's newestCommitTs: %u\n"),
+ ControlFile.checkPointCopy.newestCommitTs);
printf(_("Time of latest checkpoint: %s\n"),
ckpttime_str);
printf(_("Fake LSN counter for unlogged rels: %X/%X\n"),
diff --git a/src/bin/pg_resetxlog/pg_resetxlog.c b/src/bin/pg_resetxlog/pg_resetxlog.c
index 0657da09318..88269601219 100644
--- a/src/bin/pg_resetxlog/pg_resetxlog.c
+++ b/src/bin/pg_resetxlog/pg_resetxlog.c
@@ -665,9 +665,9 @@ PrintControlValues(bool guessed)
ControlFile.checkPointCopy.oldestMulti);
printf(_("Latest checkpoint's oldestMulti's DB: %u\n"),
ControlFile.checkPointCopy.oldestMultiDB);
- printf(_("Latest checkpoint's oldest CommitTs: %u\n"),
+ printf(_("Latest checkpoint's oldestCommitTs: %u\n"),
ControlFile.checkPointCopy.oldestCommitTs);
- printf(_("Latest checkpoint's newest CommitTs: %u\n"),
+ printf(_("Latest checkpoint's newestCommitTs: %u\n"),
ControlFile.checkPointCopy.newestCommitTs);
printf(_("Maximum data alignment: %u\n"),
ControlFile.maxAlign);