aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2022-09-15 10:58:03 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2022-09-15 10:58:03 -0400
commit918de37652138da7f7e54c79351178367d60f501 (patch)
tree4ee48ba065752cd24c9f1c916220d52356a05437
parentb4f584f9d2a1b50d1f5ce88408a54bb11f1c8353 (diff)
downloadpostgresql-918de37652138da7f7e54c79351178367d60f501.tar.gz
postgresql-918de37652138da7f7e54c79351178367d60f501.zip
Revert ill-considered change in pg_resetwal output.
Commit 31dcfae83 changed one pg_resetwal output string, and a corresponding test in pg_upgrade, without sufficient thought for the consequences. We can't change that output without creating hazards for cross-version upgrades, since pg_upgrade needs to be able to read the output of several different versions of pg_resetwal. There may well be external tools with the same requirement. For the moment, just revert those two changes. What we really ought to do here is have a separate, stable, easily machine-readable output format for pg_resetwal and pg_controldata, as proposed years ago by Alvaro. Once that's in place and tools no longer need to depend on the exact spelling of the human-readable output, we can put back this change. Discussion: https://postgr.es/m/fbea8c6f-415a-bad9-c3de-969c40d08a84@dunslane.net
-rw-r--r--src/bin/pg_resetwal/pg_resetwal.c2
-rw-r--r--src/bin/pg_upgrade/controldata.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/bin/pg_resetwal/pg_resetwal.c b/src/bin/pg_resetwal/pg_resetwal.c
index 7adf79eeed6..d4772a29650 100644
--- a/src/bin/pg_resetwal/pg_resetwal.c
+++ b/src/bin/pg_resetwal/pg_resetwal.c
@@ -788,7 +788,7 @@ PrintNewControlValues(void)
XLogFileName(fname, ControlFile.checkPointCopy.ThisTimeLineID,
newXlogSegNo, WalSegSz);
- printf(_("First WAL segment after reset: %s\n"), fname);
+ printf(_("First log segment after reset: %s\n"), fname);
if (set_mxid != 0)
{
diff --git a/src/bin/pg_upgrade/controldata.c b/src/bin/pg_upgrade/controldata.c
index 88d7e1c73de..018cd310f7c 100644
--- a/src/bin/pg_upgrade/controldata.c
+++ b/src/bin/pg_upgrade/controldata.c
@@ -348,7 +348,7 @@ get_control_data(ClusterInfo *cluster, bool live_check)
cluster->controldata.chkpnt_nxtmxoff = str2uint(p);
got_mxoff = true;
}
- else if ((p = strstr(bufin, "First WAL segment after reset:")) != NULL)
+ else if ((p = strstr(bufin, "First log segment after reset:")) != NULL)
{
/* Skip the colon and any whitespace after it */
p = strchr(p, ':');